Package docutils :: Module core
[show private | hide private]
[frames | no frames]

Module docutils.core

Calling the publish_* convenience functions (or instantiating a Publisher object) with component names will result in default behavior. For custom behavior (setting component options), create custom component objects first, and pass them to publish_*/Publisher.
Classes
Publisher A facade encapsulating the high-level logic of a Docutils system.

Function Summary
  publish_cmdline(reader, reader_name, parser, parser_name, writer, writer_name, settings, settings_spec, settings_overrides, enable_exit, argv, usage, description)
Set up & run a Publisher.
  publish_file(source, source_path, destination, destination_path, reader, reader_name, parser, parser_name, writer, writer_name, settings, settings_spec, settings_overrides, enable_exit)
Set up & run a Publisher.
  publish_string(source, source_path, destination_path, reader, reader_name, parser, parser_name, writer, writer_name, settings, settings_spec, settings_overrides, enable_exit)
Set up & run a Publisher, and return the string output.

Variable Summary
str default_description = 'Reads from <source> (default is s...
str default_usage = '%prog [options] [<source> [<destination...

Function Details

publish_cmdline(reader=None, reader_name='standalone', parser=None, parser_name='restructuredtext', writer=None, writer_name='pseudoxml', settings=None, settings_spec=None, settings_overrides=None, enable_exit=1, argv=None, usage='%prog [options] [<source> [<destination>]]', description='Reads from <source> (default is stdin) and writes to <de...)

Set up & run a Publisher. For command-line front ends.

Parameters:

publish_file(source=None, source_path=None, destination=None, destination_path=None, reader=None, reader_name='standalone', parser=None, parser_name='restructuredtext', writer=None, writer_name='pseudoxml', settings=None, settings_spec=None, settings_overrides=None, enable_exit=None)

Set up & run a Publisher. For programmatic use with file-like I/O.

Parameters:

publish_string(source, source_path=None, destination_path=None, reader=None, reader_name='standalone', parser=None, parser_name='restructuredtext', writer=None, writer_name='pseudoxml', settings=None, settings_spec=None, settings_overrides=None, enable_exit=None)

Set up & run a Publisher, and return the string output. For programmatic use with string I/O.

For encoded string output, be sure to set the "output_encoding" setting to the desired encoding. Set it to "unicode" for unencoded Unicode string output. Here's how:

publish_string(..., settings_overrides={'output_encoding': 'unicode'})

Similarly for Unicode string input (source):

publish_string(..., settings_overrides={'input_encoding': 'unicode'})

Parameters:


Variable Details

default_description

Type:
str
Value:
'Reads from <source> (default is stdin) and writes to <destination> (d\
efault is stdout).'                                                    

default_usage

Type:
str
Value:
'%prog [options] [<source> [<destination>]]'                           

Generated by Epydoc 2.0 on Tue Jul 22 05:30:38 2003 http://epydoc.sf.net