{ "info": { "author": "Mike Sandford", "author_email": "mike@mikedeplume.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Intended Audience :: Education", "License :: OSI Approved :: MIT License", "Natural Language :: English", "Operating System :: OS Independent", "Programming Language :: Python :: 2.7", "Topic :: Education" ], "description": "Physical Turtle\n===============\n\nThis is an extension for the Python turtle module that provides a\nphysical space for a turtle to inhabit. The initial aim is to provide\nareas of solid space that the turtle cannot move into.\n\nThe Turtle class is extended with the following methods. This list\nmay change as the first version of this package is developed.\n\nGenerally, methods are used here rather than attributes to be\nconsistent with the rest of the Turtle interface.\n\nMethods:\n\n* `touch_left()`, `touch_right()`, `touch_front()`, `touch_back()`\n\n Each one returns True if the Turtle would not be able to move in\n that direction.\n\n* `last_distance()`\n\n The distance travelled in the preceding forward or backward\n movement. Since the turtle is not able to move through a solid area\n this distance may be less than the distance originally called for.\n\n* `pen_set_solid()`\n\n Set a pen property so that any movement of the turtle with the pen\n down creates a solid area. The pen colour is not affected, so that\n the lines shown on the screen correspond to lines of solidity in\n the physical space.\n\n The solid area created by the turtle move is a rectangle\n corresponding to the length of the move and the width of the pen.\n\n No solid area is drawn in the pen is up.\n\n The action of filling a polygon with a colour does not create solid\n space.\n\n* `pen_unset_solid()`\n\n Reverses the action of pen_set_solid so that turtle movement does\n not create solid areas.\n\nThe extension provides a new rule that says a turtle cannot cross a\nline that has been drawn with `pen_set_solid`. The turtle is allowed\nto move up to the solid line and the attribute `last_distance`\ngives the distance actually moved.\n\nThere are two exceptions to this rule:\n\n- A turtle with pen `up` is allowed to move anywhere. This is allows\n the turtle to move to any place on the screen and is required for\n placing the turtle into an enclosed space.\n\n- A turtle with pen `solid` is allowed to move anywhere. This is\n specifically designed to allow drawing a solid shape where one edge\n must be drawn contiguously with another. (If this was not allowed,\n the second line would not be drawn because it would be trapped by\n the end of the first line.)\n\nInstallation\n============\n\nGet the version straight from the Python Package Index::\n\n pip install physicalturtle\n\nOr Get the latest version from Bit Bucket::\n\n https://bitbucket.org/mikedeplume/physical-turtle\n\nIf you do download the repository, don't forget to put the\n`physicalturtle` package on your PYTHON_PATH. The easiest way to do\nthis is to go into the directory and type::\n\n python setup.py install\n\n\nLicense\n=======\n\nThe package uses the MIT license:\n\n\n Permission is hereby granted, free of charge, to any person\n obtaining a copy of this software and associated documentation\n files (the \"Software\"), to deal in the Software without\n restriction, including without limitation the rights to use, copy,\n modify, merge, publish, distribute, sublicense, and/or sell copies\n of the Software, and to permit persons to whom the Software is\n furnished to do so, subject to the following conditions:\n\n The above copyright notice and this permission notice shall be\n included in all copies or substantial portions of the Software.\n\n THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT\n HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,\n WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER\n DEALINGS IN THE SOFTWARE.\n\nUse\n===\n\nThe package is intended as a one for one replacement for the built in\nturtle module. Any existing turtle software that you have should work\njust as before if you replace::\n\n from turtle import ...\n\nwith::\n\n from physicalturtle import ...\n\nFrom that perspective, there is nothing much new to learn.\n\nExamples\n========\n\nThese examples can be run either by importing the run procedure or by\nexecuting them from the command line::\n\n $python path/to/package/example_xxx.py\n\nUsing the command line is probably going to be appropriate if you have\ndownloaded the source and want to study how it works.\n\nRandom action\n+++++++++++++\n\nAt the Python prompt::\n\n >>> from physical_turtle.example_random import run_me\n >>> run_me()\n\nAnd watch the turtle bounce randomly around an enclosed space. \n\nFollow an Outline\n+++++++++++++++++\n\nAt the Python prompt::\n\n >>> from physicalturtle.example_follow import \n >>> run_me()\n\nAnd watch the blue line work its way around the solid object.\n\nA Constrained Random Walk\n+++++++++++++++++++++++++\n\nAt the Python prompt::\n\n >>> from physicalturtle.example_walk import run_ahead, run_behind\n >>> run_ahead()\n >>> run_behind()\n\nThis example draws a random walk using a solid line, which means that\nthe turtle cannot cross its own trail. The drawing rules mean that,\nto achieve this, the turtle must switch between a solid line and a\nnot-solid line. The example shows two ways to do this.\n\n\nChange History\n==============\n\nVersion 0.4\n+++++++++++\n\nResolve \n\n Issue #1: Solid lines are drawn even when pen is up\n\n Issue #2: Solid lines drawn using goto(x,y) are positioned wrongly.\n\n Issue #3: Follow an object outline losses contact with the object.\n\nVersion 0.3\n+++++++++++\n\nStart making changes for Python 3. The Python 3 turtle module differs\nslightly from the Python 2 version (see Python 3 documentation) and\nthese differences have been reflected in Physical Turtle.\n\nChange the package name to `physicalturtle`. This is more PEP8ish and\nhelps to keep some consistency with the PYPI package name. My\napologies to current users for the inconvenience. I realise it will\nbe inconvenient, but the hit now will save annoyance further down the\nline.\n\n\n\nVersion 0.2\n+++++++++++\n\nThe `touch_xxx` methods now work. This is illustrated in a new\nexample, `example_follow.py`.\n\nThe internal mechanism for finishing off the line clipping algorithm\nhas been tidied up.\n\nThe internal mechanisms now distinguish properly between the effective\nsize of the turtle, the safety_radius, as used in line clipping, and\nthe reach of the `touch_xxx` methods, the stick length.\n\nVersion 0.1\n+++++++++++\n\nAn initial version focusing on the straight line geometry.", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://www.mikedeplume.com", "keywords": null, "license": "MIT License", "maintainer": null, "maintainer_email": null, "name": "PhysicalTurtle", "package_url": "https://pypi.org/project/PhysicalTurtle/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/PhysicalTurtle/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://www.mikedeplume.com" }, "release_url": "https://pypi.org/project/PhysicalTurtle/0.4/", "requires_dist": null, "requires_python": null, "summary": "Physical characteristics for turtle graphics", "version": "0.4" }, "last_serial": 867147, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "4a0f4a51c661c2a715c658e6adafb8cf", "sha256": "e47a1ffce7925a08a082907795d876d8fcf8c8c67b586ebbf65cac95fdf65653" }, "downloads": -1, "filename": "PhysicalTurtle-0.1.tar.gz", "has_sig": false, "md5_digest": "4a0f4a51c661c2a715c658e6adafb8cf", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 19863, "upload_time": "2013-02-20T20:07:17", "url": "https://files.pythonhosted.org/packages/e3/b8/95a19e2b1f5bca11f943cfd041ba4615c4a168caa6fcdc7b523a291f8c3a/PhysicalTurtle-0.1.tar.gz" } ], "0.2": [ { "comment_text": "", "digests": { "md5": "64140162edcdb88d83d7ab727e1a71aa", "sha256": "f5e0e9133dcac17478c08166855bf4011cd6d566386cc4fa70d1ee2d15c2281b" }, "downloads": -1, "filename": "PhysicalTurtle-0.2.tar.gz", "has_sig": false, "md5_digest": "64140162edcdb88d83d7ab727e1a71aa", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21700, "upload_time": "2013-03-10T14:53:54", "url": "https://files.pythonhosted.org/packages/37/f7/a08dc7d9a273a4138f1b22ee61aac94eff7396ad1e983d709a838b975d37/PhysicalTurtle-0.2.tar.gz" } ], "0.3": [ { "comment_text": "", "digests": { "md5": "11f15632543ab11b30bafe5406838c9f", "sha256": "5252a60acc2dd50eb0f7799ad15f0b1dd79b1bf023bf8dc0241d268e96dd1fee" }, "downloads": -1, "filename": "PhysicalTurtle-0.3.tar.gz", "has_sig": false, "md5_digest": "11f15632543ab11b30bafe5406838c9f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26149, "upload_time": "2013-06-21T15:23:01", "url": "https://files.pythonhosted.org/packages/ef/77/62888921e6af2161d0fe979a3e86dd4e315a66a838cad0e03799e6d353d7/PhysicalTurtle-0.3.tar.gz" } ], "0.4": [ { "comment_text": "", "digests": { "md5": "a7db82eb6e5330e4a7f06f7df864dd06", "sha256": "3f9298df4ffff28ac2396dbc851d7634bfd2ef323b5ed5f7f615f2fe4812e680" }, "downloads": -1, "filename": "PhysicalTurtle-0.4.tar.gz", "has_sig": false, "md5_digest": "a7db82eb6e5330e4a7f06f7df864dd06", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 27384, "upload_time": "2013-09-16T20:05:04", "url": "https://files.pythonhosted.org/packages/d5/78/8fb9649caf73ee50ac1693cb32c457a0be2554374006c0723f0db1c281e7/PhysicalTurtle-0.4.tar.gz" }, { "comment_text": "", "digests": { "md5": "07dc2f58a9464f72963400964e045040", "sha256": "f32c97a8575c589957461e5bcb18b64de651e41e445896a056c854f8da56ad9b" }, "downloads": -1, "filename": "PhysicalTurtle-0.4.zip", "has_sig": false, "md5_digest": "07dc2f58a9464f72963400964e045040", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 36615, "upload_time": "2013-09-16T20:05:01", "url": "https://files.pythonhosted.org/packages/a1/ff/9d39e885b78dfd1789f3c53b6a73237cef9870935686953a0e34917f9ec5/PhysicalTurtle-0.4.zip" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "a7db82eb6e5330e4a7f06f7df864dd06", "sha256": "3f9298df4ffff28ac2396dbc851d7634bfd2ef323b5ed5f7f615f2fe4812e680" }, "downloads": -1, "filename": "PhysicalTurtle-0.4.tar.gz", "has_sig": false, "md5_digest": "a7db82eb6e5330e4a7f06f7df864dd06", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 27384, "upload_time": "2013-09-16T20:05:04", "url": "https://files.pythonhosted.org/packages/d5/78/8fb9649caf73ee50ac1693cb32c457a0be2554374006c0723f0db1c281e7/PhysicalTurtle-0.4.tar.gz" }, { "comment_text": "", "digests": { "md5": "07dc2f58a9464f72963400964e045040", "sha256": "f32c97a8575c589957461e5bcb18b64de651e41e445896a056c854f8da56ad9b" }, "downloads": -1, "filename": "PhysicalTurtle-0.4.zip", "has_sig": false, "md5_digest": "07dc2f58a9464f72963400964e045040", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 36615, "upload_time": "2013-09-16T20:05:01", "url": "https://files.pythonhosted.org/packages/a1/ff/9d39e885b78dfd1789f3c53b6a73237cef9870935686953a0e34917f9ec5/PhysicalTurtle-0.4.zip" } ] }