{ "info": { "author": "Luca Tringali", "author_email": "TRINGALINVENT@libero.it", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Intended Audience :: Developers", "License :: OSI Approved :: GNU General Public License v3 (GPLv3)", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Topic :: Software Development :: Build Tools" ], "description": "# pythonWordArt\n\nMake WordArt, like the ones in MS Office, using Python3. \\\nThe actual WordArt generation is performed by a forked version of CSS3 WordArt by Arizzitano: https://github.com/arizzitano/css3wordart\nThis Python class is just producing the correct HTML code, converting it into PDF, and then into a PNG image. Basically, the HTML get rendered by a QWebEnginePage and printed in PDF. Then, the PDF gets rasterized into a PNG, trying to calculate the correct size of the final image.\n\n## Requirements \n* PySide2: https://pypi.org/project/PySide2/\n\nIf you install pythonWordArt with pip\n```\npip install pythonWordArt\n```\nthe PySide2 library will be installed automatically. Anyway, if you are installing this on a Linux server, you might need tho install also these libraries using your package manager:\n```\nsudo apt-get install libgl1-mesa-dri libgl1-mesa-glx libnss3 libfontconfig1 libxcomposite1 libxcursor1 libxi6 libxtst6 libasound2\n```\nyou don't need a full Xorg running, just the base libraries. The only problem is that if you don't have a Xorg screen you cannot use the OpenGL effects, so a handful of WordArt styles will not be available. You can check that running the **demo**.\n\n## Simple test\n\nIf you run the **main.py** file it will print the name a temporary folder: all the files for the demo will be created in that folder. \\\nIt's also available a test program that you can run without arguments, or with two arguments. For example, if you want to create an image called **example.png** using the style **rainbow** just run this:\n```\npython3 test.py example.png rainbow\n```\nif you want to know all styles name, please keep reading.\n\n## Example code\n\nThis is a minimalistic example:\n```\nfrom pythonWordArt import pyWordArt\nw = pyWordArt()\nw.render3D = True\nfileName = \"temp.png\"\nw.WordArt(\"Text here\", w.Styles[\"rainbow\"], 100, fileName)\n```\nThe first argument is the text, the second is the Style (which needs to be choosen from the **Styles** list) and the third is the size of the font used to write the WordArt. The fourth argument is the filename, without extension, for output. \\\nIf you specify render3D, the library will attempt to draw the 3D effects. If you don't specify this flag, the rendering will be faster and more reliable, but will not have 3D effects. \\\nTo try out all the styles, you can run a demo:\n```\nimport tempfile\nimport os\nfrom pythonWordArt import pyWordArt\nw = pyWordArt()\ntmpdirname = \"\"\nwith tempfile.TemporaryDirectory() as dirname:\ntmpdirname = dirname\nos.mkdir(tmpdirname)\nprint(tmpdirname)\nw.canvasWidth = 1754\nw.canvasHeight = 1240\nw.render3D = True\nw.demo(tmpdirname, 100)\n```\nIt's a good idea to set the canvas size, in particular if you are writing a long text. A note: running the demo, some images might not be written correctly. This happens because some WordArt need some more time, and if you create too many one after the other the QWebEngineView does not have the time to clear its content. This does not happen if you wait between the creation of two WordArt. \\\nIf you need to get the background transparent, you can set\n```\nw.transparentBackground = True\n```\nbefore calling the function **WordArt** or **demo**.\n\n## Styles\n\nThese are all the available styles:\n* outline \n* up \n* arc \n* squeeze \n* inverted-arc \n* basic-stack \n* italic-outline \n* slate \n* mauve \n* graydient \n* red-blue \n* brown-stack \n* radial \n* purple \n* green-marble \n* rainbow \n* aqua \n* texture-stack \n* paper-bag \n* sunset \n* tilt \n* blues \n* yellow-dash \n* green-stack \n* chrome \n* marble-slab \n* gray-block \n* superhero \n* horizon \n* stack-3d\n\nYou can find all the images in the **examples** folder.\n\n## HTML\n\nThere is a simple HTML example in the pythonWordArt folder, of course you need also the css3wordart subfolder to make it work. To change the text, just look for the **wordart-text** span. The content of the span will become the text, and the the **data-text** property will become the shadow. Usually, text and shadow are the same, but you can always use different phrases.\n\n## Thanks to\nArizzitano for his WordArt in CSS3+Javascript: https://github.com/arizzitano/css3wordart", "description_content_type": "text/markdown", "docs_url": null, "download_url": "https://github.com/zorbaproject/pythonWordArt/archive/v0.4.tar.gz", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/zorbaproject/pythonWordArt", "keywords": "wordart,html2png,office", "license": "gpl-3.0", "maintainer": "", "maintainer_email": "", "name": "pythonWordArt", "package_url": "https://pypi.org/project/pythonWordArt/", "platform": "", "project_url": "https://pypi.org/project/pythonWordArt/", "project_urls": { "Download": "https://github.com/zorbaproject/pythonWordArt/archive/v0.4.tar.gz", "Homepage": "https://github.com/zorbaproject/pythonWordArt" }, "release_url": "https://pypi.org/project/pythonWordArt/0.4/", "requires_dist": null, "requires_python": "", "summary": "Make WordArt, like the ones in MS Office, using Python3", "version": "0.4" }, "last_serial": 6004422, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "2ce52e422833ec6c0fb53f6e1fa32c5a", "sha256": "0bbc62de674590d6977226f264ec36f5ab11f95b392a56970f72c27b5a2795ad" }, "downloads": -1, "filename": "pythonWordArt-0.1.tar.gz", "has_sig": false, "md5_digest": "2ce52e422833ec6c0fb53f6e1fa32c5a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3495, "upload_time": "2019-10-16T16:08:01", "url": "https://files.pythonhosted.org/packages/4a/6f/fda48258cc2fb325d6c7880973dfee2ca79f3ac0d3ad33ee76d5f219f136/pythonWordArt-0.1.tar.gz" } ], "0.2": [ { "comment_text": "", "digests": { "md5": "7e6d6525758c4c557770ab6a82e82ff4", "sha256": "62317f5dcb3117e4b6baa85ff3a1e536604afa161382bbdf63c91dbef152b030" }, "downloads": -1, "filename": "pythonWordArt-0.2.tar.gz", "has_sig": false, "md5_digest": "7e6d6525758c4c557770ab6a82e82ff4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1434134, "upload_time": "2019-10-16T22:38:57", "url": "https://files.pythonhosted.org/packages/27/16/c6913a002abed4c19d6119e64dd599331e132d38520467a6a7d0e5824f1b/pythonWordArt-0.2.tar.gz" } ], "0.3": [ { "comment_text": "", "digests": { "md5": "0bb512ef2a43737d6209666ae9de2ebb", "sha256": "14086d66f0831a25b37bc88d1993a56e8f2623c1da319bdd6270424f0c4c6893" }, "downloads": -1, "filename": "pythonWordArt-0.3.tar.gz", "has_sig": false, "md5_digest": "0bb512ef2a43737d6209666ae9de2ebb", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1434585, "upload_time": "2019-10-17T00:35:35", "url": "https://files.pythonhosted.org/packages/54/fb/816b3ff766661454751d38cf4508dc30225d7d3860847bb4f03296f99816/pythonWordArt-0.3.tar.gz" } ], "0.4": [ { "comment_text": "", "digests": { "md5": "92ccd5e2486247743cf39b4f1b648614", "sha256": "551c403f4ca2fbb7cfe881cb2c2ebb23e2490c847997c39d55b3931e4493eaaf" }, "downloads": -1, "filename": "pythonWordArt-0.4.tar.gz", "has_sig": false, "md5_digest": "92ccd5e2486247743cf39b4f1b648614", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1407320, "upload_time": "2019-10-20T19:34:17", "url": "https://files.pythonhosted.org/packages/08/c9/96451336ce5a82f133f6c4c306a55ff9a855b26e02adee4d009e0fd4a673/pythonWordArt-0.4.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "92ccd5e2486247743cf39b4f1b648614", "sha256": "551c403f4ca2fbb7cfe881cb2c2ebb23e2490c847997c39d55b3931e4493eaaf" }, "downloads": -1, "filename": "pythonWordArt-0.4.tar.gz", "has_sig": false, "md5_digest": "92ccd5e2486247743cf39b4f1b648614", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1407320, "upload_time": "2019-10-20T19:34:17", "url": "https://files.pythonhosted.org/packages/08/c9/96451336ce5a82f133f6c4c306a55ff9a855b26e02adee4d009e0fd4a673/pythonWordArt-0.4.tar.gz" } ] }