| 1 |
Metadata-Version: 2.1 |
| 2 |
Name: blockdiag |
| 3 |
Version: 3.0.0 |
| 4 |
Summary: blockdiag generates block-diagram image from text |
| 5 |
Home-page: http://blockdiag.com/ |
| 6 |
Author: Takeshi Komiya |
| 7 |
Author-email: [email protected] |
| 8 |
License: Apache License 2.0 |
| 9 |
Download-URL: http://pypi.python.org/pypi/blockdiag |
| 10 |
Project-URL: Code, https://github.com/blockdiag/blockdiag |
| 11 |
Project-URL: Issue tracker, https://github.com/blockdiag/blockdiag/issues |
| 12 |
Keywords: diagram,generator |
| 13 |
Platform: UNKNOWN |
| 14 |
Classifier: Development Status :: 5 - Production/Stable |
| 15 |
Classifier: Intended Audience :: System Administrators |
| 16 |
Classifier: License :: OSI Approved :: Apache Software License |
| 17 |
Classifier: Programming Language :: Python |
| 18 |
Classifier: Programming Language :: Python :: 3.7 |
| 19 |
Classifier: Programming Language :: Python :: 3.8 |
| 20 |
Classifier: Programming Language :: Python :: 3.9 |
| 21 |
Classifier: Topic :: Software Development |
| 22 |
Classifier: Topic :: Software Development :: Documentation |
| 23 |
Classifier: Topic :: Text Processing :: Markup |
| 24 |
Requires-Python: >=3.7 |
| 25 |
Description-Content-Type: text/x-rst |
| 26 |
Provides-Extra: pdf |
| 27 |
Provides-Extra: rst |
| 28 |
Provides-Extra: testing |
| 29 |
License-File: LICENSE |
| 30 |
|
| 31 |
`blockdiag` generate block-diagram image file from spec-text file. |
| 32 |
|
| 33 |
.. image:: https://github.com/blockdiag/blockdiag/actions/workflows/main.yml/badge.svg |
| 34 |
:target: https://github.com/blockdiag/blockdiag/actions/workflows/main.yml |
| 35 |
:alt: GitHub Action CI build status |
| 36 |
|
| 37 |
.. image:: https://img.shields.io/pypi/v/blockdiag |
| 38 |
:target: https://pypi.python.org/pypi/blockdiag/ |
| 39 |
:alt: Latest PyPI version |
| 40 |
|
| 41 |
.. image:: https://img.shields.io/pypi/dm/blockdiag |
| 42 |
:target: https://pypi.python.org/pypi/blockdiag/ |
| 43 |
:alt: Number of PyPI downloads |
| 44 |
|
| 45 |
|
| 46 |
Features |
| 47 |
======== |
| 48 |
* Generate block-diagram from dot like text (basic feature). |
| 49 |
* Multilingualization for node-label (utf-8 only). |
| 50 |
|
| 51 |
You can get some examples and generated images on |
| 52 |
`blockdiag.com <http://blockdiag.com/en/blockdiag/examples.html>`_ . |
| 53 |
|
| 54 |
Setup |
| 55 |
===== |
| 56 |
|
| 57 |
Use pip:: |
| 58 |
|
| 59 |
$ sudo pip install blockdiag |
| 60 |
|
| 61 |
If you want to export as PDF format, give pdf arguments:: |
| 62 |
|
| 63 |
$ sudo pip install "blockdiag[pdf]" |
| 64 |
|
| 65 |
|
| 66 |
Copy and modify ini file. example:: |
| 67 |
|
| 68 |
$ cp <blockdiag installed path>/blockdiag/examples/simple.diag . |
| 69 |
$ vi simple.diag |
| 70 |
|
| 71 |
Please refer to `spec-text setting sample`_ section for the format of the |
| 72 |
`simpla.diag` configuration file. |
| 73 |
|
| 74 |
spec-text setting sample |
| 75 |
======================== |
| 76 |
Few examples are available. |
| 77 |
You can get more examples at |
| 78 |
`blockdiag.com`_ . |
| 79 |
|
| 80 |
simple.diag |
| 81 |
------------ |
| 82 |
simple.diag is simply define nodes and transitions by dot-like text format:: |
| 83 |
|
| 84 |
diagram admin { |
| 85 |
top_page -> config -> config_edit -> config_confirm -> top_page; |
| 86 |
} |
| 87 |
|
| 88 |
screen.diag |
| 89 |
------------ |
| 90 |
screen.diag is more complexly sample. diaglam nodes have a alternative label |
| 91 |
and some transitions:: |
| 92 |
|
| 93 |
diagram admin { |
| 94 |
top_page [label = "Top page"]; |
| 95 |
|
| 96 |
foo_index [label = "List of FOOs"]; |
| 97 |
foo_detail [label = "Detail FOO"]; |
| 98 |
foo_add [label = "Add FOO"]; |
| 99 |
foo_add_confirm [label = "Add FOO (confirm)"]; |
| 100 |
foo_edit [label = "Edit FOO"]; |
| 101 |
foo_edit_confirm [label = "Edit FOO (confirm)"]; |
| 102 |
foo_delete_confirm [label = "Delete FOO (confirm)"]; |
| 103 |
|
| 104 |
bar_detail [label = "Detail of BAR"]; |
| 105 |
bar_edit [label = "Edit BAR"]; |
| 106 |
bar_edit_confirm [label = "Edit BAR (confirm)"]; |
| 107 |
|
| 108 |
logout; |
| 109 |
|
| 110 |
top_page -> foo_index; |
| 111 |
top_page -> bar_detail; |
| 112 |
|
| 113 |
foo_index -> foo_detail; |
| 114 |
foo_detail -> foo_edit; |
| 115 |
foo_detail -> foo_delete_confirm; |
| 116 |
foo_index -> foo_add -> foo_add_confirm -> foo_index; |
| 117 |
foo_index -> foo_edit -> foo_edit_confirm -> foo_index; |
| 118 |
foo_index -> foo_delete_confirm -> foo_index; |
| 119 |
|
| 120 |
bar_detail -> bar_edit -> bar_edit_confirm -> bar_detail; |
| 121 |
} |
| 122 |
|
| 123 |
|
| 124 |
Usage |
| 125 |
===== |
| 126 |
Execute blockdiag command:: |
| 127 |
|
| 128 |
$ blockdiag simple.diag |
| 129 |
$ ls simple.png |
| 130 |
simple.png |
| 131 |
|
| 132 |
|
| 133 |
Requirements |
| 134 |
============ |
| 135 |
* Python 3.7 or later |
| 136 |
* Pillow 3.0 or later |
| 137 |
* funcparserlib 1.0.0a0 or later |
| 138 |
* reportlab (optional) |
| 139 |
* wand and imagemagick (optional) |
| 140 |
* setuptools |
| 141 |
|
| 142 |
|
| 143 |
License |
| 144 |
======= |
| 145 |
Apache License 2.0 |
| 146 |
|
| 147 |
|