Skip to main content

Simple turtle system for JupyterLab

Project description

jupyterlab-jbturtle

Simple turtle module for JupyterLab

JBTurtle

  • This module uses Pillow
  • Attention: Almost impractical with FireFox because of FOUC. Do not use with FireFox.

Install

pip install Pillow
pip install jbturtle

Sample

from jbturtle import *

turtle = JBTurtle(640, 400)
nn = 0
for count in range(100):
  turtle.line_hsv(nn, 1, 1)
  turtle.forward(100)
  turtle.turn_right(85)
  nn += 5

Functions

  • JBTurtle(xs, ys)
    • Constructor
    • xs: x-size of workspace
    • ys: y-size of workspace
  • init(xs, ys)
    • Initialization
    • xs: x-size of workspace
    • ys: y-size of workspace
  • forward(dst)
  • turn_right(angle)
  • turn_left(angle)
  • move(x, y)
  • pen_up()
  • pen_down()
  • speed(spd)
  • line_width(lw)
  • line_color((r, g, b))
  • line_rgb(r, g, b)
  • line_hsv(h, s, v)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

jbturtle-0.2.6.tar.gz (3.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

jbturtle-0.2.6-py3-none-any.whl (6.0 kB view details)

Uploaded Python 3

File details

Details for the file jbturtle-0.2.6.tar.gz.

File metadata

  • Download URL: jbturtle-0.2.6.tar.gz
  • Upload date:
  • Size: 3.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.16

File hashes

Hashes for jbturtle-0.2.6.tar.gz
Algorithm Hash digest
SHA256 4464d1440941a27822fdcb1d78e49eb81606f073b37ac99a23685e2093dc7686
MD5 e8ca7da4f606d7e0e32bb08fdb1b892e
BLAKE2b-256 8492c150a42a04b11275ce01ef437fb2b95ea02dc116dc97f025873742e7934e

See more details on using hashes here.

File details

Details for the file jbturtle-0.2.6-py3-none-any.whl.

File metadata

  • Download URL: jbturtle-0.2.6-py3-none-any.whl
  • Upload date:
  • Size: 6.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.16

File hashes

Hashes for jbturtle-0.2.6-py3-none-any.whl
Algorithm Hash digest
SHA256 87cbcaa4f8bbdd7443e881b053c2055c99df07b308bc714ade10df445ddff2ab
MD5 836a56f1aaeda583126b23849e30ceb4
BLAKE2b-256 f0f9a0ea1a93d7ea5dcaa46e97bc0900591ec65a431291a9094b2d430bad64fe

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page