File: wx.lib.pubsub.utils.topictreeprinter.txt

package info (click to toggle)
wxpython4.0 4.2.0%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 232,540 kB
  • sloc: cpp: 958,937; python: 233,059; ansic: 150,441; makefile: 51,662; sh: 8,687; perl: 1,563; javascript: 584; php: 326; xml: 200
file content (90 lines) | stat: -rw-r--r-- 3,159 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
.. wxPython Phoenix documentation

   This file was generated by Phoenix's sphinx generator and associated
   tools, do not edit by hand.

   Copyright: (c) 2011-2020 by Total Control Software
   License:   wxWindows License

.. include:: headings.inc

.. module:: wx.lib.pubsub.utils.topictreeprinter

.. currentmodule:: wx.lib.pubsub.utils.topictreeprinter

.. highlight:: python



.. _wx.lib.pubsub.utils.topictreeprinter:

==========================================================================================================================================
|phoenix_title|  **wx.lib.pubsub.utils.topictreeprinter**
==========================================================================================================================================

Output various aspects of topic tree to string or file.

:copyright: Copyright since 2006 by Oliver Schoenborn, all rights reserved.
:license: BSD, see LICENSE_BSD_Simple.txt for details.


|function_summary| Functions Summary
====================================

================================================================================ ================================================================================
:func:`~wx.lib.pubsub.utils.topictreeprinter.printTreeDocs`                      Print out the topic tree to a file (or file-like object like a
================================================================================ ================================================================================


|


|class_summary| Classes Summary
===============================

================================================================================ ================================================================================
:ref:`~wx.lib.pubsub.utils.topictreeprinter.TopicTreePrinter`                    Example topic tree visitor that prints a prettified representation
================================================================================ ================================================================================


|


.. toctree::
   :maxdepth: 1
   :hidden:

   wx.lib.pubsub.utils.topictreeprinter.TopicTreePrinter





Functions
------------

.. function:: printTreeDocs(rootTopic=None, topicMgr=None, \*\*kwargs)

   Print out the topic tree to a file (or file-like object like a
   StringIO), starting at rootTopic. If root topic should be root of
   whole tree, get it from pub.getDefaultTopicTreeRoot().
   The treeVisitor is an instance of pub.TopicTreeTraverser.
   
   Printing the tree docs would normally involve this::
   
       from pubsub import pub
       from pubsub.utils.topictreeprinter import TopicTreePrinter
       traverser = pub.TopicTreeTraverser( TopicTreePrinter(**kwargs) )
       traverser.traverse( pub.getDefaultTopicTreeRoot() )
   
   With printTreeDocs, it looks like this::
   
       from pubsub import pub
       from pubsub.utils import printTreeDocs
       printTreeDocs()
   
   The kwargs are the same as for TopicTreePrinter constructor:
   extra(None), width(70), indentStep(4), bulletTopic, bulletTopicItem,
   bulletTopicArg, fileObj(stdout). If fileObj not given, stdout is used.