MCPcopy Index your code
hub / github.com/python/cpython / __init__

Method __init__

Lib/idlelib/help.py:57–70  ·  view source on GitHub ↗
(self, text)

Source from the content-addressed store, hash-verified

55 the handle_starttag and handle_endtags methods, might have to also.
56 """
57 def __init__(self, text):
58 HTMLParser.__init__(self, convert_charrefs=True)
59 self.text = text # Text widget we're rendering into.
60 self.tags = '' # Current block level text tags to apply.
61 self.chartags = '' # Current character level text tags.
62 self.hdrlink = False # Exclude html header links.
63 self.level = 0 # Track indentation level.
64 self.pre = False # Displaying preformatted text?
65 self.hprefix = '' # Heading prefix (like '25.5'?) to remove.
66 self.nested_dl = False # In a nested <dl>?
67 self.simplelist = False # In a simple list (no double spacing)?
68 self.toc = [] # Pair headers with text indexes for toc.
69 self.header = '' # Text within header tags for toc.
70 self.prevtag = None # Previous tag info (opener?, tag).
71
72 def indent(self, amt=1):
73 "Change indent (+1, 0, -1) and tags."

Callers

nothing calls this directly

Calls 1

__init__Method · 0.45

Tested by

no test coverage detected