Skip to main content

Python bindings for rpic — the pic graphics language → SVG/PNG/PDF with animation.

Project description

rpiclang (Python)

Python bindings for rpic — the pic graphics language rendered to SVG / PNG / PDF, with animation manifests.

pip install rpiclang        # distribution name; you `import rpic`
import rpic, json

svg = rpic.render_svg('box "hi"; arrow; circle "x"')
open("out.png", "wb").write(rpic.render_png("box \"hi\"", scale=2.0))
open("out.pdf", "wb").write(rpic.render_pdf("box \"hi\""))

# circuit library:
svg = rpic.render_svg('A:(0,0); B:(2,0)\nresistor(A,B)', circuits=True)

# svg + animation manifest:
bundle = json.loads(rpic.compile_json('box\nanimate last box with "pop"'))

Build

pip install maturin
cd bindings/python
maturin develop --release     # installs into the current environment
# or: maturin build --release  → wheels in target/wheels/

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

rpiclang-0.1.0.tar.gz (150.8 kB view details)

Uploaded Source

Built Distributions

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

rpiclang-0.1.0-cp39-abi3-win_amd64.whl (3.1 MB view details)

Uploaded CPython 3.9+Windows x86-64

rpiclang-0.1.0-cp39-abi3-manylinux_2_35_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.9+manylinux: glibc 2.35+ x86-64

rpiclang-0.1.0-cp39-abi3-macosx_11_0_arm64.whl (3.3 MB view details)

Uploaded CPython 3.9+macOS 11.0+ ARM64

File details

Details for the file rpiclang-0.1.0.tar.gz.

File metadata

  • Download URL: rpiclang-0.1.0.tar.gz
  • Upload date:
  • Size: 150.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for rpiclang-0.1.0.tar.gz
Algorithm Hash digest
SHA256 227194da54eb434244f4b91297396199ff3171413cd4b9250695055994ee0340
MD5 f8448a5237cc7ea6b3aedf5285c20d8c
BLAKE2b-256 82ad0493640e62015990dbf0d1110d9f0b899648e60f473bc6f4ce1eed72ef95

See more details on using hashes here.

Provenance

The following attestation bundles were made for rpiclang-0.1.0.tar.gz:

Publisher: python.yml on milkway/rpic-lang

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rpiclang-0.1.0-cp39-abi3-win_amd64.whl.

File metadata

  • Download URL: rpiclang-0.1.0-cp39-abi3-win_amd64.whl
  • Upload date:
  • Size: 3.1 MB
  • Tags: CPython 3.9+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for rpiclang-0.1.0-cp39-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 e91bbed4573d5cc7099b77c15a49e403bb4adf2d9cb9af67ebe27f44b132c573
MD5 ce3c47495cce7cf54bc6bc5df013e6a4
BLAKE2b-256 7c860f3bd91d52de25ff0bea91cbab09b0934f45c98b7918a897b85bd831ba13

See more details on using hashes here.

Provenance

The following attestation bundles were made for rpiclang-0.1.0-cp39-abi3-win_amd64.whl:

Publisher: python.yml on milkway/rpic-lang

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rpiclang-0.1.0-cp39-abi3-manylinux_2_35_x86_64.whl.

File metadata

File hashes

Hashes for rpiclang-0.1.0-cp39-abi3-manylinux_2_35_x86_64.whl
Algorithm Hash digest
SHA256 2d569a3b823f81859c75a13b56b3afc2ef53204c3932649f3b2ecc19a1f37169
MD5 5e8a290e7d52db1f8173b48c42fb0639
BLAKE2b-256 9baaa8dea8cacf288aab35cafc625ed12497f0be0305fc4f8eaf1cff3be4aad6

See more details on using hashes here.

Provenance

The following attestation bundles were made for rpiclang-0.1.0-cp39-abi3-manylinux_2_35_x86_64.whl:

Publisher: python.yml on milkway/rpic-lang

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file rpiclang-0.1.0-cp39-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for rpiclang-0.1.0-cp39-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 c8f3521899e6d5d586b90a719e2701f0c5deb53c3678edf76668199156d44a06
MD5 cdfb5310f6655f0aa4b2b3b46a57c9a6
BLAKE2b-256 2925564ea54fb40f69a1d4b3f5ff09501b2b02e8d284a366033bc38c4e08be5c

See more details on using hashes here.

Provenance

The following attestation bundles were made for rpiclang-0.1.0-cp39-abi3-macosx_11_0_arm64.whl:

Publisher: python.yml on milkway/rpic-lang

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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