Skip to main content

No project description provided

Project description

mpl-speech-bubble

A proof-of-concept package to draw speech bubble. It is basically MPL's annotation and it merges the arrow patch and bbox patch using skia-pathops. The package is far from complete and only recommended for an advanced MPL user who are well familiar with how annotation works.

from mpl_speech_bubble import annotate_bubble

ann = annotate_bubble(ax, 'speech\nbubble',
                      xy=(4, 4), xycoords='data',
                      xytext=(-10, -25), textcoords='offset points',
                      size=20, color="w",
                      ha="left", va="top",
                      bbox=dict(boxstyle="round",
                                fc="none", ec="w"),
                      arrowprops=dict(arrowstyle="wedge,tail_width=2.",
                                      patchA=None,
                                      patchB=el,
                                      relpos=(0.5, 0.5),
                                      connectionstyle="arc3,rad=-0.1"))

Check out examples/example.py for full example.

Installation

The package is not available at pip. You can clone the git repository and install from the source.:

pip install .

Development Installation

pip install -e ".[dev]"

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 Distribution

mpl_speech_bubble-0.1.0-py3-none-any.whl (8.6 kB view hashes)

Uploaded Python 3

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