Skip to main content

Parse graphviz’ xdot draw instructions

Project description

CI docs.rs Crates.io PyPI

xdot

The main function of this package is parse. It parses node/edge attributes on graphviz graphs created by xdot into drawable shapes.

use xdot::{parse, ShapeDraw};
let shapes: Vec<ShapeDraw> = parse("c 7 -#ff0000 p 4 4 4 36 4 36 36 4 36");

Each ShapeDraw struct contains a shape with geometry and a pen with drawing attributes (such as color, line style, and font). If you have the layout feature active, you can also use layout_and_draw_graph (and draw_graph):

use graphviz_rust::parse;
use graphviz_rust::dot_structures::Graph;
use xdot::{layout_and_draw_graph, ShapeDraw};

let graph: Graph = parse("graph { a -- b}").unwrap();
let shapes: Vec<ShapeDraw> = layout_and_draw_graph(graph).unwrap();

Release process

To be automated. Currently:

$ # update version
$ $EDITOR Cargo.toml  # update version
$ cargo build  # update lockfile
$ git add Cargo.toml Cargo.lock && git commit && git tag v??????
$ # publish
$ cargo publish
$ docker run --rm -v "$PWD:/io" ghcr.io/pyo3/maturin:v1.0.0-beta.7 build --release -i python3.8 -i python3.9 -i python3.10 -i python3.11
$ twine upload 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 Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

xdot_rs-0.2.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.11 manylinux: glibc 2.17+ x86-64

xdot_rs-0.2.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.10 manylinux: glibc 2.17+ x86-64

xdot_rs-0.2.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.9 manylinux: glibc 2.17+ x86-64

xdot_rs-0.2.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.8 manylinux: glibc 2.17+ x86-64

File details

Details for the file xdot_rs-0.2.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for xdot_rs-0.2.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 33e768dc4e64dc2ce84cac461c4ee83b7cd9621133b2d4ee3ff51b3e80ad94e9
MD5 f397529ab2f3b22ff082974204967bf0
BLAKE2b-256 5e95cc0f28fa7e63d50147c43fcc23150756a2666de529c9bd7ea76005712ed8

See more details on using hashes here.

File details

Details for the file xdot_rs-0.2.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for xdot_rs-0.2.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 c74dee6a5ba1686d1a21823cb301a2c9c615eb4698e19ca8ef238c0ec26bf37e
MD5 4c55171a55b42561f2e0fce8e8bea0a1
BLAKE2b-256 55e88dd67d2e26bc44548766c283d911d90b672410e7db8788ae95c65fdf9251

See more details on using hashes here.

File details

Details for the file xdot_rs-0.2.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for xdot_rs-0.2.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 ad0ca114865262c41c847b151357941d9404047e993eb9a721a54653a80c7235
MD5 fbfbbe46b2884180f424d34e231b547d
BLAKE2b-256 aaf8bd637ab306c500def640d1130d6cfcd4386e94961ccf3620ef6a482d968b

See more details on using hashes here.

File details

Details for the file xdot_rs-0.2.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for xdot_rs-0.2.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 0c75254503c530d4cf76a473c9963007859486e6a3ba97209940295d897734ca
MD5 7a23f865140a0e77a4be7b0fb5eaa2b8
BLAKE2b-256 8129824e0d76a57cff724217250fdd828251e3e0c5d4fd6c336337bf66ce30d4

See more details on using hashes here.

Supported by

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