Update upstream source from tag 'upstream/0.14.1'
Update to upstream version '0.14.1'
with Debian dir 0da94f338cbae28cf84ddf81a2dc11ae3d1a7fce
TANIGUCHI Takaki
3 years ago
0 | 0 | Changelog |
1 | 1 | ========= |
2 | ||
3 | ||
4 | Version 0.14.1 | |
5 | -------------- | |
6 | ||
7 | Document the colon-separated ``node[:port[:compass]]`` format used for ``tail`` | |
8 | and ``head`` points in the ``edge()``- and ``edges()``-methods' (PR Michał | |
9 | Góral). | |
2 | 10 | |
3 | 11 | |
4 | 12 | Version 0.14 |
0 | 0 | Metadata-Version: 2.1 |
1 | 1 | Name: graphviz |
2 | Version: 0.14 | |
2 | Version: 0.14.1 | |
3 | 3 | Summary: Simple Python interface for Graphviz |
4 | 4 | Home-page: https://github.com/xflr6/graphviz |
5 | 5 | Author: Sebastian Bank |
24 | 24 | author = 'Sebastian Bank' |
25 | 25 | |
26 | 26 | # The short X.Y version |
27 | version = '0.14' | |
27 | version = '0.14.1' | |
28 | 28 | # The full version, including alpha/beta/rc tags |
29 | 29 | release = version |
30 | 30 |
51 | 51 | :attr:`~.Graph.comment` for the first source code line, etc. |
52 | 52 | |
53 | 53 | Add nodes and edges to the graph object using its :meth:`~.Graph.node` and |
54 | :meth:`~.Graph.edge` or :meth:`~.Graph.edges` methods: | |
54 | :meth:`~.Graph.edge`- or :meth:`~.Graph.edges`-methods: | |
55 | 55 | |
56 | 56 | .. code:: python |
57 | 57 | |
260 | 260 | :align: center |
261 | 261 | |
262 | 262 | |
263 | .. _ports: | |
264 | ||
265 | Node ports & compass | |
266 | -------------------- | |
267 | ||
268 | The :meth:`~.Graph.edge`- and :meth:`~.Graph.edges`-methods use the | |
269 | colon-separated format ``node[:port[:compass]]`` for ``tail`` and ``head`` | |
270 | nodes. This allows to specify an optional node ``port`` plus an optional | |
271 | ``compass`` point the edge should aim at for the given tail or head node | |
272 | (:ref:`example <btree.py>`). | |
273 | ||
274 | As colons are used to indicate ``port`` and ``compass``, node names with | |
275 | literal colon(s) (``:``) are not supported. Note that there is no such | |
276 | restriction for the ``label`` argument, so you can work around by choosing a | |
277 | colon-free ``name`` together with the wanted ``label``: | |
278 | ||
279 | .. code:: python | |
280 | ||
281 | >>> cpp = Digraph('C++') | |
282 | ||
283 | >>> cpp.node('A', 'std::string') | |
284 | >>> cpp.node('B', '"spam"') | |
285 | ||
286 | >>> cpp.edge('A', 'B') | |
287 | ||
288 | >>> print(cpp.source) # doctest: +NORMALIZE_WHITESPACE | |
289 | digraph "C++" { | |
290 | A [label="std::string"] | |
291 | B [label="\"spam\""] | |
292 | A -> B | |
293 | } | |
294 | ||
295 | ||
263 | 296 | Backslash escapes |
264 | 297 | ----------------- |
265 | 298 | |
444 | 477 | To add arbitrary statements to the created DOT_ source, use the |
445 | 478 | :attr:`~.Graph.body` attribute of the :class:`.Graph` or :class:`.Digraph` |
446 | 479 | object. It holds the verbatim list of lines to be written to the source file. |
447 | Use its ``append()`` or ``extend()`` method: | |
480 | Use its ``append()``- or ``extend()``-method: | |
448 | 481 | |
449 | 482 | .. code:: python |
450 | 483 |
40 | 40 | ] |
41 | 41 | |
42 | 42 | __title__ = 'graphviz' |
43 | __version__ = '0.14' | |
43 | __version__ = '0.14.1' | |
44 | 44 | __author__ = 'Sebastian Bank <sebastian.bank@uni-leipzig.de>' |
45 | 45 | __license__ = 'MIT, see LICENSE.txt' |
46 | 46 | __copyright__ = 'Copyright (c) 2013-2020 Sebastian Bank' |
132 | 132 | self.body.append(line) |
133 | 133 | |
134 | 134 | def edge(self, tail_name, head_name, label=None, _attributes=None, **attrs): |
135 | """Create an edge between two nodes. | |
136 | ||
137 | Args: | |
138 | tail_name: Start node identifier. | |
139 | head_name: End node identifier. | |
135 | """Create an edge between two nodes. | |
136 | ||
137 | Args: | |
138 | tail_name: Start node identifier (format: ``node[:port[:compass]]``). | |
139 | head_name: End node identifier (format: ``node[:port[:compass]]``). | |
140 | 140 | label: Caption to be displayed near the edge. |
141 | 141 | attrs: Any additional edge attributes (must be strings). |
142 | ||
143 | Note: | |
144 | The ``tail_name`` and ``head_name`` strings are separated by | |
145 | (optional) colon(s) into ``node`` name, ``port`` name, and | |
146 | ``compass`` (e.g. ``sw``). | |
147 | See :ref:`details in the User Guide <ports>`. | |
142 | 148 | """ |
143 | 149 | tail_name = self._quote_edge(tail_name) |
144 | 150 | head_name = self._quote_edge(head_name) |
150 | 156 | """Create a bunch of edges. |
151 | 157 | |
152 | 158 | Args: |
153 | tail_head_iter: Iterable of ``(tail_name, head_name)`` pairs. | |
159 | tail_head_iter: Iterable of ``(tail_name, head_name)`` pairs (format:``node[:port[:compass]]``). | |
160 | ||
161 | ||
162 | Note: | |
163 | The ``tail_name`` and ``head_name`` strings are separated by | |
164 | (optional) colon(s) into ``node`` name, ``port`` name, and | |
165 | ``compass`` (e.g. ``sw``). | |
166 | See :ref:`details in the User Guide <ports>`. | |
154 | 167 | """ |
155 | 168 | edge = self._edge_plain |
156 | 169 | quote = self._quote_edge |
197 | 210 | |
198 | 211 | See the :ref:`usage examples in the User Guide <subgraphs>`. |
199 | 212 | |
200 | .. note:: | |
213 | Note: | |
201 | 214 | If the ``name`` of the subgraph begins with ``'cluster'`` (all lowercase) |
202 | 215 | the layout engine will treat it as a special cluster subgraph. |
203 | 216 | """ |
254 | 267 | strict (bool): Rendering should merge multi-edges. |
255 | 268 | |
256 | 269 | Note: |
257 | All parameters are optional and can be changed under their | |
270 | All parameters are `optional` and can be changed under their | |
258 | 271 | corresponding attribute name after instance creation. |
259 | 272 | """ |
260 | 273 |
0 | 0 | Metadata-Version: 2.1 |
1 | 1 | Name: graphviz |
2 | Version: 0.14 | |
2 | Version: 0.14.1 | |
3 | 3 | Summary: Simple Python interface for Graphviz |
4 | 4 | Home-page: https://github.com/xflr6/graphviz |
5 | 5 | Author: Sebastian Bank |
16 | 16 | docs/manual.rst |
17 | 17 | docs/notebooks.rst |
18 | 18 | docs/pet-shop.png |
19 | docs/requirements.txt | |
20 | 19 | docs/round-table.png |
21 | 20 | docs/_static/angles.svg |
22 | 21 | docs/_static/btree.svg |
6 | 6 | twine |
7 | 7 | |
8 | 8 | [docs] |
9 | sphinx>=1.7 | |
9 | sphinx>=1.8 | |
10 | 10 | sphinx-rtd-theme |
11 | 11 | |
12 | 12 | [test] |
13 | 13 | mock>=3 |
14 | pytest!=3.10.0,>=3.4 | |
15 | pytest-mock>=1.8 | |
14 | pytest>=4 | |
15 | pytest-mock>=2 | |
16 | 16 | pytest-cov |
7 | 7 | universal = 1 |
8 | 8 | |
9 | 9 | [tool:pytest] |
10 | minversion = 3.4 | |
10 | minversion = 4 | |
11 | 11 | testpaths = README.rst docs graphviz tests |
12 | 12 | addopts = |
13 | 13 | --doctest-modules --doctest-glob='*.rst' --ignore=docs/conf.py |
4 | 4 | |
5 | 5 | setup( |
6 | 6 | name='graphviz', |
7 | version='0.14', | |
7 | version='0.14.1', | |
8 | 8 | author='Sebastian Bank', |
9 | 9 | author_email='sebastian.bank@uni-leipzig.de', |
10 | 10 | description='Simple Python interface for Graphviz', |
21 | 21 | python_requires='>=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*', |
22 | 22 | extras_require={ |
23 | 23 | 'dev': ['tox>=3', 'flake8', 'pep8-naming', 'wheel', 'twine'], |
24 | 'test': ['mock>=3', 'pytest>=3.4,!=3.10.0', 'pytest-mock>=1.8', 'pytest-cov'], | |
25 | 'docs': ['sphinx>=1.7', 'sphinx-rtd-theme'], | |
24 | 'test': ['mock>=3', 'pytest>=4', 'pytest-mock>=2', 'pytest-cov'], | |
25 | 'docs': ['sphinx>=1.8', 'sphinx-rtd-theme'], | |
26 | 26 | }, |
27 | 27 | long_description=io.open('README.rst', encoding='utf-8').read(), |
28 | 28 | classifiers=[ |