{ "info": { "author": "Leopold de Gaillande", "author_email": "leopold.tal.dg@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Natural Language :: English", "Programming Language :: Python :: 3", "Topic :: Software Development :: Interpreters" ], "description": "mpdl-py\n=======\n\nMPDL interpreter for Python\n\nMPDL\n----\n\nMPDL (Mondrian Painting Description Language) is an esoteric language\n`created by Arnaud Marguerat`_ to describe `Piet Mondrian`_ abstract paintings.\n\n.. _`created by Arnaud Marguerat`: https://codegolf.stackexchange.com/questions/40741/mondrian-painting-description-language\n.. _`Piet Mondrian`: https://en.wikipedia.org/wiki/Piet_Mondrian\n\nSyntax\n~~~~~~\n\nMPDL operates on a stack of rectangles and outputs a square image. The stack\nis initialised with a single rectangle filling the whole image. There are 3\ncommands:\n\n1. ``v``: Pop a rectangle and split it vertically at the\n position given by the argument as percentage, rounded down. Push the left\n and right rectangles, in this order.\n\n2. ``h``: Split horizontally. Push the top and bottom\n rectangles, in this order.\n\n3. ``c``: Pop a rectangle and paint it a colour:\n \n - 1: white\n \n - 2: red\n \n - 3: blue\n \n - 4: yellow\n\nRectangles are drawn with a black border.\n\nExample\n~~~~~~~\n\nThe sample program::\n\n v25 h71 v93 h50 c4 c1 c1 c2 h71 c3 h44 c1 c1\n\nrun with canvas size 256px and border width 3px, outputs\n\n.. image:: mondrian_composition.png\n\nHow to install\n--------------\n\nInstalling from distribution\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nIt's usually easiest to get the package from the pip repository::\n\n pip install mpdl\n\nInstalling from source\n~~~~~~~~~~~~~~~~~~~~~~~\n\nTo install from source, clone the source repo and run the setup script::\n\n git clone https://github.com/LeopoldTal/mpdl-py.git\n cd mpdl-py\n pip install -e .\n\nRunning the tests\n~~~~~~~~~~~~~~~~~\n\nRun tests in the root directory with::\n\n py.test\n\nTo generate a coverage report::\n\n py.test --cov --cov-branch --cov-report=term-missing\n\nHow to use\n----------\n\nUsage::\n\n mpdl [-o OUT] [-s SIZE] [-b BORDER] path/to/source_file.mpdl\n\nOutputs an ASCII PPM image with colour depth 1.\n\nArguments:\n\n- ``-o``: Path to output file. Default ``out.ppm``.\n- ``-s``: Side length of square image in pixels. Default 256.\n- ``-b``: Thickness of rectangle borders in pixels. Default 3.\n\nLicence\n-------\n\nMIT. See LICENSE_ file.\n\n.. _LICENSE: LICENSE\n\nCredits\n-------\n\nDeveloper\n~~~~~~~~~\n\nmpdl-py is developed by `Leopold T. de Gaillande`_.\n\n.. _`Leopold T. de Gaillande`: https://github.com/LeopoldTal/\n\nLanguage author\n~~~~~~~~~~~~~~~\n\nMPDL is the work of `Arnaud Marguerat`_.\n\n.. _`Arnaud Marguerat`: https://codegolf.stackexchange.com/users/13798/arnaud\n\nDependencies\n~~~~~~~~~~~~\n\n* setuptools_\n* argparse_\n* pytest_\n* unittest_\n\n.. _setuptools: https://setuptools.readthedocs.io/en/latest/\n.. _argparse: https://docs.python.org/3/library/argparse.html\n.. _pytest: https://docs.pytest.org/en/latest/\n.. _unittest: https://docs.python.org/3/library/unittest.html\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/LeopoldTal/mpdl-py", "keywords": "mpdl interpreter esoteric esolang", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "mpdl", "package_url": "https://pypi.org/project/mpdl/", "platform": "", "project_url": "https://pypi.org/project/mpdl/", "project_urls": { "Homepage": "https://github.com/LeopoldTal/mpdl-py" }, "release_url": "https://pypi.org/project/mpdl/1.0.0/", "requires_dist": null, "requires_python": "", "summary": "Mondrian Painting Description Language interpreter", "version": "1.0.0" }, "last_serial": 5745622, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "be749c22158f100ec272f14050462faf", "sha256": "14999a64476f504f7ab2ca25f7849df0cc395e1efb46a3e29385cd385c9a3003" }, "downloads": -1, "filename": "mpdl-0.1.0.tar.gz", "has_sig": false, "md5_digest": "be749c22158f100ec272f14050462faf", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12811, "upload_time": "2019-08-28T20:46:01", "url": "https://files.pythonhosted.org/packages/38/3b/176306c061b1acf32c97766991cd65443b8ee909f92168f1bbacb3e55911/mpdl-0.1.0.tar.gz" } ], "1.0.0": [ { "comment_text": "", "digests": { "md5": "2d8fa6fac2e0510fef416b3c84d4ca64", "sha256": "b47ec2cafb327b9ad1cc29a536f69f04036aefc5d5170bc45c2c98d6068a0b84" }, "downloads": -1, "filename": "mpdl-1.0.0.tar.gz", "has_sig": false, "md5_digest": "2d8fa6fac2e0510fef416b3c84d4ca64", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12807, "upload_time": "2019-08-28T20:52:51", "url": "https://files.pythonhosted.org/packages/a2/51/4a3bb0c448100bf24373f0bc7239c0f778dd7d85200751c7bcd39c9e32d0/mpdl-1.0.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "2d8fa6fac2e0510fef416b3c84d4ca64", "sha256": "b47ec2cafb327b9ad1cc29a536f69f04036aefc5d5170bc45c2c98d6068a0b84" }, "downloads": -1, "filename": "mpdl-1.0.0.tar.gz", "has_sig": false, "md5_digest": "2d8fa6fac2e0510fef416b3c84d4ca64", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12807, "upload_time": "2019-08-28T20:52:51", "url": "https://files.pythonhosted.org/packages/a2/51/4a3bb0c448100bf24373f0bc7239c0f778dd7d85200751c7bcd39c9e32d0/mpdl-1.0.0.tar.gz" } ] }