Skip to content

Latest commit

 

History

History
96 lines (55 loc) · 1.74 KB

README.rst

File metadata and controls

96 lines (55 loc) · 1.74 KB

Yuml extension for Sphinx

Author: Nicolas JOUANIN <[email protected]>

About

This extensions allows rendering of plots using yUML service.

This extensions adds the yuml directive that will replace the yuml commands with the generated by Yuml.

Quick Example

This source:

.. yuml::

    [Customer]->[Billing Address]

Installing from git checkout

Checkout sphinxcontrib-yuml:

$ git clone https://github.com/njouanin/sphinxcontrib-yuml.git

Change into the sphinxcontrib-yuml directory:

$ cd sphinxcontrib-yuml

Install the module:

$ python setup.py install

Enabling the extension in Sphinx

Just add sphinxcontrib.yuml to the list of extensions in the conf.py file. For example:

extensions = ['sphinxcontrib.yuml']

Usage

Options

type: class, activity or usecase
Type of diagram to draw
direction: RL, LR, TD
Diagram direction (RL=right-to-left, LR=left-to-right, TD=top-down)
scale: integer value
diagram scale
style: scruffy, plain, boring
diagram style

Configuration

For now one optional configuration is added to Sphinx. It can be set in conf.py file:

yuml_format <dict>:

image format used for the different builders. latex and html formats are supported.

For example:

yuml_format = dict(latex='pdf', html='png')
yuml_options <dict>:

Yuml options used for diagram generation.

For example:

yuml_format = dict(style='scruffy', direction='LR', type='class')

These are the actual defaults.