An HTML structured text formatter.
Methods
|
|
__str__
_str
dl
head
normal
ol
pre
table
ul
|
|
__str__
|
__str__ (
self,
extra_dl=re.compile( "</dl>\n<dl>" ),
extra_ul=re.compile( "</ul>\n<ul>" ),
extra_ol=re.compile( "</ol>\n<ol>" ),
)
Return an HTML string representation of the structured text data.
|
|
_str
|
_str (
self,
structure,
level,
bullet=ts_regex.compile( '[ \t\n]*[o*-][ \t\n]+\([^\0]*\)' ).match_group,
example=ts_regex.compile( '[\0- ]examples?:[\0- ]*$' ).search,
dl=ts_regex.compile( '\([^\n]+\)[ \t]+--[ \t\n]+\([^\0]*\)' ).match_group,
nl=ts_regex.compile( '\n' ).search,
ol=ts_regex.compile( '[ \t]*\(\([0-9]+\|[%s]+\)[.)]\)+[ \t\n]+\([^\0]*\|$\)' % string.letters ).match_group,
olp=ts_regex.compile( '[ \t]*([0-9]+)[ \t\n]+\([^\0]*\|$\)' ).match_group,
)
|
|
dl
|
dl (
self,
before,
t,
d,
after,
)
|
|
head
|
head (
self,
before,
t,
level,
d,
)
|
|
normal
|
normal (
self,
before,
p,
after,
)
|
|
ol
|
ol (
self,
before,
p,
after,
)
|
|
pre
|
pre (
self,
structure,
tagged=0,
)
|
|
table
|
table (
self,
before,
table,
after,
)
|
|
ul
|
ul (
self,
before,
p,
after,
)
|
|