Skip to main content

Sphinx extension to generate images from xournal files.

Project description

https://img.shields.io/pypi/v/sphinx-xournal.svg

Sphinx extension to render images of Xournal files.

Usage

You will need to start by installing the extension.

pip install sphinx-xournal

Your sphinx conf.py file will need a few changes. To enable this extension it needs to be added to the extensions list.

extensions = [
    "sphinx_xournal",
]

If xournalpp is not installed in the default location you need to specify one:

xournal_binary_path = "/a/different/place/xournalpp"

You are now ready to include your .xopp files in your marvelous documentation.

We provide you with 3 options:

Option 1:

You can generate a restructured image from any Xournal files. This block inherits all the restructured image tags, like :align:.

.. xournal-image:: ./example.xopp
   :format: svg
   :align: center

   Sketch of an example.

Option 2:

Same applies for the figure block.

.. xournal-figure:: ./example.xopp
   :format: svg
   :align: center

   Sketch of an example.

Option 3 (Experimental):

The last option allows you to embed the raw svg.

.. xournal-raw:: ./example.xopp
   :format: svg
   :align: center

   Sketch of an example.

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

sphinx_xournal-0.1.2.tar.gz (10.5 kB view hashes)

Uploaded Source

Built Distribution

sphinx_xournal-0.1.2-py3-none-any.whl (8.8 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