| Home | Trees | Index | Help |
|---|
| Package qm :: Module structured_text |
|
Functions for parsing, processing, and formatting Python structured text.
See "Structured Text Formatting Rules":http://www.python.org/sigs/doc-sig/stext.html for more information.| Classes | |
|---|---|
Formatter |
Interface for output formatters for the 'StructuredTextProcessor'. |
HtmlFormatter |
Formatter for generating HTML from structured text. |
StructuredTextProcessor |
Parser and formatter for Python structured text. |
TextFormatter |
Formatter for generating plain text from structured text. |
| Function Summary | |
|---|---|
__entity_char_replacement(match,
replacement_map)
| |
Return 'text' with special characters converted to HTML entities. | |
Return the first line of 'structured_text'. | |
Return the first paragraph of 'structured_text'. | |
Split 'structured_text' into paragraphs. | |
Return the contents of 'structured_text' minus the first line. | |
Return 'structured_text' formatted as HTML. | |
Return 'structured_text' formatted as plain text. | |
| Variable Summary | |
|---|---|
str |
html_help_text = '\n<h4>Structured Text</h4>\n\n<p>Struc...
|
| Function Details |
|---|
escape_html_entities(text)Return 'text' with special characters converted to HTML entities. |
get_first(structured_text)Return the first line of 'structured_text'. By convention, the first line of a structured text description is a short summary. |
get_first_paragraph(structured_text)Return the first paragraph of 'structured_text'. 'structured_text' -- A string consisting of structured text. returns -- A string of structured text that is the first paragraph of the 'structured_text'. |
get_paragraphs(structured_text)Split 'structured_text' into paragraphs. 'structured_text' -- A string consisting of structured text. returns -- A sequence of pagraphs of structured text. Each element in the sequence corresponds to a successive pagraph in the 'structured_text'. If 'structured_text' is the empty string, the sequence returned will consist of a single paragraph, itself empty. |
get_rest(structured_text)Return the contents of 'structured_text' minus the first line. |
to_html(structured_text)Return 'structured_text' formatted as HTML. |
to_text(structured_text, width=78, indent=0)Return 'structured_text' formatted as plain text. 'width' -- The width of the text (including the indentation). 'indent' -- The width of the block indentation of the formatted output. |
| Variable Details |
|---|
| Home | Trees | Index | Help |
|---|
| Generated by Epydoc 2.1 on Thu Sep 27 15:49:07 2007 | http://epydoc.sf.net |