Package doconce :: Module doconce
[hide private]
[frames] | no frames]

Module doconce

source code

Functions [hide private]
 
debugpr(out) source code
 
supported_format_names() source code
 
syntax_check(filestr, format) source code
 
make_one_line_paragraphs(filestr, format) source code
 
insert_code_from_file(filestr, format) source code
 
exercises(filestr, format) source code
 
parse_keyword(keyword, format)
Parse a keyword for a description list when the keyword may represent information about an argument to a function or a variable in a program:
source code
 
typeset_tables(filestr, format)
Translate tables with pipes and dashes to a list of row-column values.
source code
 
typeset_lists(filestr, format, debug_info=[])
Go through filestr and parse all lists and typeset them correctly.
source code
 
handle_figures(filestr, format) source code
 
handle_cross_referencing(filestr, format) source code
 
handle_index_and_bib(filestr, format, has_title)
Process idx{...
source code
 
interpret_authors(filestr, format) source code
 
typeset_authors(filestr, format) source code
 
inline_tag_subst(filestr, format)
Deal with all inline tags by substitution.
source code
 
subst_away_inline_comments(filestr) source code
 
subst_class_func_mod(filestr, format) source code
 
file2file(in_filename, format, out_filename)
Perform the transformation of a doconce file, stored in in_filename, to a given format (html, latex, etc.), written to out_filename.
source code
 
doconce2format4docstrings(filestr, format)
Run doconce2format on all doc strings in a Python file.
source code
 
doconce2format(filestr, format) source code
 
preprocess(filename, format, preprocessor_options=[])
Run mako or the preprocess script on filename and return the name of the resulting file.
source code
 
main() source code
Variables [hide private]
  debug = False
  __package__ = 'doconce'
Function Details [hide private]

parse_keyword(keyword, format)

source code 

Parse a keyword for a description list when the keyword may represent information about an argument to a function or a variable in a program:

 - argument x: x coordinate (float).
 - keyword argument tolerance: error tolerance (float).
 - return: corresponding y coordinate (float).

typeset_tables(filestr, format)

source code 

Translate tables with pipes and dashes to a list of row-column values. Horizontal rules become a row ['horizontal rule'] in the list. The list is easily translated to various output formats by other modules.

typeset_lists(filestr, format, debug_info=[])

source code 

Go through filestr and parse all lists and typeset them correctly. This function must be called after all (verbatim) code and tex blocks have been removed from the file. This function also treats comment lines and blank lines.

handle_index_and_bib(filestr, format, has_title)

source code 

Process idx{...} and cite{...} instructions.

file2file(in_filename, format, out_filename)

source code 

Perform the transformation of a doconce file, stored in in_filename, to a given format (html, latex, etc.), written to out_filename. This is the "main" function in the module.

preprocess(filename, format, preprocessor_options=[])

source code 

Run mako or the preprocess script on filename and return the name of the resulting file. The preprocessor_options list contains the preprocessor options given on the command line. In addition, the preprocessor option FORMAT (=format) is always defined.