add docutils modules to helpers

This commit is contained in:
Dmitry Jemerov
2011-05-02 14:18:03 +02:00
parent 30bd5ede01
commit 437870d782
150 changed files with 38936 additions and 0 deletions
+204
View File
@@ -0,0 +1,204 @@
# $Id: __init__.py 6364 2010-07-07 14:56:53Z grubert $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
This is the Docutils (Python Documentation Utilities) package.
Package Structure
=================
Modules:
- __init__.py: Contains component base classes, exception classes, and
Docutils version information.
- core.py: Contains the ``Publisher`` class and ``publish_*()`` convenience
functions.
- frontend.py: Runtime settings (command-line interface, configuration files)
processing, for Docutils front-ends.
- io.py: Provides a uniform API for low-level input and output.
- nodes.py: Docutils document tree (doctree) node class library.
- statemachine.py: A finite state machine specialized for
regular-expression-based text filters.
- urischemes.py: Contains a complete mapping of known URI addressing
scheme names to descriptions.
- utils.py: Contains the ``Reporter`` system warning class and miscellaneous
utilities.
Subpackages:
- languages: Language-specific mappings of terms.
- parsers: Syntax-specific input parser modules or packages.
- readers: Context-specific input handlers which understand the data
source and manage a parser.
- transforms: Modules used by readers and writers to modify DPS
doctrees.
- writers: Format-specific output translators.
"""
__docformat__ = 'reStructuredText'
__version__ = '0.8'
"""``major.minor.micro`` version number. The micro number is bumped for API
changes, for new functionality, and for interim project releases. The minor
number is bumped whenever there is a significant project release. The major
number will be bumped when the project is feature-complete, and perhaps if
there is a major change in the design."""
__version_details__ = 'snapshot 2010-09-01, r6395'
"""Extra version details (e.g. 'snapshot 2005-05-29, r3410', 'repository',
'release'), modified automatically & manually."""
class ApplicationError(StandardError): pass
class DataError(ApplicationError): pass
class SettingsSpec:
"""
Runtime setting specification base class.
SettingsSpec subclass objects used by `docutils.frontend.OptionParser`.
"""
settings_spec = ()
"""Runtime settings specification. Override in subclasses.
Defines runtime settings and associated command-line options, as used by
`docutils.frontend.OptionParser`. This is a tuple of:
- Option group title (string or `None` which implies no group, just a list
of single options).
- Description (string or `None`).
- A sequence of option tuples. Each consists of:
- Help text (string)
- List of option strings (e.g. ``['-Q', '--quux']``).
- Dictionary of keyword arguments sent to the OptionParser/OptionGroup
``add_option`` method.
Runtime setting names are derived implicitly from long option names
('--a-setting' becomes ``settings.a_setting``) or explicitly from the
'dest' keyword argument.
Most settings will also have a 'validator' keyword & function. The
validator function validates setting values (from configuration files
and command-line option arguments) and converts them to appropriate
types. For example, the ``docutils.frontend.validate_boolean``
function, **required by all boolean settings**, converts true values
('1', 'on', 'yes', and 'true') to 1 and false values ('0', 'off',
'no', 'false', and '') to 0. Validators need only be set once per
setting. See the `docutils.frontend.validate_*` functions.
See the optparse docs for more details.
- More triples of group title, description, options, as many times as
needed. Thus, `settings_spec` tuples can be simply concatenated.
"""
settings_defaults = None
"""A dictionary of defaults for settings not in `settings_spec` (internal
settings, intended to be inaccessible by command-line and config file).
Override in subclasses."""
settings_default_overrides = None
"""A dictionary of auxiliary defaults, to override defaults for settings
defined in other components. Override in subclasses."""
relative_path_settings = ()
"""Settings containing filesystem paths. Override in subclasses.
Settings listed here are to be interpreted relative to the current working
directory."""
config_section = None
"""The name of the config file section specific to this component
(lowercase, no brackets). Override in subclasses."""
config_section_dependencies = None
"""A list of names of config file sections that are to be applied before
`config_section`, in order (from general to specific). In other words,
the settings in `config_section` are to be overlaid on top of the settings
from these sections. The "general" section is assumed implicitly.
Override in subclasses."""
class TransformSpec:
"""
Runtime transform specification base class.
TransformSpec subclass objects used by `docutils.transforms.Transformer`.
"""
def get_transforms(self):
"""Transforms required by this class. Override in subclasses."""
if self.default_transforms != ():
import warnings
warnings.warn('default_transforms attribute deprecated.\n'
'Use get_transforms() method instead.',
DeprecationWarning)
return list(self.default_transforms)
return []
# Deprecated; for compatibility.
default_transforms = ()
unknown_reference_resolvers = ()
"""List of functions to try to resolve unknown references. Unknown
references have a 'refname' attribute which doesn't correspond to any
target in the document. Called when the transforms in
`docutils.tranforms.references` are unable to find a correct target. The
list should contain functions which will try to resolve unknown
references, with the following signature::
def reference_resolver(node):
'''Returns boolean: true if resolved, false if not.'''
If the function is able to resolve the reference, it should also remove
the 'refname' attribute and mark the node as resolved::
del node['refname']
node.resolved = 1
Each function must have a "priority" attribute which will affect the order
the unknown_reference_resolvers are run::
reference_resolver.priority = 100
Override in subclasses."""
class Component(SettingsSpec, TransformSpec):
"""Base class for Docutils components."""
component_type = None
"""Name of the component type ('reader', 'parser', 'writer'). Override in
subclasses."""
supported = ()
"""Names for this component. Override in subclasses."""
def supports(self, format):
"""
Is `format` supported by this component?
To be used by transforms to ask the dependent component if it supports
a certain input context or output format.
"""
return format in self.supported
+36
View File
@@ -0,0 +1,36 @@
# $Id: _compat.py 5908 2009-04-21 13:43:23Z goodger $
# Author: Georg Brandl <georg@python.org>
# Copyright: This module has been placed in the public domain.
"""
Python 2/3 compatibility definitions.
This module currently provides the following helper symbols:
* bytes (name of byte string type; str in 2.x, bytes in 3.x)
* b (function converting a string literal to an ASCII byte string;
can be also used to convert a Unicode string into a byte string)
* u_prefix (unicode repr prefix, 'u' in 2.x, nothing in 3.x)
* BytesIO (a StringIO class that works with bytestrings)
"""
import sys
if sys.version_info < (3,0):
b = bytes = str
u_prefix = 'u'
from StringIO import StringIO as BytesIO
else:
import builtins
bytes = builtins.bytes
u_prefix = ''
def b(s):
if isinstance(s, str):
return s.encode('latin1')
elif isinstance(s, bytes):
return s
else:
raise TypeError("Invalid argument %r for b()" % (s,))
# using this hack since 2to3 "fixes" the relative import
# when using ``from io import BytesIO``
BytesIO = __import__('io').BytesIO
@@ -0,0 +1,133 @@
#!/usr/bin/env python
# -*- coding: utf8 -*-
# string_template_compat.py: string.Template for Python <= 2.4
# =====================================================
# This is just an excerpt of the standard string module to provide backwards
# compatibility.
import re as _re
class _multimap:
"""Helper class for combining multiple mappings.
Used by .{safe_,}substitute() to combine the mapping and keyword
arguments.
"""
def __init__(self, primary, secondary):
self._primary = primary
self._secondary = secondary
def __getitem__(self, key):
try:
return self._primary[key]
except KeyError:
return self._secondary[key]
class _TemplateMetaclass(type):
pattern = r"""
%(delim)s(?:
(?P<escaped>%(delim)s) | # Escape sequence of two delimiters
(?P<named>%(id)s) | # delimiter and a Python identifier
{(?P<braced>%(id)s)} | # delimiter and a braced identifier
(?P<invalid>) # Other ill-formed delimiter exprs
)
"""
def __init__(cls, name, bases, dct):
super(_TemplateMetaclass, cls).__init__(name, bases, dct)
if 'pattern' in dct:
pattern = cls.pattern
else:
pattern = _TemplateMetaclass.pattern % {
'delim' : _re.escape(cls.delimiter),
'id' : cls.idpattern,
}
cls.pattern = _re.compile(pattern, _re.IGNORECASE | _re.VERBOSE)
class Template:
"""A string class for supporting $-substitutions."""
__metaclass__ = _TemplateMetaclass
delimiter = '$'
idpattern = r'[_a-z][_a-z0-9]*'
def __init__(self, template):
self.template = template
# Search for $$, $identifier, ${identifier}, and any bare $'s
def _invalid(self, mo):
i = mo.start('invalid')
lines = self.template[:i].splitlines(True)
if not lines:
colno = 1
lineno = 1
else:
colno = i - len(''.join(lines[:-1]))
lineno = len(lines)
raise ValueError('Invalid placeholder in string: line %d, col %d' %
(lineno, colno))
def substitute(self, *args, **kws):
if len(args) > 1:
raise TypeError('Too many positional arguments')
if not args:
mapping = kws
elif kws:
mapping = _multimap(kws, args[0])
else:
mapping = args[0]
# Helper function for .sub()
def convert(mo):
# Check the most common path first.
named = mo.group('named') or mo.group('braced')
if named is not None:
val = mapping[named]
# We use this idiom instead of str() because the latter will
# fail if val is a Unicode containing non-ASCII characters.
return '%s' % (val,)
if mo.group('escaped') is not None:
return self.delimiter
if mo.group('invalid') is not None:
self._invalid(mo)
raise ValueError('Unrecognized named group in pattern',
self.pattern)
return self.pattern.sub(convert, self.template)
def safe_substitute(self, *args, **kws):
if len(args) > 1:
raise TypeError('Too many positional arguments')
if not args:
mapping = kws
elif kws:
mapping = _multimap(kws, args[0])
else:
mapping = args[0]
# Helper function for .sub()
def convert(mo):
named = mo.group('named')
if named is not None:
try:
# We use this idiom instead of str() because the latter
# will fail if val is a Unicode containing non-ASCII
return '%s' % (mapping[named],)
except KeyError:
return self.delimiter + named
braced = mo.group('braced')
if braced is not None:
try:
return '%s' % (mapping[braced],)
except KeyError:
return self.delimiter + '{' + braced + '}'
if mo.group('escaped') is not None:
return self.delimiter
if mo.group('invalid') is not None:
return self.delimiter
raise ValueError('Unrecognized named group in pattern',
self.pattern)
return self.pattern.sub(convert, self.template)
+642
View File
@@ -0,0 +1,642 @@
# $Id: core.py 6294 2010-03-26 10:47:00Z milde $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
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`. See `The Docutils Publisher`_.
.. _The Docutils Publisher: http://docutils.sf.net/docs/api/publisher.html
"""
__docformat__ = 'reStructuredText'
import sys
import pprint
from docutils import __version__, __version_details__, SettingsSpec
from docutils import frontend, io, utils, readers, writers
from docutils.frontend import OptionParser
from docutils.transforms import Transformer
import docutils.readers.doctree
class Publisher:
"""
A facade encapsulating the high-level logic of a Docutils system.
"""
def __init__(self, reader=None, parser=None, writer=None,
source=None, source_class=io.FileInput,
destination=None, destination_class=io.FileOutput,
settings=None):
"""
Initial setup. If any of `reader`, `parser`, or `writer` are not
specified, the corresponding ``set_...`` method should be called with
a component name (`set_reader` sets the parser as well).
"""
self.document = None
"""The document tree (`docutils.nodes` objects)."""
self.reader = reader
"""A `docutils.readers.Reader` instance."""
self.parser = parser
"""A `docutils.parsers.Parser` instance."""
self.writer = writer
"""A `docutils.writers.Writer` instance."""
for component in 'reader', 'parser', 'writer':
assert not isinstance(getattr(self, component), str), (
'passed string "%s" as "%s" parameter; pass an instance, '
'or use the "%s_name" parameter instead (in '
'docutils.core.publish_* convenience functions).'
% (getattr(self, component), component, component))
self.source = source
"""The source of input data, a `docutils.io.Input` instance."""
self.source_class = source_class
"""The class for dynamically created source objects."""
self.destination = destination
"""The destination for docutils output, a `docutils.io.Output`
instance."""
self.destination_class = destination_class
"""The class for dynamically created destination objects."""
self.settings = settings
"""An object containing Docutils settings as instance attributes.
Set by `self.process_command_line()` or `self.get_settings()`."""
def set_reader(self, reader_name, parser, parser_name):
"""Set `self.reader` by name."""
reader_class = readers.get_reader_class(reader_name)
self.reader = reader_class(parser, parser_name)
self.parser = self.reader.parser
def set_writer(self, writer_name):
"""Set `self.writer` by name."""
writer_class = writers.get_writer_class(writer_name)
self.writer = writer_class()
def set_components(self, reader_name, parser_name, writer_name):
if self.reader is None:
self.set_reader(reader_name, self.parser, parser_name)
if self.parser is None:
if self.reader.parser is None:
self.reader.set_parser(parser_name)
self.parser = self.reader.parser
if self.writer is None:
self.set_writer(writer_name)
def setup_option_parser(self, usage=None, description=None,
settings_spec=None, config_section=None,
**defaults):
if config_section:
if not settings_spec:
settings_spec = SettingsSpec()
settings_spec.config_section = config_section
parts = config_section.split()
if len(parts) > 1 and parts[-1] == 'application':
settings_spec.config_section_dependencies = ['applications']
#@@@ Add self.source & self.destination to components in future?
option_parser = OptionParser(
components=(self.parser, self.reader, self.writer, settings_spec),
defaults=defaults, read_config_files=1,
usage=usage, description=description)
return option_parser
def get_settings(self, usage=None, description=None,
settings_spec=None, config_section=None, **defaults):
"""
Set and return default settings (overrides in `defaults` dict).
Set components first (`self.set_reader` & `self.set_writer`).
Explicitly setting `self.settings` disables command line option
processing from `self.publish()`.
"""
option_parser = self.setup_option_parser(
usage, description, settings_spec, config_section, **defaults)
self.settings = option_parser.get_default_values()
return self.settings
def process_programmatic_settings(self, settings_spec,
settings_overrides,
config_section):
if self.settings is None:
defaults = (settings_overrides or {}).copy()
# Propagate exceptions by default when used programmatically:
defaults.setdefault('traceback', 1)
self.get_settings(settings_spec=settings_spec,
config_section=config_section,
**defaults)
def process_command_line(self, argv=None, usage=None, description=None,
settings_spec=None, config_section=None,
**defaults):
"""
Pass an empty list to `argv` to avoid reading `sys.argv` (the
default).
Set components first (`self.set_reader` & `self.set_writer`).
"""
option_parser = self.setup_option_parser(
usage, description, settings_spec, config_section, **defaults)
if argv is None:
argv = sys.argv[1:]
self.settings = option_parser.parse_args(argv)
def set_io(self, source_path=None, destination_path=None):
if self.source is None:
self.set_source(source_path=source_path)
if self.destination is None:
self.set_destination(destination_path=destination_path)
def set_source(self, source=None, source_path=None):
if source_path is None:
source_path = self.settings._source
else:
self.settings._source = source_path
self.source = self.source_class(
source=source, source_path=source_path,
encoding=self.settings.input_encoding)
def set_destination(self, destination=None, destination_path=None):
if destination_path is None:
destination_path = self.settings._destination
else:
self.settings._destination = destination_path
self.destination = self.destination_class(
destination=destination, destination_path=destination_path,
encoding=self.settings.output_encoding,
error_handler=self.settings.output_encoding_error_handler)
def apply_transforms(self):
self.document.transformer.populate_from_components(
(self.source, self.reader, self.reader.parser, self.writer,
self.destination))
self.document.transformer.apply_transforms()
def publish(self, argv=None, usage=None, description=None,
settings_spec=None, settings_overrides=None,
config_section=None, enable_exit_status=None):
"""
Process command line options and arguments (if `self.settings` not
already set), run `self.reader` and then `self.writer`. Return
`self.writer`'s output.
"""
exit = None
try:
if self.settings is None:
self.process_command_line(
argv, usage, description, settings_spec, config_section,
**(settings_overrides or {}))
self.set_io()
self.document = self.reader.read(self.source, self.parser,
self.settings)
self.apply_transforms()
output = self.writer.write(self.document, self.destination)
self.writer.assemble_parts()
except SystemExit, error:
exit = 1
exit_status = error.code
except Exception, error:
if not self.settings: # exception too early to report nicely
raise
if self.settings.traceback: # Propagate exceptions?
self.debugging_dumps()
raise
self.report_Exception(error)
exit = 1
exit_status = 1
self.debugging_dumps()
if (enable_exit_status and self.document
and (self.document.reporter.max_level
>= self.settings.exit_status_level)):
sys.exit(self.document.reporter.max_level + 10)
elif exit:
sys.exit(exit_status)
return output
def debugging_dumps(self):
if not self.document:
return
if self.settings.dump_settings:
print >>sys.stderr, '\n::: Runtime settings:'
print >>sys.stderr, pprint.pformat(self.settings.__dict__)
if self.settings.dump_internals:
print >>sys.stderr, '\n::: Document internals:'
print >>sys.stderr, pprint.pformat(self.document.__dict__)
if self.settings.dump_transforms:
print >>sys.stderr, '\n::: Transforms applied:'
print >>sys.stderr, (' (priority, transform class, '
'pending node details, keyword args)')
print >>sys.stderr, pprint.pformat(
[(priority, '%s.%s' % (xclass.__module__, xclass.__name__),
pending and pending.details, kwargs)
for priority, xclass, pending, kwargs
in self.document.transformer.applied])
if self.settings.dump_pseudo_xml:
print >>sys.stderr, '\n::: Pseudo-XML:'
print >>sys.stderr, self.document.pformat().encode(
'raw_unicode_escape')
def report_Exception(self, error):
if isinstance(error, utils.SystemMessage):
self.report_SystemMessage(error)
elif isinstance(error, UnicodeEncodeError):
self.report_UnicodeError(error)
else:
print >>sys.stderr, '%s: %s' % (error.__class__.__name__, error)
print >>sys.stderr, ("""\
Exiting due to error. Use "--traceback" to diagnose.
Please report errors to <docutils-users@lists.sf.net>.
Include "--traceback" output, Docutils version (%s [%s]),
Python version (%s), your OS type & version, and the
command line used.""" % (__version__, __version_details__,
sys.version.split()[0]))
def report_SystemMessage(self, error):
print >>sys.stderr, ('Exiting due to level-%s (%s) system message.'
% (error.level,
utils.Reporter.levels[error.level]))
def report_UnicodeError(self, error):
data = error.object[error.start:error.end]
sys.stderr.write(
'%s: %s\n'
'\n'
'The specified output encoding (%s) cannot\n'
'handle all of the output.\n'
'Try setting "--output-encoding-error-handler" to\n'
'\n'
'* "xmlcharrefreplace" (for HTML & XML output);\n'
' the output will contain "%s" and should be usable.\n'
'* "backslashreplace" (for other output formats);\n'
' look for "%s" in the output.\n'
'* "replace"; look for "?" in the output.\n'
'\n'
'"--output-encoding-error-handler" is currently set to "%s".\n'
'\n'
'Exiting due to error. Use "--traceback" to diagnose.\n'
'If the advice above doesn\'t eliminate the error,\n'
'please report it to <docutils-users@lists.sf.net>.\n'
'Include "--traceback" output, Docutils version (%s),\n'
'Python version (%s), your OS type & version, and the\n'
'command line used.\n'
% (error.__class__.__name__, error,
self.settings.output_encoding,
data.encode('ascii', 'xmlcharrefreplace'),
data.encode('ascii', 'backslashreplace'),
self.settings.output_encoding_error_handler,
__version__, sys.version.split()[0]))
default_usage = '%prog [options] [<source> [<destination>]]'
default_description = ('Reads from <source> (default is stdin) and writes to '
'<destination> (default is stdout). See '
'<http://docutils.sf.net/docs/user/config.html> for '
'the full reference.')
def 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, config_section=None,
enable_exit_status=1, argv=None,
usage=default_usage, description=default_description):
"""
Set up & run a `Publisher` for command-line-based file I/O (input and
output file paths taken automatically from the command line). Return the
encoded string output also.
Parameters: see `publish_programmatically` for the remainder.
- `argv`: Command-line argument list to use instead of ``sys.argv[1:]``.
- `usage`: Usage string, output if there's a problem parsing the command
line.
- `description`: Program description, output for the "--help" option
(along with command-line option descriptions).
"""
pub = Publisher(reader, parser, writer, settings=settings)
pub.set_components(reader_name, parser_name, writer_name)
output = pub.publish(
argv, usage, description, settings_spec, settings_overrides,
config_section=config_section, enable_exit_status=enable_exit_status)
return output
def 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,
config_section=None, enable_exit_status=None):
"""
Set up & run a `Publisher` for programmatic use with file-like I/O.
Return the encoded string output also.
Parameters: see `publish_programmatically`.
"""
output, pub = publish_programmatically(
source_class=io.FileInput, source=source, source_path=source_path,
destination_class=io.FileOutput,
destination=destination, destination_path=destination_path,
reader=reader, reader_name=reader_name,
parser=parser, parser_name=parser_name,
writer=writer, writer_name=writer_name,
settings=settings, settings_spec=settings_spec,
settings_overrides=settings_overrides,
config_section=config_section,
enable_exit_status=enable_exit_status)
return output
def 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, config_section=None,
enable_exit_status=None):
"""
Set up & run a `Publisher` for programmatic use with string I/O. Return
the encoded string or Unicode string output.
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 one way::
publish_string(..., settings_overrides={'output_encoding': 'unicode'})
Similarly for Unicode string input (`source`)::
publish_string(..., settings_overrides={'input_encoding': 'unicode'})
Parameters: see `publish_programmatically`.
"""
output, pub = publish_programmatically(
source_class=io.StringInput, source=source, source_path=source_path,
destination_class=io.StringOutput,
destination=None, destination_path=destination_path,
reader=reader, reader_name=reader_name,
parser=parser, parser_name=parser_name,
writer=writer, writer_name=writer_name,
settings=settings, settings_spec=settings_spec,
settings_overrides=settings_overrides,
config_section=config_section,
enable_exit_status=enable_exit_status)
return output
def publish_parts(source, source_path=None, source_class=io.StringInput,
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, config_section=None,
enable_exit_status=None):
"""
Set up & run a `Publisher`, and return a dictionary of document parts.
Dictionary keys are the names of parts, and values are Unicode strings;
encoding is up to the client. For programmatic use with string I/O.
For encoded string input, be sure to set the 'input_encoding' setting to
the desired encoding. Set it to 'unicode' for unencoded Unicode string
input. Here's how::
publish_parts(..., settings_overrides={'input_encoding': 'unicode'})
Parameters: see `publish_programmatically`.
"""
output, pub = publish_programmatically(
source=source, source_path=source_path, source_class=source_class,
destination_class=io.StringOutput,
destination=None, destination_path=destination_path,
reader=reader, reader_name=reader_name,
parser=parser, parser_name=parser_name,
writer=writer, writer_name=writer_name,
settings=settings, settings_spec=settings_spec,
settings_overrides=settings_overrides,
config_section=config_section,
enable_exit_status=enable_exit_status)
return pub.writer.parts
def publish_doctree(source, source_path=None,
source_class=io.StringInput,
reader=None, reader_name='standalone',
parser=None, parser_name='restructuredtext',
settings=None, settings_spec=None,
settings_overrides=None, config_section=None,
enable_exit_status=None):
"""
Set up & run a `Publisher` for programmatic use with string I/O.
Return the document tree.
For encoded string input, be sure to set the 'input_encoding' setting to
the desired encoding. Set it to 'unicode' for unencoded Unicode string
input. Here's one way::
publish_doctree(..., settings_overrides={'input_encoding': 'unicode'})
Parameters: see `publish_programmatically`.
"""
pub = Publisher(reader=reader, parser=parser, writer=None,
settings=settings,
source_class=source_class,
destination_class=io.NullOutput)
pub.set_components(reader_name, parser_name, 'null')
pub.process_programmatic_settings(
settings_spec, settings_overrides, config_section)
pub.set_source(source, source_path)
pub.set_destination(None, None)
output = pub.publish(enable_exit_status=enable_exit_status)
return pub.document
def publish_from_doctree(document, destination_path=None,
writer=None, writer_name='pseudoxml',
settings=None, settings_spec=None,
settings_overrides=None, config_section=None,
enable_exit_status=None):
"""
Set up & run a `Publisher` to render from an existing document
tree data structure, for programmatic use with string I/O. Return
the encoded string output.
Note that document.settings is overridden; if you want to use the settings
of the original `document`, pass settings=document.settings.
Also, new document.transformer and document.reporter objects are
generated.
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 one way::
publish_from_doctree(
..., settings_overrides={'output_encoding': 'unicode'})
Parameters: `document` is a `docutils.nodes.document` object, an existing
document tree.
Other parameters: see `publish_programmatically`.
"""
reader = docutils.readers.doctree.Reader(parser_name='null')
pub = Publisher(reader, None, writer,
source=io.DocTreeInput(document),
destination_class=io.StringOutput, settings=settings)
if not writer and writer_name:
pub.set_writer(writer_name)
pub.process_programmatic_settings(
settings_spec, settings_overrides, config_section)
pub.set_destination(None, destination_path)
return pub.publish(enable_exit_status=enable_exit_status)
def publish_cmdline_to_binary(reader=None, reader_name='standalone',
parser=None, parser_name='restructuredtext',
writer=None, writer_name='pseudoxml',
settings=None, settings_spec=None,
settings_overrides=None, config_section=None,
enable_exit_status=1, argv=None,
usage=default_usage, description=default_description,
destination=None, destination_class=io.BinaryFileOutput
):
"""
Set up & run a `Publisher` for command-line-based file I/O (input and
output file paths taken automatically from the command line). Return the
encoded string output also.
This is just like publish_cmdline, except that it uses
io.BinaryFileOutput instead of io.FileOutput.
Parameters: see `publish_programmatically` for the remainder.
- `argv`: Command-line argument list to use instead of ``sys.argv[1:]``.
- `usage`: Usage string, output if there's a problem parsing the command
line.
- `description`: Program description, output for the "--help" option
(along with command-line option descriptions).
"""
pub = Publisher(reader, parser, writer, settings=settings,
destination_class=destination_class)
pub.set_components(reader_name, parser_name, writer_name)
output = pub.publish(
argv, usage, description, settings_spec, settings_overrides,
config_section=config_section, enable_exit_status=enable_exit_status)
return output
def publish_programmatically(source_class, source, source_path,
destination_class, destination, destination_path,
reader, reader_name,
parser, parser_name,
writer, writer_name,
settings, settings_spec,
settings_overrides, config_section,
enable_exit_status):
"""
Set up & run a `Publisher` for custom programmatic use. Return the
encoded string output and the Publisher object.
Applications should not need to call this function directly. If it does
seem to be necessary to call this function directly, please write to the
Docutils-develop mailing list
<http://docutils.sf.net/docs/user/mailing-lists.html#docutils-develop>.
Parameters:
* `source_class` **required**: The class for dynamically created source
objects. Typically `io.FileInput` or `io.StringInput`.
* `source`: Type depends on `source_class`:
- If `source_class` is `io.FileInput`: Either a file-like object
(must have 'read' and 'close' methods), or ``None``
(`source_path` is opened). If neither `source` nor
`source_path` are supplied, `sys.stdin` is used.
- If `source_class` is `io.StringInput` **required**: The input
string, either an encoded 8-bit string (set the
'input_encoding' setting to the correct encoding) or a Unicode
string (set the 'input_encoding' setting to 'unicode').
* `source_path`: Type depends on `source_class`:
- `io.FileInput`: Path to the input file, opened if no `source`
supplied.
- `io.StringInput`: Optional. Path to the file or object that produced
`source`. Only used for diagnostic output.
* `destination_class` **required**: The class for dynamically created
destination objects. Typically `io.FileOutput` or `io.StringOutput`.
* `destination`: Type depends on `destination_class`:
- `io.FileOutput`: Either a file-like object (must have 'write' and
'close' methods), or ``None`` (`destination_path` is opened). If
neither `destination` nor `destination_path` are supplied,
`sys.stdout` is used.
- `io.StringOutput`: Not used; pass ``None``.
* `destination_path`: Type depends on `destination_class`:
- `io.FileOutput`: Path to the output file. Opened if no `destination`
supplied.
- `io.StringOutput`: Path to the file or object which will receive the
output; optional. Used for determining relative paths (stylesheets,
source links, etc.).
* `reader`: A `docutils.readers.Reader` object.
* `reader_name`: Name or alias of the Reader class to be instantiated if
no `reader` supplied.
* `parser`: A `docutils.parsers.Parser` object.
* `parser_name`: Name or alias of the Parser class to be instantiated if
no `parser` supplied.
* `writer`: A `docutils.writers.Writer` object.
* `writer_name`: Name or alias of the Writer class to be instantiated if
no `writer` supplied.
* `settings`: A runtime settings (`docutils.frontend.Values`) object, for
dotted-attribute access to runtime settings. It's the end result of the
`SettingsSpec`, config file, and option processing. If `settings` is
passed, it's assumed to be complete and no further setting/config/option
processing is done.
* `settings_spec`: A `docutils.SettingsSpec` subclass or object. Provides
extra application-specific settings definitions independently of
components. In other words, the application becomes a component, and
its settings data is processed along with that of the other components.
Used only if no `settings` specified.
* `settings_overrides`: A dictionary containing application-specific
settings defaults that override the defaults of other components.
Used only if no `settings` specified.
* `config_section`: A string, the name of the configuration file section
for this application. Overrides the ``config_section`` attribute
defined by `settings_spec`. Used only if no `settings` specified.
* `enable_exit_status`: Boolean; enable exit status at end of processing?
"""
pub = Publisher(reader, parser, writer, settings=settings,
source_class=source_class,
destination_class=destination_class)
pub.set_components(reader_name, parser_name, writer_name)
pub.process_programmatic_settings(
settings_spec, settings_overrides, config_section)
pub.set_source(source, source_path)
pub.set_destination(destination, destination_path)
output = pub.publish(enable_exit_status=enable_exit_status)
return output, pub
+5
View File
@@ -0,0 +1,5 @@
# This configuration file is to prevent tools/buildhtml.py from
# processing text files in and below this directory.
[buildhtml application]
prune: .
+96
View File
@@ -0,0 +1,96 @@
# $Id: examples.py 4800 2006-11-12 18:02:01Z goodger $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
This module contains practical examples of Docutils client code.
Importing this module from client code is not recommended; its contents are
subject to change in future Docutils releases. Instead, it is recommended
that you copy and paste the parts you need into your own code, modifying as
necessary.
"""
from docutils import core, io
def html_parts(input_string, source_path=None, destination_path=None,
input_encoding='unicode', doctitle=1, initial_header_level=1):
"""
Given an input string, returns a dictionary of HTML document parts.
Dictionary keys are the names of parts, and values are Unicode strings;
encoding is up to the client.
Parameters:
- `input_string`: A multi-line text string; required.
- `source_path`: Path to the source file or object. Optional, but useful
for diagnostic output (system messages).
- `destination_path`: Path to the file or object which will receive the
output; optional. Used for determining relative paths (stylesheets,
source links, etc.).
- `input_encoding`: The encoding of `input_string`. If it is an encoded
8-bit string, provide the correct encoding. If it is a Unicode string,
use "unicode", the default.
- `doctitle`: Disable the promotion of a lone top-level section title to
document title (and subsequent section title to document subtitle
promotion); enabled by default.
- `initial_header_level`: The initial level for header elements (e.g. 1
for "<h1>").
"""
overrides = {'input_encoding': input_encoding,
'doctitle_xform': doctitle,
'initial_header_level': initial_header_level}
parts = core.publish_parts(
source=input_string, source_path=source_path,
destination_path=destination_path,
writer_name='html', settings_overrides=overrides)
return parts
def html_body(input_string, source_path=None, destination_path=None,
input_encoding='unicode', output_encoding='unicode',
doctitle=1, initial_header_level=1):
"""
Given an input string, returns an HTML fragment as a string.
The return value is the contents of the <body> element.
Parameters (see `html_parts()` for the remainder):
- `output_encoding`: The desired encoding of the output. If a Unicode
string is desired, use the default value of "unicode" .
"""
parts = html_parts(
input_string=input_string, source_path=source_path,
destination_path=destination_path,
input_encoding=input_encoding, doctitle=doctitle,
initial_header_level=initial_header_level)
fragment = parts['html_body']
if output_encoding != 'unicode':
fragment = fragment.encode(output_encoding)
return fragment
def internals(input_string, source_path=None, destination_path=None,
input_encoding='unicode', settings_overrides=None):
"""
Return the document tree and publisher, for exploring Docutils internals.
Parameters: see `html_parts()`.
"""
if settings_overrides:
overrides = settings_overrides.copy()
else:
overrides = {}
overrides['input_encoding'] = input_encoding
output, pub = core.publish_programmatically(
source_class=io.StringInput, source=input_string,
source_path=source_path,
destination_class=io.NullOutput, destination=None,
destination_path=destination_path,
reader=None, reader_name='standalone',
parser=None, parser_name='restructuredtext',
writer=None, writer_name='null',
settings=None, settings_spec=None, settings_overrides=overrides,
config_section=None, enable_exit_status=None)
return pub.writer.document, pub
+786
View File
@@ -0,0 +1,786 @@
# $Id: frontend.py 6205 2009-11-30 08:11:08Z milde $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
Command-line and common processing for Docutils front-end tools.
Exports the following classes:
* `OptionParser`: Standard Docutils command-line processing.
* `Option`: Customized version of `optparse.Option`; validation support.
* `Values`: Runtime settings; objects are simple structs
(``object.attribute``). Supports cumulative list settings (attributes).
* `ConfigParser`: Standard Docutils config file processing.
Also exports the following functions:
* Option callbacks: `store_multiple`, `read_config_file`.
* Setting validators: `validate_encoding`,
`validate_encoding_error_handler`,
`validate_encoding_and_error_handler`, `validate_boolean`,
`validate_threshold`, `validate_colon_separated_string_list`,
`validate_dependency_file`.
* `make_paths_absolute`.
* SettingSpec manipulation: `filter_settings_spec`.
"""
__docformat__ = 'reStructuredText'
import os
import os.path
import sys
import warnings
import ConfigParser as CP
import codecs
import docutils
import docutils.utils
import docutils.nodes
import optparse
from optparse import SUPPRESS_HELP
def store_multiple(option, opt, value, parser, *args, **kwargs):
"""
Store multiple values in `parser.values`. (Option callback.)
Store `None` for each attribute named in `args`, and store the value for
each key (attribute name) in `kwargs`.
"""
for attribute in args:
setattr(parser.values, attribute, None)
for key, value in kwargs.items():
setattr(parser.values, key, value)
def read_config_file(option, opt, value, parser):
"""
Read a configuration file during option processing. (Option callback.)
"""
try:
new_settings = parser.get_config_file_settings(value)
except ValueError, error:
parser.error(error)
parser.values.update(new_settings, parser)
def validate_encoding(setting, value, option_parser,
config_parser=None, config_section=None):
try:
codecs.lookup(value)
except LookupError:
raise (LookupError('setting "%s": unknown encoding: "%s"'
% (setting, value)),
None, sys.exc_info()[2])
return value
def validate_encoding_error_handler(setting, value, option_parser,
config_parser=None, config_section=None):
try:
codecs.lookup_error(value)
except AttributeError: # TODO: remove (only needed prior to Python 2.3)
if value not in ('strict', 'ignore', 'replace', 'xmlcharrefreplace'):
raise (LookupError(
'unknown encoding error handler: "%s" (choices: '
'"strict", "ignore", "replace", or "xmlcharrefreplace")' % value),
None, sys.exc_info()[2])
except LookupError:
raise (LookupError(
'unknown encoding error handler: "%s" (choices: '
'"strict", "ignore", "replace", "backslashreplace", '
'"xmlcharrefreplace", and possibly others; see documentation for '
'the Python ``codecs`` module)' % value),
None, sys.exc_info()[2])
return value
def validate_encoding_and_error_handler(
setting, value, option_parser, config_parser=None, config_section=None):
"""
Side-effect: if an error handler is included in the value, it is inserted
into the appropriate place as if it was a separate setting/option.
"""
if ':' in value:
encoding, handler = value.split(':')
validate_encoding_error_handler(
setting + '_error_handler', handler, option_parser,
config_parser, config_section)
if config_parser:
config_parser.set(config_section, setting + '_error_handler',
handler)
else:
setattr(option_parser.values, setting + '_error_handler', handler)
else:
encoding = value
validate_encoding(setting, encoding, option_parser,
config_parser, config_section)
return encoding
def validate_boolean(setting, value, option_parser,
config_parser=None, config_section=None):
if isinstance(value, unicode):
try:
return option_parser.booleans[value.strip().lower()]
except KeyError:
raise (LookupError('unknown boolean value: "%s"' % value),
None, sys.exc_info()[2])
return value
def validate_nonnegative_int(setting, value, option_parser,
config_parser=None, config_section=None):
value = int(value)
if value < 0:
raise ValueError('negative value; must be positive or zero')
return value
def validate_threshold(setting, value, option_parser,
config_parser=None, config_section=None):
try:
return int(value)
except ValueError:
try:
return option_parser.thresholds[value.lower()]
except (KeyError, AttributeError):
raise (LookupError('unknown threshold: %r.' % value),
None, sys.exc_info[2])
def validate_colon_separated_string_list(
setting, value, option_parser, config_parser=None, config_section=None):
if isinstance(value, unicode):
value = value.split(':')
else:
last = value.pop()
value.extend(last.split(':'))
return value
def validate_url_trailing_slash(
setting, value, option_parser, config_parser=None, config_section=None):
if not value:
return './'
elif value.endswith('/'):
return value
else:
return value + '/'
def validate_dependency_file(setting, value, option_parser,
config_parser=None, config_section=None):
try:
return docutils.utils.DependencyList(value)
except IOError:
return docutils.utils.DependencyList(None)
def validate_strip_class(setting, value, option_parser,
config_parser=None, config_section=None):
if config_parser: # validate all values
class_values = value
else: # just validate the latest value
class_values = [value[-1]]
for class_value in class_values:
normalized = docutils.nodes.make_id(class_value)
if class_value != normalized:
raise ValueError('invalid class value %r (perhaps %r?)'
% (class_value, normalized))
return value
def make_paths_absolute(pathdict, keys, base_path=None):
"""
Interpret filesystem path settings relative to the `base_path` given.
Paths are values in `pathdict` whose keys are in `keys`. Get `keys` from
`OptionParser.relative_path_settings`.
"""
if base_path is None:
base_path = os.getcwd()
for key in keys:
if key in pathdict:
value = pathdict[key]
if isinstance(value, list):
value = [make_one_path_absolute(base_path, path)
for path in value]
elif value:
value = make_one_path_absolute(base_path, value)
pathdict[key] = value
def make_one_path_absolute(base_path, path):
return os.path.abspath(os.path.join(base_path, path))
def filter_settings_spec(settings_spec, *exclude, **replace):
"""Return a copy of `settings_spec` excluding/replacing some settings.
`settings_spec` is a tuple of configuration settings with a structure
described for docutils.SettingsSpec.settings_spec.
Optional positional arguments are names of to-be-excluded settings.
Keyword arguments are option specification replacements.
(See the html4strict writer for an example.)
"""
settings = list(settings_spec)
# every third item is a sequence of option tuples
for i in range(2, len(settings), 3):
newopts = []
for opt_spec in settings[i]:
# opt_spec is ("<help>", [<option strings>], {<keyword args>})
opt_name = [opt_string[2:].replace('-', '_')
for opt_string in opt_spec[1]
if opt_string.startswith('--')
][0]
if opt_name in exclude:
continue
if opt_name in replace.keys():
newopts.append(replace[opt_name])
else:
newopts.append(opt_spec)
settings[i] = tuple(newopts)
return tuple(settings)
class Values(optparse.Values):
"""
Updates list attributes by extension rather than by replacement.
Works in conjunction with the `OptionParser.lists` instance attribute.
"""
def __init__(self, *args, **kwargs):
optparse.Values.__init__(self, *args, **kwargs)
if (not hasattr(self, 'record_dependencies')
or self.record_dependencies is None):
# Set up dependency list, in case it is needed.
self.record_dependencies = docutils.utils.DependencyList()
def update(self, other_dict, option_parser):
if isinstance(other_dict, Values):
other_dict = other_dict.__dict__
other_dict = other_dict.copy()
for setting in option_parser.lists.keys():
if (hasattr(self, setting) and setting in other_dict):
value = getattr(self, setting)
if value:
value += other_dict[setting]
del other_dict[setting]
self._update_loose(other_dict)
def copy(self):
"""Return a shallow copy of `self`."""
return self.__class__(defaults=self.__dict__)
class Option(optparse.Option):
ATTRS = optparse.Option.ATTRS + ['validator', 'overrides']
def process(self, opt, value, values, parser):
"""
Call the validator function on applicable settings and
evaluate the 'overrides' option.
Extends `optparse.Option.process`.
"""
result = optparse.Option.process(self, opt, value, values, parser)
setting = self.dest
if setting:
if self.validator:
value = getattr(values, setting)
try:
new_value = self.validator(setting, value, parser)
except Exception, error:
raise (optparse.OptionValueError(
'Error in option "%s":\n %s: %s'
% (opt, error.__class__.__name__, error)),
None, sys.exc_info()[2])
setattr(values, setting, new_value)
if self.overrides:
setattr(values, self.overrides, None)
return result
class OptionParser(optparse.OptionParser, docutils.SettingsSpec):
"""
Parser for command-line and library use. The `settings_spec`
specification here and in other Docutils components are merged to build
the set of command-line options and runtime settings for this process.
Common settings (defined below) and component-specific settings must not
conflict. Short options are reserved for common settings, and components
are restrict to using long options.
"""
standard_config_files = [
'/etc/docutils.conf', # system-wide
'./docutils.conf', # project-specific
'~/.docutils'] # user-specific
"""Docutils configuration files, using ConfigParser syntax. Filenames
will be tilde-expanded later. Later files override earlier ones."""
threshold_choices = 'info 1 warning 2 error 3 severe 4 none 5'.split()
"""Possible inputs for for --report and --halt threshold values."""
thresholds = {'info': 1, 'warning': 2, 'error': 3, 'severe': 4, 'none': 5}
"""Lookup table for --report and --halt threshold values."""
booleans={'1': 1, 'on': 1, 'yes': 1, 'true': 1,
'0': 0, 'off': 0, 'no': 0, 'false': 0, '': 0}
"""Lookup table for boolean configuration file settings."""
try:
default_error_encoding = sys.stderr.encoding or 'ascii'
except AttributeError:
default_error_encoding = 'ascii'
default_error_encoding_error_handler = 'backslashreplace'
settings_spec = (
'General Docutils Options',
None,
(('Specify the document title as metadata.',
['--title'], {}),
('Include a "Generated by Docutils" credit and link.',
['--generator', '-g'], {'action': 'store_true',
'validator': validate_boolean}),
('Do not include a generator credit.',
['--no-generator'], {'action': 'store_false', 'dest': 'generator'}),
('Include the date at the end of the document (UTC).',
['--date', '-d'], {'action': 'store_const', 'const': '%Y-%m-%d',
'dest': 'datestamp'}),
('Include the time & date (UTC).',
['--time', '-t'], {'action': 'store_const',
'const': '%Y-%m-%d %H:%M UTC',
'dest': 'datestamp'}),
('Do not include a datestamp of any kind.',
['--no-datestamp'], {'action': 'store_const', 'const': None,
'dest': 'datestamp'}),
('Include a "View document source" link.',
['--source-link', '-s'], {'action': 'store_true',
'validator': validate_boolean}),
('Use <URL> for a source link; implies --source-link.',
['--source-url'], {'metavar': '<URL>'}),
('Do not include a "View document source" link.',
['--no-source-link'],
{'action': 'callback', 'callback': store_multiple,
'callback_args': ('source_link', 'source_url')}),
('Link from section headers to TOC entries. (default)',
['--toc-entry-backlinks'],
{'dest': 'toc_backlinks', 'action': 'store_const', 'const': 'entry',
'default': 'entry'}),
('Link from section headers to the top of the TOC.',
['--toc-top-backlinks'],
{'dest': 'toc_backlinks', 'action': 'store_const', 'const': 'top'}),
('Disable backlinks to the table of contents.',
['--no-toc-backlinks'],
{'dest': 'toc_backlinks', 'action': 'store_false'}),
('Link from footnotes/citations to references. (default)',
['--footnote-backlinks'],
{'action': 'store_true', 'default': 1,
'validator': validate_boolean}),
('Disable backlinks from footnotes and citations.',
['--no-footnote-backlinks'],
{'dest': 'footnote_backlinks', 'action': 'store_false'}),
('Enable section numbering by Docutils. (default)',
['--section-numbering'],
{'action': 'store_true', 'dest': 'sectnum_xform',
'default': 1, 'validator': validate_boolean}),
('Disable section numbering by Docutils.',
['--no-section-numbering'],
{'action': 'store_false', 'dest': 'sectnum_xform'}),
('Remove comment elements from the document tree.',
['--strip-comments'],
{'action': 'store_true', 'validator': validate_boolean}),
('Leave comment elements in the document tree. (default)',
['--leave-comments'],
{'action': 'store_false', 'dest': 'strip_comments'}),
('Remove all elements with classes="<class>" from the document tree. '
'Warning: potentially dangerous; use with caution. '
'(Multiple-use option.)',
['--strip-elements-with-class'],
{'action': 'append', 'dest': 'strip_elements_with_classes',
'metavar': '<class>', 'validator': validate_strip_class}),
('Remove all classes="<class>" attributes from elements in the '
'document tree. Warning: potentially dangerous; use with caution. '
'(Multiple-use option.)',
['--strip-class'],
{'action': 'append', 'dest': 'strip_classes',
'metavar': '<class>', 'validator': validate_strip_class}),
('Report system messages at or higher than <level>: "info" or "1", '
'"warning"/"2" (default), "error"/"3", "severe"/"4", "none"/"5"',
['--report', '-r'], {'choices': threshold_choices, 'default': 2,
'dest': 'report_level', 'metavar': '<level>',
'validator': validate_threshold}),
('Report all system messages. (Same as "--report=1".)',
['--verbose', '-v'], {'action': 'store_const', 'const': 1,
'dest': 'report_level'}),
('Report no system messages. (Same as "--report=5".)',
['--quiet', '-q'], {'action': 'store_const', 'const': 5,
'dest': 'report_level'}),
('Halt execution at system messages at or above <level>. '
'Levels as in --report. Default: 4 (severe).',
['--halt'], {'choices': threshold_choices, 'dest': 'halt_level',
'default': 4, 'metavar': '<level>',
'validator': validate_threshold}),
('Halt at the slightest problem. Same as "--halt=info".',
['--strict'], {'action': 'store_const', 'const': 1,
'dest': 'halt_level'}),
('Enable a non-zero exit status for non-halting system messages at '
'or above <level>. Default: 5 (disabled).',
['--exit-status'], {'choices': threshold_choices,
'dest': 'exit_status_level',
'default': 5, 'metavar': '<level>',
'validator': validate_threshold}),
('Enable debug-level system messages and diagnostics.',
['--debug'], {'action': 'store_true', 'validator': validate_boolean}),
('Disable debug output. (default)',
['--no-debug'], {'action': 'store_false', 'dest': 'debug'}),
('Send the output of system messages to <file>.',
['--warnings'], {'dest': 'warning_stream', 'metavar': '<file>'}),
('Enable Python tracebacks when Docutils is halted.',
['--traceback'], {'action': 'store_true', 'default': None,
'validator': validate_boolean}),
('Disable Python tracebacks. (default)',
['--no-traceback'], {'dest': 'traceback', 'action': 'store_false'}),
('Specify the encoding and optionally the '
'error handler of input text. Default: <locale-dependent>:strict.',
['--input-encoding', '-i'],
{'metavar': '<name[:handler]>',
'validator': validate_encoding_and_error_handler}),
('Specify the error handler for undecodable characters. '
'Choices: "strict" (default), "ignore", and "replace".',
['--input-encoding-error-handler'],
{'default': 'strict', 'validator': validate_encoding_error_handler}),
('Specify the text encoding and optionally the error handler for '
'output. Default: UTF-8:strict.',
['--output-encoding', '-o'],
{'metavar': '<name[:handler]>', 'default': 'utf-8',
'validator': validate_encoding_and_error_handler}),
('Specify error handler for unencodable output characters; '
'"strict" (default), "ignore", "replace", '
'"xmlcharrefreplace", "backslashreplace".',
['--output-encoding-error-handler'],
{'default': 'strict', 'validator': validate_encoding_error_handler}),
('Specify text encoding and error handler for error output. '
'Default: %s:%s.'
% (default_error_encoding, default_error_encoding_error_handler),
['--error-encoding', '-e'],
{'metavar': '<name[:handler]>', 'default': default_error_encoding,
'validator': validate_encoding_and_error_handler}),
('Specify the error handler for unencodable characters in '
'error output. Default: %s.'
% default_error_encoding_error_handler,
['--error-encoding-error-handler'],
{'default': default_error_encoding_error_handler,
'validator': validate_encoding_error_handler}),
('Specify the language (as 2-letter code). Default: en.',
['--language', '-l'], {'dest': 'language_code', 'default': 'en',
'metavar': '<name>'}),
('Write output file dependencies to <file>.',
['--record-dependencies'],
{'metavar': '<file>', 'validator': validate_dependency_file,
'default': None}), # default set in Values class
('Read configuration settings from <file>, if it exists.',
['--config'], {'metavar': '<file>', 'type': 'string',
'action': 'callback', 'callback': read_config_file}),
("Show this program's version number and exit.",
['--version', '-V'], {'action': 'version'}),
('Show this help message and exit.',
['--help', '-h'], {'action': 'help'}),
# Typically not useful for non-programmatical use:
(SUPPRESS_HELP, ['--id-prefix'], {'default': ''}),
(SUPPRESS_HELP, ['--auto-id-prefix'], {'default': 'id'}),
# Hidden options, for development use only:
(SUPPRESS_HELP, ['--dump-settings'], {'action': 'store_true'}),
(SUPPRESS_HELP, ['--dump-internals'], {'action': 'store_true'}),
(SUPPRESS_HELP, ['--dump-transforms'], {'action': 'store_true'}),
(SUPPRESS_HELP, ['--dump-pseudo-xml'], {'action': 'store_true'}),
(SUPPRESS_HELP, ['--expose-internal-attribute'],
{'action': 'append', 'dest': 'expose_internals',
'validator': validate_colon_separated_string_list}),
(SUPPRESS_HELP, ['--strict-visitor'], {'action': 'store_true'}),
))
"""Runtime settings and command-line options common to all Docutils front
ends. Setting specs specific to individual Docutils components are also
used (see `populate_from_components()`)."""
settings_defaults = {'_disable_config': None,
'_source': None,
'_destination': None,
'_config_files': None}
"""Defaults for settings that don't have command-line option equivalents."""
relative_path_settings = ('warning_stream',)
config_section = 'general'
version_template = ('%%prog (Docutils %s [%s], Python %s, on %s)'
% (docutils.__version__, docutils.__version_details__,
sys.version.split()[0], sys.platform))
"""Default version message."""
def __init__(self, components=(), defaults=None, read_config_files=None,
*args, **kwargs):
"""
`components` is a list of Docutils components each containing a
``.settings_spec`` attribute. `defaults` is a mapping of setting
default overrides.
"""
self.lists = {}
"""Set of list-type settings."""
self.config_files = []
"""List of paths of applied configuration files."""
optparse.OptionParser.__init__(
self, option_class=Option, add_help_option=None,
formatter=optparse.TitledHelpFormatter(width=78),
*args, **kwargs)
if not self.version:
self.version = self.version_template
# Make an instance copy (it will be modified):
self.relative_path_settings = list(self.relative_path_settings)
self.components = (self,) + tuple(components)
self.populate_from_components(self.components)
self.set_defaults_from_dict(defaults or {})
if read_config_files and not self.defaults['_disable_config']:
try:
config_settings = self.get_standard_config_settings()
except ValueError, error:
self.error(error)
self.set_defaults_from_dict(config_settings.__dict__)
def populate_from_components(self, components):
"""
For each component, first populate from the `SettingsSpec.settings_spec`
structure, then from the `SettingsSpec.settings_defaults` dictionary.
After all components have been processed, check for and populate from
each component's `SettingsSpec.settings_default_overrides` dictionary.
"""
for component in components:
if component is None:
continue
settings_spec = component.settings_spec
self.relative_path_settings.extend(
component.relative_path_settings)
for i in range(0, len(settings_spec), 3):
title, description, option_spec = settings_spec[i:i+3]
if title:
group = optparse.OptionGroup(self, title, description)
self.add_option_group(group)
else:
group = self # single options
for (help_text, option_strings, kwargs) in option_spec:
option = group.add_option(help=help_text, *option_strings,
**kwargs)
if kwargs.get('action') == 'append':
self.lists[option.dest] = 1
if component.settings_defaults:
self.defaults.update(component.settings_defaults)
for component in components:
if component and component.settings_default_overrides:
self.defaults.update(component.settings_default_overrides)
def get_standard_config_files(self):
"""Return list of config files, from environment or standard."""
try:
config_files = os.environ['DOCUTILSCONFIG'].split(os.pathsep)
except KeyError:
config_files = self.standard_config_files
# If 'HOME' is not set, expandvars() requires the 'pwd' module which is
# not available under certain environments, for example, within
# mod_python. The publisher ends up in here, and we need to publish
# from within mod_python. Therefore we need to avoid expanding when we
# are in those environments.
expand = os.path.expanduser
if 'HOME' not in os.environ:
try:
import pwd
except ImportError:
expand = lambda x: x
return [expand(f) for f in config_files if f.strip()]
def get_standard_config_settings(self):
settings = Values()
for filename in self.get_standard_config_files():
settings.update(self.get_config_file_settings(filename), self)
return settings
def get_config_file_settings(self, config_file):
"""Returns a dictionary containing appropriate config file settings."""
parser = ConfigParser()
parser.read(config_file, self)
self.config_files.extend(parser._files)
base_path = os.path.dirname(config_file)
applied = {}
settings = Values()
for component in self.components:
if not component:
continue
for section in (tuple(component.config_section_dependencies or ())
+ (component.config_section,)):
if section in applied:
continue
applied[section] = 1
settings.update(parser.get_section(section), self)
make_paths_absolute(
settings.__dict__, self.relative_path_settings, base_path)
return settings.__dict__
def check_values(self, values, args):
"""Store positional arguments as runtime settings."""
values._source, values._destination = self.check_args(args)
make_paths_absolute(values.__dict__, self.relative_path_settings,
os.getcwd())
values._config_files = self.config_files
return values
def check_args(self, args):
source = destination = None
if args:
source = args.pop(0)
if source == '-': # means stdin
source = None
if args:
destination = args.pop(0)
if destination == '-': # means stdout
destination = None
if args:
self.error('Maximum 2 arguments allowed.')
if source and source == destination:
self.error('Do not specify the same file for both source and '
'destination. It will clobber the source file.')
return source, destination
def set_defaults_from_dict(self, defaults):
self.defaults.update(defaults)
def get_default_values(self):
"""Needed to get custom `Values` instances."""
defaults = Values(self.defaults)
defaults._config_files = self.config_files
return defaults
def get_option_by_dest(self, dest):
"""
Get an option by its dest.
If you're supplying a dest which is shared by several options,
it is undefined which option of those is returned.
A KeyError is raised if there is no option with the supplied
dest.
"""
for group in self.option_groups + [self]:
for option in group.option_list:
if option.dest == dest:
return option
raise KeyError('No option with dest == %r.' % dest)
class ConfigParser(CP.ConfigParser):
old_settings = {
'pep_stylesheet': ('pep_html writer', 'stylesheet'),
'pep_stylesheet_path': ('pep_html writer', 'stylesheet_path'),
'pep_template': ('pep_html writer', 'template')}
"""{old setting: (new section, new setting)} mapping, used by
`handle_old_config`, to convert settings from the old [options] section."""
old_warning = """
The "[option]" section is deprecated. Support for old-format configuration
files may be removed in a future Docutils release. Please revise your
configuration files. See <http://docutils.sf.net/docs/user/config.html>,
section "Old-Format Configuration Files".
"""
not_utf8_error = """\
Unable to read configuration file "%s": content not encoded as UTF-8.
Skipping "%s" configuration file.
"""
def __init__(self, *args, **kwargs):
CP.ConfigParser.__init__(self, *args, **kwargs)
self._files = []
"""List of paths of configuration files read."""
def read(self, filenames, option_parser):
if type(filenames) in (str, unicode):
filenames = [filenames]
for filename in filenames:
try:
# Config files must be UTF-8-encoded:
fp = codecs.open(filename, 'r', 'utf-8')
except IOError:
continue
try:
CP.ConfigParser.readfp(self, fp, filename)
except UnicodeDecodeError:
sys.stderr.write(self.not_utf8_error % (filename, filename))
fp.close()
continue
fp.close()
self._files.append(filename)
if self.has_section('options'):
self.handle_old_config(filename)
self.validate_settings(filename, option_parser)
def handle_old_config(self, filename):
warnings.warn_explicit(self.old_warning, ConfigDeprecationWarning,
filename, 0)
options = self.get_section('options')
if not self.has_section('general'):
self.add_section('general')
for key, value in options.items():
if key in self.old_settings:
section, setting = self.old_settings[key]
if not self.has_section(section):
self.add_section(section)
else:
section = 'general'
setting = key
if not self.has_option(section, setting):
self.set(section, setting, value)
self.remove_section('options')
def validate_settings(self, filename, option_parser):
"""
Call the validator function and implement overrides on all applicable
settings.
"""
for section in self.sections():
for setting in self.options(section):
try:
option = option_parser.get_option_by_dest(setting)
except KeyError:
continue
if option.validator:
value = self.get(section, setting, raw=1)
try:
new_value = option.validator(
setting, value, option_parser,
config_parser=self, config_section=section)
except Exception, error:
raise (ValueError(
'Error in config file "%s", section "[%s]":\n'
' %s: %s\n %s = %s'
% (filename, section, error.__class__.__name__,
error, setting, value)), None, sys.exc_info()[2])
self.set(section, setting, new_value)
if option.overrides:
self.set(section, option.overrides, None)
def optionxform(self, optionstr):
"""
Transform '-' to '_' so the cmdline form of option names can be used.
"""
return optionstr.lower().replace('-', '_')
def get_section(self, section):
"""
Return a given section as a dictionary (empty if the section
doesn't exist).
"""
section_dict = {}
if self.has_section(section):
for option in self.options(section):
section_dict[option] = self.get(section, option, raw=1)
return section_dict
class ConfigDeprecationWarning(DeprecationWarning):
"""Warning for deprecated configuration file features."""
+443
View File
@@ -0,0 +1,443 @@
# $Id: io.py 6269 2010-03-18 22:27:53Z milde $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
I/O classes provide a uniform API for low-level input and output. Subclasses
will exist for a variety of input/output mechanisms.
"""
__docformat__ = 'reStructuredText'
import sys
try:
import locale
except:
pass
import re
import codecs
from docutils import TransformSpec
from docutils._compat import b
class Input(TransformSpec):
"""
Abstract base class for input wrappers.
"""
component_type = 'input'
default_source_path = None
def __init__(self, source=None, source_path=None, encoding=None,
error_handler='strict'):
self.encoding = encoding
"""Text encoding for the input source."""
self.error_handler = error_handler
"""Text decoding error handler."""
self.source = source
"""The source of input data."""
self.source_path = source_path
"""A text reference to the source."""
if not source_path:
self.source_path = self.default_source_path
self.successful_encoding = None
"""The encoding that successfully decoded the source data."""
def __repr__(self):
return '%s: source=%r, source_path=%r' % (self.__class__, self.source,
self.source_path)
def read(self):
raise NotImplementedError
def decode(self, data):
"""
Decode a string, `data`, heuristically.
Raise UnicodeError if unsuccessful.
The client application should call ``locale.setlocale`` at the
beginning of processing::
locale.setlocale(locale.LC_ALL, '')
"""
if self.encoding and self.encoding.lower() == 'unicode':
assert isinstance(data, unicode), (
'input encoding is "unicode" '
'but input is not a unicode object')
if isinstance(data, unicode):
# Accept unicode even if self.encoding != 'unicode'.
return data
if self.encoding:
# We believe the user/application when the encoding is
# explicitly given.
encodings = [self.encoding]
else:
data_encoding = self.determine_encoding_from_data(data)
if data_encoding:
# If the data declares its encoding (explicitly or via a BOM),
# we believe it.
encodings = [data_encoding]
else:
# Apply heuristics only if no encoding is explicitly given and
# no BOM found. Start with UTF-8, because that only matches
# data that *IS* UTF-8:
encodings = ['utf-8']
try:
encodings.append(locale.getlocale()[1])
except:
pass
try:
encodings.append(locale.getdefaultlocale()[1])
except:
pass
# fallback encoding:
encodings.append('latin-1')
error = None
error_details = ''
for enc in encodings:
if not enc:
continue
try:
decoded = unicode(data, enc, self.error_handler)
self.successful_encoding = enc
# Return decoded, removing BOMs.
return decoded.replace(u'\ufeff', u'')
except (UnicodeError, LookupError), tmperror:
error = tmperror # working around Python 3 deleting the
# error variable after the except clause
if error is not None:
error_details = '\n(%s: %s)' % (error.__class__.__name__, error)
raise UnicodeError(
'Unable to decode input data. Tried the following encodings: '
'%s.%s'
% (', '.join([repr(enc) for enc in encodings if enc]),
error_details))
coding_slug = re.compile(b("coding[:=]\s*([-\w.]+)"))
"""Encoding declaration pattern."""
byte_order_marks = ((codecs.BOM_UTF8, 'utf-8'), # actually 'utf-8-sig'
(codecs.BOM_UTF16_BE, 'utf-16-be'),
(codecs.BOM_UTF16_LE, 'utf-16-le'),)
"""Sequence of (start_bytes, encoding) tuples for encoding detection.
The first bytes of input data are checked against the start_bytes strings.
A match indicates the given encoding."""
def determine_encoding_from_data(self, data):
"""
Try to determine the encoding of `data` by looking *in* `data`.
Check for a byte order mark (BOM) or an encoding declaration.
"""
# check for a byte order mark:
for start_bytes, encoding in self.byte_order_marks:
if data.startswith(start_bytes):
return encoding
# check for an encoding declaration pattern in first 2 lines of file:
for line in data.splitlines()[:2]:
match = self.coding_slug.search(line)
if match:
return match.group(1).decode('ascii')
return None
class Output(TransformSpec):
"""
Abstract base class for output wrappers.
"""
component_type = 'output'
default_destination_path = None
def __init__(self, destination=None, destination_path=None,
encoding=None, error_handler='strict'):
self.encoding = encoding
"""Text encoding for the output destination."""
self.error_handler = error_handler or 'strict'
"""Text encoding error handler."""
self.destination = destination
"""The destination for output data."""
self.destination_path = destination_path
"""A text reference to the destination."""
if not destination_path:
self.destination_path = self.default_destination_path
def __repr__(self):
return ('%s: destination=%r, destination_path=%r'
% (self.__class__, self.destination, self.destination_path))
def write(self, data):
"""`data` is a Unicode string, to be encoded by `self.encode`."""
raise NotImplementedError
def encode(self, data):
if self.encoding and self.encoding.lower() == 'unicode':
assert isinstance(data, unicode), (
'the encoding given is "unicode" but the output is not '
'a Unicode string')
return data
if not isinstance(data, unicode):
# Non-unicode (e.g. binary) output.
return data
else:
return data.encode(self.encoding, self.error_handler)
class FileInput(Input):
"""
Input for single, simple file-like objects.
"""
def __init__(self, source=None, source_path=None,
encoding=None, error_handler='strict',
autoclose=1, handle_io_errors=1, mode='rU'):
"""
:Parameters:
- `source`: either a file-like object (which is read directly), or
`None` (which implies `sys.stdin` if no `source_path` given).
- `source_path`: a path to a file, which is opened and then read.
- `encoding`: the expected text encoding of the input file.
- `error_handler`: the encoding error handler to use.
- `autoclose`: close automatically after read (boolean); always
false if `sys.stdin` is the source.
- `handle_io_errors`: summarize I/O errors here, and exit?
- `mode`: how the file is to be opened (see standard function
`open`). The default 'rU' provides universal newline support
for text files.
"""
Input.__init__(self, source, source_path, encoding, error_handler)
self.autoclose = autoclose
self.handle_io_errors = handle_io_errors
if source is None:
if source_path:
# Specify encoding in Python 3
if sys.version_info >= (3,0):
kwargs = {'encoding': self.encoding,
'errors': self.error_handler}
else:
kwargs = {}
try:
self.source = open(source_path, mode, **kwargs)
except IOError, error:
if not handle_io_errors:
raise
print >>sys.stderr, '%s: %s' % (error.__class__.__name__,
error)
print >>sys.stderr, ('Unable to open source file for '
"reading ('%s'). Exiting." %
source_path)
sys.exit(1)
else:
self.source = sys.stdin
self.autoclose = None
if not source_path:
try:
self.source_path = self.source.name
except AttributeError:
pass
def read(self):
"""
Read and decode a single file and return the data (Unicode string).
"""
try:
data = self.source.read()
finally:
if self.autoclose:
self.close()
return self.decode(data)
def readlines(self):
"""
Return lines of a single file as list of Unicode strings.
"""
try:
lines = self.source.readlines()
finally:
if self.autoclose:
self.close()
return [self.decode(line) for line in lines]
def close(self):
self.source.close()
class FileOutput(Output):
"""
Output for single, simple file-like objects.
"""
def __init__(self, destination=None, destination_path=None,
encoding=None, error_handler='strict', autoclose=1,
handle_io_errors=1):
"""
:Parameters:
- `destination`: either a file-like object (which is written
directly) or `None` (which implies `sys.stdout` if no
`destination_path` given).
- `destination_path`: a path to a file, which is opened and then
written.
- `autoclose`: close automatically after write (boolean); always
false if `sys.stdout` is the destination.
"""
Output.__init__(self, destination, destination_path,
encoding, error_handler)
self.opened = 1
self.autoclose = autoclose
self.handle_io_errors = handle_io_errors
if destination is None:
if destination_path:
self.opened = None
else:
self.destination = sys.stdout
self.autoclose = None
if not destination_path:
try:
self.destination_path = self.destination.name
except AttributeError:
pass
def open(self):
# Specify encoding in Python 3.
# (Do not use binary mode ('wb') as this prevents the
# conversion of newlines to the system specific default.)
if sys.version_info >= (3,0):
kwargs = {'encoding': self.encoding,
'errors': self.error_handler}
else:
kwargs = {}
try:
self.destination = open(self.destination_path, 'w', **kwargs)
except IOError, error:
if not self.handle_io_errors:
raise
print >>sys.stderr, '%s: %s' % (error.__class__.__name__,
error)
print >>sys.stderr, ('Unable to open destination file for writing'
" ('%s'). Exiting." % self.destination_path)
sys.exit(1)
self.opened = 1
def write(self, data):
"""Encode `data`, write it to a single file, and return it.
In Python 3, a (unicode) String is returned.
"""
if sys.version_info >= (3,0):
output = data # in py3k, write expects a (Unicode) string
else:
output = self.encode(data)
if not self.opened:
self.open()
try:
self.destination.write(output)
finally:
if self.autoclose:
self.close()
return output
def close(self):
self.destination.close()
self.opened = None
class BinaryFileOutput(FileOutput):
"""
A version of docutils.io.FileOutput which writes to a binary file.
"""
def open(self):
try:
self.destination = open(self.destination_path, 'wb')
except IOError, error:
if not self.handle_io_errors:
raise
print >>sys.stderr, '%s: %s' % (error.__class__.__name__,
error)
print >>sys.stderr, ('Unable to open destination file for writing '
"('%s'). Exiting." % self.destination_path)
sys.exit(1)
self.opened = 1
class StringInput(Input):
"""
Direct string input.
"""
default_source_path = '<string>'
def read(self):
"""Decode and return the source string."""
return self.decode(self.source)
class StringOutput(Output):
"""
Direct string output.
"""
default_destination_path = '<string>'
def write(self, data):
"""Encode `data`, store it in `self.destination`, and return it."""
self.destination = self.encode(data)
return self.destination
class NullInput(Input):
"""
Degenerate input: read nothing.
"""
default_source_path = 'null input'
def read(self):
"""Return a null string."""
return u''
class NullOutput(Output):
"""
Degenerate output: write nothing.
"""
default_destination_path = 'null output'
def write(self, data):
"""Do nothing ([don't even] send data to the bit bucket)."""
pass
class DocTreeInput(Input):
"""
Adapter for document tree input.
The document tree must be passed in the ``source`` parameter.
"""
default_source_path = 'doctree input'
def read(self):
"""Return the document tree."""
return self.source
@@ -0,0 +1,21 @@
# $Id: __init__.py 5618 2008-07-28 08:37:32Z strank $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
# Internationalization details are documented in
# <http://docutils.sf.net/docs/howto/i18n.html>.
"""
This package contains modules for language-dependent features of Docutils.
"""
__docformat__ = 'reStructuredText'
_languages = {}
def get_language(language_code):
if language_code in _languages:
return _languages[language_code]
module = __import__(language_code, globals(), locals())
_languages[language_code] = module
return module
+60
View File
@@ -0,0 +1,60 @@
# $Id: en.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
English-language mappings for language-dependent features of Docutils.
"""
__docformat__ = 'reStructuredText'
labels = {
# fixed: language-dependent
'author': 'Author',
'authors': 'Authors',
'organization': 'Organization',
'address': 'Address',
'contact': 'Contact',
'version': 'Version',
'revision': 'Revision',
'status': 'Status',
'date': 'Date',
'copyright': 'Copyright',
'dedication': 'Dedication',
'abstract': 'Abstract',
'attention': 'Attention!',
'caution': 'Caution!',
'danger': '!DANGER!',
'error': 'Error',
'hint': 'Hint',
'important': 'Important',
'note': 'Note',
'tip': 'Tip',
'warning': 'Warning',
'contents': 'Contents'}
"""Mapping of node class name to label text."""
bibliographic_fields = {
# language-dependent: fixed
'author': 'author',
'authors': 'authors',
'organization': 'organization',
'address': 'address',
'contact': 'contact',
'version': 'version',
'revision': 'revision',
'status': 'status',
'date': 'date',
'copyright': 'copyright',
'dedication': 'dedication',
'abstract': 'abstract'}
"""English (lowcased) to canonical name mapping for bibliographic fields."""
author_separators = [';', ',']
"""List of separator strings for the 'Authors' bibliographic field. Tried in
order."""
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,47 @@
# $Id: __init__.py 5618 2008-07-28 08:37:32Z strank $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
This package contains Docutils parser modules.
"""
__docformat__ = 'reStructuredText'
from docutils import Component
class Parser(Component):
component_type = 'parser'
config_section = 'parsers'
def parse(self, inputstring, document):
"""Override to parse `inputstring` into document tree `document`."""
raise NotImplementedError('subclass must override this method')
def setup_parse(self, inputstring, document):
"""Initial parse setup. Call at start of `self.parse()`."""
self.inputstring = inputstring
self.document = document
document.reporter.attach_observer(document.note_parse_message)
def finish_parse(self):
"""Finalize parse details. Call at end of `self.parse()`."""
self.document.reporter.detach_observer(
self.document.note_parse_message)
_parser_aliases = {
'restructuredtext': 'rst',
'rest': 'rst',
'restx': 'rst',
'rtxt': 'rst',}
def get_parser_class(parser_name):
"""Return the Parser class from the `parser_name` module."""
parser_name = parser_name.lower()
if parser_name in _parser_aliases:
parser_name = _parser_aliases[parser_name]
module = __import__(parser_name, globals(), locals())
return module.Parser
+20
View File
@@ -0,0 +1,20 @@
# $Id: null.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: Martin Blais <blais@furius.ca>
# Copyright: This module has been placed in the public domain.
"""A do-nothing parser."""
from docutils import parsers
class Parser(parsers.Parser):
"""A do-nothing parser."""
supported = ('null',)
config_section = 'null parser'
config_section_dependencies = ('parsers',)
def parse(self, inputstring, document):
pass
@@ -0,0 +1,373 @@
# $Id: __init__.py 6314 2010-04-26 10:04:17Z milde $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
This is ``docutils.parsers.rst`` package. It exports a single class, `Parser`,
the reStructuredText parser.
Usage
=====
1. Create a parser::
parser = docutils.parsers.rst.Parser()
Several optional arguments may be passed to modify the parser's behavior.
Please see `Customizing the Parser`_ below for details.
2. Gather input (a multi-line string), by reading a file or the standard
input::
input = sys.stdin.read()
3. Create a new empty `docutils.nodes.document` tree::
document = docutils.utils.new_document(source, settings)
See `docutils.utils.new_document()` for parameter details.
4. Run the parser, populating the document tree::
parser.parse(input, document)
Parser Overview
===============
The reStructuredText parser is implemented as a state machine, examining its
input one line at a time. To understand how the parser works, please first
become familiar with the `docutils.statemachine` module, then see the
`states` module.
Customizing the Parser
----------------------
Anything that isn't already customizable is that way simply because that type
of customizability hasn't been implemented yet. Patches welcome!
When instantiating an object of the `Parser` class, two parameters may be
passed: ``rfc2822`` and ``inliner``. Pass ``rfc2822=1`` to enable an initial
RFC-2822 style header block, parsed as a "field_list" element (with "class"
attribute set to "rfc2822"). Currently this is the only body-level element
which is customizable without subclassing. (Tip: subclass `Parser` and change
its "state_classes" and "initial_state" attributes to refer to new classes.
Contact the author if you need more details.)
The ``inliner`` parameter takes an instance of `states.Inliner` or a subclass.
It handles inline markup recognition. A common extension is the addition of
further implicit hyperlinks, like "RFC 2822". This can be done by subclassing
`states.Inliner`, adding a new method for the implicit markup, and adding a
``(pattern, method)`` pair to the "implicit_dispatch" attribute of the
subclass. See `states.Inliner.implicit_inline()` for details. Explicit
inline markup can be customized in a `states.Inliner` subclass via the
``patterns.initial`` and ``dispatch`` attributes (and new methods as
appropriate).
"""
__docformat__ = 'reStructuredText'
import docutils.parsers
import docutils.statemachine
from docutils.parsers.rst import states
from docutils import frontend, nodes
class Parser(docutils.parsers.Parser):
"""The reStructuredText parser."""
supported = ('restructuredtext', 'rst', 'rest', 'restx', 'rtxt', 'rstx')
"""Aliases this parser supports."""
settings_spec = (
'reStructuredText Parser Options',
None,
(('Recognize and link to standalone PEP references (like "PEP 258").',
['--pep-references'],
{'action': 'store_true', 'validator': frontend.validate_boolean}),
('Base URL for PEP references '
'(default "http://www.python.org/dev/peps/").',
['--pep-base-url'],
{'metavar': '<URL>', 'default': 'http://www.python.org/dev/peps/',
'validator': frontend.validate_url_trailing_slash}),
('Template for PEP file part of URL. (default "pep-%04d")',
['--pep-file-url-template'],
{'metavar': '<URL>', 'default': 'pep-%04d'}),
('Recognize and link to standalone RFC references (like "RFC 822").',
['--rfc-references'],
{'action': 'store_true', 'validator': frontend.validate_boolean}),
('Base URL for RFC references (default "http://www.faqs.org/rfcs/").',
['--rfc-base-url'],
{'metavar': '<URL>', 'default': 'http://www.faqs.org/rfcs/',
'validator': frontend.validate_url_trailing_slash}),
('Set number of spaces for tab expansion (default 8).',
['--tab-width'],
{'metavar': '<width>', 'type': 'int', 'default': 8,
'validator': frontend.validate_nonnegative_int}),
('Remove spaces before footnote references.',
['--trim-footnote-reference-space'],
{'action': 'store_true', 'validator': frontend.validate_boolean}),
('Leave spaces before footnote references.',
['--leave-footnote-reference-space'],
{'action': 'store_false', 'dest': 'trim_footnote_reference_space'}),
('Disable directives that insert the contents of external file '
'("include" & "raw"); replaced with a "warning" system message.',
['--no-file-insertion'],
{'action': 'store_false', 'default': 1,
'dest': 'file_insertion_enabled',
'validator': frontend.validate_boolean}),
('Enable directives that insert the contents of external file '
'("include" & "raw"). Enabled by default.',
['--file-insertion-enabled'],
{'action': 'store_true'}),
('Disable the "raw" directives; replaced with a "warning" '
'system message.',
['--no-raw'],
{'action': 'store_false', 'default': 1, 'dest': 'raw_enabled',
'validator': frontend.validate_boolean}),
('Enable the "raw" directive. Enabled by default.',
['--raw-enabled'],
{'action': 'store_true'}),))
config_section = 'restructuredtext parser'
config_section_dependencies = ('parsers',)
def __init__(self, rfc2822=None, inliner=None):
if rfc2822:
self.initial_state = 'RFC2822Body'
else:
self.initial_state = 'Body'
self.state_classes = states.state_classes
self.inliner = inliner
def parse(self, inputstring, document):
"""Parse `inputstring` and populate `document`, a document tree."""
self.setup_parse(inputstring, document)
self.statemachine = states.RSTStateMachine(
state_classes=self.state_classes,
initial_state=self.initial_state,
debug=document.reporter.debug_flag)
inputlines = docutils.statemachine.string2lines(
inputstring, tab_width=document.settings.tab_width,
convert_whitespace=1)
self.statemachine.run(inputlines, document, inliner=self.inliner)
self.finish_parse()
class DirectiveError(Exception):
"""
Store a message and a system message level.
To be thrown from inside directive code.
Do not instantiate directly -- use `Directive.directive_error()`
instead!
"""
def __init__(self, level, message):
"""Set error `message` and `level`"""
Exception.__init__(self)
self.level = level
self.msg = message
class Directive(object):
"""
Base class for reStructuredText directives.
The following attributes may be set by subclasses. They are
interpreted by the directive parser (which runs the directive
class):
- `required_arguments`: The number of required arguments (default:
0).
- `optional_arguments`: The number of optional arguments (default:
0).
- `final_argument_whitespace`: A boolean, indicating if the final
argument may contain whitespace (default: False).
- `option_spec`: A dictionary, mapping known option names to
conversion functions such as `int` or `float` (default: {}, no
options). Several conversion functions are defined in the
directives/__init__.py module.
Option conversion functions take a single parameter, the option
argument (a string or ``None``), validate it and/or convert it
to the appropriate form. Conversion functions may raise
`ValueError` and `TypeError` exceptions.
- `has_content`: A boolean; True if content is allowed. Client
code must handle the case where content is required but not
supplied (an empty content list will be supplied).
Arguments are normally single whitespace-separated words. The
final argument may contain whitespace and/or newlines if
`final_argument_whitespace` is True.
If the form of the arguments is more complex, specify only one
argument (either required or optional) and set
`final_argument_whitespace` to True; the client code must do any
context-sensitive parsing.
When a directive implementation is being run, the directive class
is instantiated, and the `run()` method is executed. During
instantiation, the following instance variables are set:
- ``name`` is the directive type or name (string).
- ``arguments`` is the list of positional arguments (strings).
- ``options`` is a dictionary mapping option names (strings) to
values (type depends on option conversion functions; see
`option_spec` above).
- ``content`` is a list of strings, the directive content line by line.
- ``lineno`` is the absolute line number of the first line
of the directive.
- ``src`` is the name (or path) of the rst source of the directive.
- ``srcline`` is the line number of the first line of the directive
in its source. It may differ from ``lineno``, if the main source
includes other sources with the ``.. include::`` directive.
- ``content_offset`` is the line offset of the first line of the content from
the beginning of the current input. Used when initiating a nested parse.
- ``block_text`` is a string containing the entire directive.
- ``state`` is the state which called the directive function.
- ``state_machine`` is the state machine which controls the state which called
the directive function.
Directive functions return a list of nodes which will be inserted
into the document tree at the point where the directive was
encountered. This can be an empty list if there is nothing to
insert.
For ordinary directives, the list must contain body elements or
structural elements. Some directives are intended specifically
for substitution definitions, and must return a list of `Text`
nodes and/or inline elements (suitable for inline insertion, in
place of the substitution reference). Such directives must verify
substitution definition context, typically using code like this::
if not isinstance(state, states.SubstitutionDef):
error = state_machine.reporter.error(
'Invalid context: the "%s" directive can only be used '
'within a substitution definition.' % (name),
nodes.literal_block(block_text, block_text), line=lineno)
return [error]
"""
# There is a "Creating reStructuredText Directives" how-to at
# <http://docutils.sf.net/docs/howto/rst-directives.html>. If you
# update this docstring, please update the how-to as well.
required_arguments = 0
"""Number of required directive arguments."""
optional_arguments = 0
"""Number of optional arguments after the required arguments."""
final_argument_whitespace = False
"""May the final argument contain whitespace?"""
option_spec = None
"""Mapping of option names to validator functions."""
has_content = False
"""May the directive have content?"""
def __init__(self, name, arguments, options, content, lineno,
content_offset, block_text, state, state_machine):
self.name = name
self.arguments = arguments
self.options = options
self.content = content
self.lineno = lineno
self.content_offset = content_offset
self.block_text = block_text
self.state = state
self.state_machine = state_machine
self.src, self.scrline = state_machine.get_source_and_line(lineno)
def run(self):
raise NotImplementedError('Must override run() is subclass.')
# Directive errors:
def directive_error(self, level, message):
"""
Return a DirectiveError suitable for being thrown as an exception.
Call "raise self.directive_error(level, message)" from within
a directive implementation to return one single system message
at level `level`, which automatically gets the directive block
and the line number added.
You'd often use self.error(message) instead, which will
generate an ERROR-level directive error.
"""
return DirectiveError(level, message)
def debug(self, message):
return self.directive_error(0, message)
def info(self, message):
return self.directive_error(1, message)
def warning(self, message):
return self.directive_error(2, message)
def error(self, message):
return self.directive_error(3, message)
def severe(self, message):
return self.directive_error(4, message)
# Convenience methods:
def assert_has_content(self):
"""
Throw an ERROR-level DirectiveError if the directive doesn't
have contents.
"""
if not self.content:
raise self.error('Content block expected for the "%s" directive; '
'none found.' % self.name)
def convert_directive_function(directive_fn):
"""
Define & return a directive class generated from `directive_fn`.
`directive_fn` uses the old-style, functional interface.
"""
class FunctionalDirective(Directive):
option_spec = getattr(directive_fn, 'options', None)
has_content = getattr(directive_fn, 'content', False)
_argument_spec = getattr(directive_fn, 'arguments', (0, 0, False))
required_arguments, optional_arguments, final_argument_whitespace \
= _argument_spec
def run(self):
return directive_fn(
self.name, self.arguments, self.options, self.content,
self.lineno, self.content_offset, self.block_text,
self.state, self.state_machine)
# Return new-style directive.
return FunctionalDirective
@@ -0,0 +1,395 @@
# $Id: __init__.py 5952 2009-05-19 08:45:27Z milde $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
This package contains directive implementation modules.
"""
__docformat__ = 'reStructuredText'
import re
import codecs
from docutils import nodes
from docutils.parsers.rst.languages import en as _fallback_language_module
_directive_registry = {
'attention': ('admonitions', 'Attention'),
'caution': ('admonitions', 'Caution'),
'danger': ('admonitions', 'Danger'),
'error': ('admonitions', 'Error'),
'important': ('admonitions', 'Important'),
'note': ('admonitions', 'Note'),
'tip': ('admonitions', 'Tip'),
'hint': ('admonitions', 'Hint'),
'warning': ('admonitions', 'Warning'),
'admonition': ('admonitions', 'Admonition'),
'sidebar': ('body', 'Sidebar'),
'topic': ('body', 'Topic'),
'line-block': ('body', 'LineBlock'),
'parsed-literal': ('body', 'ParsedLiteral'),
'rubric': ('body', 'Rubric'),
'epigraph': ('body', 'Epigraph'),
'highlights': ('body', 'Highlights'),
'pull-quote': ('body', 'PullQuote'),
'compound': ('body', 'Compound'),
'container': ('body', 'Container'),
#'questions': ('body', 'question_list'),
'table': ('tables', 'RSTTable'),
'csv-table': ('tables', 'CSVTable'),
'list-table': ('tables', 'ListTable'),
'image': ('images', 'Image'),
'figure': ('images', 'Figure'),
'contents': ('parts', 'Contents'),
'sectnum': ('parts', 'Sectnum'),
'header': ('parts', 'Header'),
'footer': ('parts', 'Footer'),
#'footnotes': ('parts', 'footnotes'),
#'citations': ('parts', 'citations'),
'target-notes': ('references', 'TargetNotes'),
'meta': ('html', 'Meta'),
#'imagemap': ('html', 'imagemap'),
'raw': ('misc', 'Raw'),
'include': ('misc', 'Include'),
'replace': ('misc', 'Replace'),
'unicode': ('misc', 'Unicode'),
'class': ('misc', 'Class'),
'role': ('misc', 'Role'),
'default-role': ('misc', 'DefaultRole'),
'title': ('misc', 'Title'),
'date': ('misc', 'Date'),
'restructuredtext-test-directive': ('misc', 'TestDirective'),}
"""Mapping of directive name to (module name, class name). The
directive name is canonical & must be lowercase. Language-dependent
names are defined in the ``language`` subpackage."""
_directives = {}
"""Cache of imported directives."""
def directive(directive_name, language_module, document):
"""
Locate and return a directive function from its language-dependent name.
If not found in the current language, check English. Return None if the
named directive cannot be found.
"""
normname = directive_name.lower()
messages = []
msg_text = []
if normname in _directives:
return _directives[normname], messages
canonicalname = None
try:
canonicalname = language_module.directives[normname]
except AttributeError, error:
msg_text.append('Problem retrieving directive entry from language '
'module %r: %s.' % (language_module, error))
except KeyError:
msg_text.append('No directive entry for "%s" in module "%s".'
% (directive_name, language_module.__name__))
if not canonicalname:
try:
canonicalname = _fallback_language_module.directives[normname]
msg_text.append('Using English fallback for directive "%s".'
% directive_name)
except KeyError:
msg_text.append('Trying "%s" as canonical directive name.'
% directive_name)
# The canonical name should be an English name, but just in case:
canonicalname = normname
if msg_text:
message = document.reporter.info(
'\n'.join(msg_text), line=document.current_line)
messages.append(message)
try:
modulename, classname = _directive_registry[canonicalname]
except KeyError:
# Error handling done by caller.
return None, messages
try:
module = __import__(modulename, globals(), locals())
except ImportError, detail:
messages.append(document.reporter.error(
'Error importing directive module "%s" (directive "%s"):\n%s'
% (modulename, directive_name, detail),
line=document.current_line))
return None, messages
try:
directive = getattr(module, classname)
_directives[normname] = directive
except AttributeError:
messages.append(document.reporter.error(
'No directive class "%s" in module "%s" (directive "%s").'
% (classname, modulename, directive_name),
line=document.current_line))
return None, messages
return directive, messages
def register_directive(name, directive):
"""
Register a nonstandard application-defined directive function.
Language lookups are not needed for such functions.
"""
_directives[name] = directive
def flag(argument):
"""
Check for a valid flag option (no argument) and return ``None``.
(Directive option conversion function.)
Raise ``ValueError`` if an argument is found.
"""
if argument and argument.strip():
raise ValueError('no argument is allowed; "%s" supplied' % argument)
else:
return None
def unchanged_required(argument):
"""
Return the argument text, unchanged.
(Directive option conversion function.)
Raise ``ValueError`` if no argument is found.
"""
if argument is None:
raise ValueError('argument required but none supplied')
else:
return argument # unchanged!
def unchanged(argument):
"""
Return the argument text, unchanged.
(Directive option conversion function.)
No argument implies empty string ("").
"""
if argument is None:
return u''
else:
return argument # unchanged!
def path(argument):
"""
Return the path argument unwrapped (with newlines removed).
(Directive option conversion function.)
Raise ``ValueError`` if no argument is found.
"""
if argument is None:
raise ValueError('argument required but none supplied')
else:
path = ''.join([s.strip() for s in argument.splitlines()])
return path
def uri(argument):
"""
Return the URI argument with whitespace removed.
(Directive option conversion function.)
Raise ``ValueError`` if no argument is found.
"""
if argument is None:
raise ValueError('argument required but none supplied')
else:
uri = ''.join(argument.split())
return uri
def nonnegative_int(argument):
"""
Check for a nonnegative integer argument; raise ``ValueError`` if not.
(Directive option conversion function.)
"""
value = int(argument)
if value < 0:
raise ValueError('negative value; must be positive or zero')
return value
def percentage(argument):
"""
Check for an integer percentage value with optional percent sign.
"""
try:
argument = argument.rstrip(' %')
except AttributeError:
pass
return nonnegative_int(argument)
length_units = ['em', 'ex', 'px', 'in', 'cm', 'mm', 'pt', 'pc']
def get_measure(argument, units):
"""
Check for a positive argument of one of the units and return a
normalized string of the form "<value><unit>" (without space in
between).
To be called from directive option conversion functions.
"""
match = re.match(r'^([0-9.]+) *(%s)$' % '|'.join(units), argument)
try:
assert match is not None
float(match.group(1))
except (AssertionError, ValueError):
raise ValueError(
'not a positive measure of one of the following units:\n%s'
% ' '.join(['"%s"' % i for i in units]))
return match.group(1) + match.group(2)
def length_or_unitless(argument):
return get_measure(argument, length_units + [''])
def length_or_percentage_or_unitless(argument, default=''):
"""
Return normalized string of a length or percentage unit.
Add <default> if there is no unit. Raise ValueError if the argument is not
a positive measure of one of the valid CSS units (or without unit).
>>> length_or_percentage_or_unitless('3 pt')
'3pt'
>>> length_or_percentage_or_unitless('3%', 'em')
'3%'
>>> length_or_percentage_or_unitless('3')
'3'
>>> length_or_percentage_or_unitless('3', 'px')
'3px'
"""
try:
return get_measure(argument, length_units + ['%'])
except ValueError:
return get_measure(argument, ['']) + default
def class_option(argument):
"""
Convert the argument into a list of ID-compatible strings and return it.
(Directive option conversion function.)
Raise ``ValueError`` if no argument is found.
"""
if argument is None:
raise ValueError('argument required but none supplied')
names = argument.split()
class_names = []
for name in names:
class_name = nodes.make_id(name)
if not class_name:
raise ValueError('cannot make "%s" into a class name' % name)
class_names.append(class_name)
return class_names
unicode_pattern = re.compile(
r'(?:0x|x|\\x|U\+?|\\u)([0-9a-f]+)$|&#x([0-9a-f]+);$', re.IGNORECASE)
def unicode_code(code):
r"""
Convert a Unicode character code to a Unicode character.
(Directive option conversion function.)
Codes may be decimal numbers, hexadecimal numbers (prefixed by ``0x``,
``x``, ``\x``, ``U+``, ``u``, or ``\u``; e.g. ``U+262E``), or XML-style
numeric character entities (e.g. ``&#x262E;``). Other text remains as-is.
Raise ValueError for illegal Unicode code values.
"""
try:
if code.isdigit(): # decimal number
return unichr(int(code))
else:
match = unicode_pattern.match(code)
if match: # hex number
value = match.group(1) or match.group(2)
return unichr(int(value, 16))
else: # other text
return code
except OverflowError, detail:
raise ValueError('code too large (%s)' % detail)
def single_char_or_unicode(argument):
"""
A single character is returned as-is. Unicode characters codes are
converted as in `unicode_code`. (Directive option conversion function.)
"""
char = unicode_code(argument)
if len(char) > 1:
raise ValueError('%r invalid; must be a single character or '
'a Unicode code' % char)
return char
def single_char_or_whitespace_or_unicode(argument):
"""
As with `single_char_or_unicode`, but "tab" and "space" are also supported.
(Directive option conversion function.)
"""
if argument == 'tab':
char = '\t'
elif argument == 'space':
char = ' '
else:
char = single_char_or_unicode(argument)
return char
def positive_int(argument):
"""
Converts the argument into an integer. Raises ValueError for negative,
zero, or non-integer values. (Directive option conversion function.)
"""
value = int(argument)
if value < 1:
raise ValueError('negative or zero value; must be positive')
return value
def positive_int_list(argument):
"""
Converts a space- or comma-separated list of values into a Python list
of integers.
(Directive option conversion function.)
Raises ValueError for non-positive-integer values.
"""
if ',' in argument:
entries = argument.split(',')
else:
entries = argument.split()
return [positive_int(entry) for entry in entries]
def encoding(argument):
"""
Verfies the encoding argument by lookup.
(Directive option conversion function.)
Raises ValueError for unknown encodings.
"""
try:
codecs.lookup(argument)
except LookupError:
raise ValueError('unknown encoding: "%s"' % argument)
return argument
def choice(argument, values):
"""
Directive option utility function, supplied to enable options whose
argument must be a member of a finite set of possible values (must be
lower case). A custom conversion function must be written to use it. For
example::
from docutils.parsers.rst import directives
def yesno(argument):
return directives.choice(argument, ('yes', 'no'))
Raise ``ValueError`` if no argument is found or if the argument's value is
not valid (not an entry in the supplied list).
"""
try:
value = argument.lower().strip()
except AttributeError:
raise ValueError('must supply an argument; choose from %s'
% format_values(values))
if value in values:
return value
else:
raise ValueError('"%s" unknown; choose from %s'
% (argument, format_values(values)))
def format_values(values):
return '%s, or "%s"' % (', '.join(['"%s"' % s for s in values[:-1]]),
values[-1])
@@ -0,0 +1,97 @@
# $Id: admonitions.py 5618 2008-07-28 08:37:32Z strank $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
Admonition directives.
"""
__docformat__ = 'reStructuredText'
from docutils.parsers.rst import Directive
from docutils.parsers.rst import states, directives
from docutils import nodes
class BaseAdmonition(Directive):
required_arguments = 0
optional_arguments = 0
final_argument_whitespace = True
option_spec = {}
has_content = True
node_class = None
"""Subclasses must set this to the appropriate admonition node class."""
def run(self):
self.assert_has_content()
text = '\n'.join(self.content)
admonition_node = self.node_class(text)
if self.arguments:
title_text = self.arguments[0]
textnodes, messages = self.state.inline_text(title_text,
self.lineno)
admonition_node += nodes.title(title_text, '', *textnodes)
admonition_node += messages
if 'class' in self.options:
classes = self.options['class']
else:
classes = ['admonition-' + nodes.make_id(title_text)]
admonition_node['classes'] += classes
self.state.nested_parse(self.content, self.content_offset,
admonition_node)
return [admonition_node]
class Admonition(BaseAdmonition):
required_arguments = 1
option_spec = {'class': directives.class_option}
node_class = nodes.admonition
class Attention(BaseAdmonition):
node_class = nodes.attention
class Caution(BaseAdmonition):
node_class = nodes.caution
class Danger(BaseAdmonition):
node_class = nodes.danger
class Error(BaseAdmonition):
node_class = nodes.error
class Hint(BaseAdmonition):
node_class = nodes.hint
class Important(BaseAdmonition):
node_class = nodes.important
class Note(BaseAdmonition):
node_class = nodes.note
class Tip(BaseAdmonition):
node_class = nodes.tip
class Warning(BaseAdmonition):
node_class = nodes.warning
@@ -0,0 +1,192 @@
# $Id: body.py 5618 2008-07-28 08:37:32Z strank $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
Directives for additional body elements.
See `docutils.parsers.rst.directives` for API details.
"""
__docformat__ = 'reStructuredText'
import sys
from docutils import nodes
from docutils.parsers.rst import Directive
from docutils.parsers.rst import directives
from docutils.parsers.rst.roles import set_classes
class BasePseudoSection(Directive):
required_arguments = 1
optional_arguments = 0
final_argument_whitespace = True
option_spec = {'class': directives.class_option}
has_content = True
node_class = None
"""Node class to be used (must be set in subclasses)."""
def run(self):
if not (self.state_machine.match_titles
or isinstance(self.state_machine.node, nodes.sidebar)):
raise self.error('The "%s" directive may not be used within '
'topics or body elements.' % self.name)
self.assert_has_content()
title_text = self.arguments[0]
textnodes, messages = self.state.inline_text(title_text, self.lineno)
titles = [nodes.title(title_text, '', *textnodes)]
# Sidebar uses this code.
if 'subtitle' in self.options:
textnodes, more_messages = self.state.inline_text(
self.options['subtitle'], self.lineno)
titles.append(nodes.subtitle(self.options['subtitle'], '',
*textnodes))
messages.extend(more_messages)
text = '\n'.join(self.content)
node = self.node_class(text, *(titles + messages))
node['classes'] += self.options.get('class', [])
if text:
self.state.nested_parse(self.content, self.content_offset, node)
return [node]
class Topic(BasePseudoSection):
node_class = nodes.topic
class Sidebar(BasePseudoSection):
node_class = nodes.sidebar
option_spec = BasePseudoSection.option_spec.copy()
option_spec['subtitle'] = directives.unchanged_required
def run(self):
if isinstance(self.state_machine.node, nodes.sidebar):
raise self.error('The "%s" directive may not be used within a '
'sidebar element.' % self.name)
return BasePseudoSection.run(self)
class LineBlock(Directive):
option_spec = {'class': directives.class_option}
has_content = True
def run(self):
self.assert_has_content()
block = nodes.line_block(classes=self.options.get('class', []))
node_list = [block]
for line_text in self.content:
text_nodes, messages = self.state.inline_text(
line_text.strip(), self.lineno + self.content_offset)
line = nodes.line(line_text, '', *text_nodes)
if line_text.strip():
line.indent = len(line_text) - len(line_text.lstrip())
block += line
node_list.extend(messages)
self.content_offset += 1
self.state.nest_line_block_lines(block)
return node_list
class ParsedLiteral(Directive):
option_spec = {'class': directives.class_option}
has_content = True
def run(self):
set_classes(self.options)
self.assert_has_content()
text = '\n'.join(self.content)
text_nodes, messages = self.state.inline_text(text, self.lineno)
node = nodes.literal_block(text, '', *text_nodes, **self.options)
node.line = self.content_offset + 1
return [node] + messages
class Rubric(Directive):
required_arguments = 1
optional_arguments = 0
final_argument_whitespace = True
option_spec = {'class': directives.class_option}
def run(self):
set_classes(self.options)
rubric_text = self.arguments[0]
textnodes, messages = self.state.inline_text(rubric_text, self.lineno)
rubric = nodes.rubric(rubric_text, '', *textnodes, **self.options)
return [rubric] + messages
class BlockQuote(Directive):
has_content = True
classes = []
def run(self):
self.assert_has_content()
elements = self.state.block_quote(self.content, self.content_offset)
for element in elements:
if isinstance(element, nodes.block_quote):
element['classes'] += self.classes
return elements
class Epigraph(BlockQuote):
classes = ['epigraph']
class Highlights(BlockQuote):
classes = ['highlights']
class PullQuote(BlockQuote):
classes = ['pull-quote']
class Compound(Directive):
option_spec = {'class': directives.class_option}
has_content = True
def run(self):
self.assert_has_content()
text = '\n'.join(self.content)
node = nodes.compound(text)
node['classes'] += self.options.get('class', [])
self.state.nested_parse(self.content, self.content_offset, node)
return [node]
class Container(Directive):
required_arguments = 0
optional_arguments = 1
final_argument_whitespace = True
has_content = True
def run(self):
self.assert_has_content()
text = '\n'.join(self.content)
try:
if self.arguments:
classes = directives.class_option(self.arguments[0])
else:
classes = []
except ValueError:
raise self.error(
'Invalid class attribute value for "%s" directive: "%s".'
% (self.name, self.arguments[0]))
node = nodes.container(text)
node['classes'].extend(classes)
self.state.nested_parse(self.content, self.content_offset, node)
return [node]
@@ -0,0 +1,88 @@
# $Id: html.py 4667 2006-07-12 21:40:56Z wiemann $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
Directives for typically HTML-specific constructs.
"""
__docformat__ = 'reStructuredText'
import sys
from docutils import nodes, utils
from docutils.parsers.rst import Directive
from docutils.parsers.rst import states
from docutils.transforms import components
class MetaBody(states.SpecializedBody):
class meta(nodes.Special, nodes.PreBibliographic, nodes.Element):
"""HTML-specific "meta" element."""
pass
def field_marker(self, match, context, next_state):
"""Meta element."""
node, blank_finish = self.parsemeta(match)
self.parent += node
return [], next_state, []
def parsemeta(self, match):
name = self.parse_field_marker(match)
indented, indent, line_offset, blank_finish = \
self.state_machine.get_first_known_indented(match.end())
node = self.meta()
pending = nodes.pending(components.Filter,
{'component': 'writer',
'format': 'html',
'nodes': [node]})
node['content'] = ' '.join(indented)
if not indented:
line = self.state_machine.line
msg = self.reporter.info(
'No content for meta tag "%s".' % name,
nodes.literal_block(line, line),
line=self.state_machine.abs_line_number())
return msg, blank_finish
tokens = name.split()
try:
attname, val = utils.extract_name_value(tokens[0])[0]
node[attname.lower()] = val
except utils.NameValueError:
node['name'] = tokens[0]
for token in tokens[1:]:
try:
attname, val = utils.extract_name_value(token)[0]
node[attname.lower()] = val
except utils.NameValueError, detail:
line = self.state_machine.line
msg = self.reporter.error(
'Error parsing meta tag attribute "%s": %s.'
% (token, detail), nodes.literal_block(line, line),
line=self.state_machine.abs_line_number())
return msg, blank_finish
self.document.note_pending(pending)
return pending, blank_finish
class Meta(Directive):
has_content = True
SMkwargs = {'state_classes': (MetaBody,)}
def run(self):
self.assert_has_content()
node = nodes.Element()
new_line_offset, blank_finish = self.state.nested_list_parse(
self.content, self.content_offset, node,
initial_state='MetaBody', blank_finish=1,
state_machine_kwargs=self.SMkwargs)
if (new_line_offset - self.content_offset) != len(self.content):
# incomplete parse of block?
error = self.state_machine.reporter.error(
'Invalid meta directive.',
nodes.literal_block(self.block_text, self.block_text),
line=self.lineno)
node += error
return node.children
@@ -0,0 +1,154 @@
# $Id: images.py 5952 2009-05-19 08:45:27Z milde $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
Directives for figures and simple images.
"""
__docformat__ = 'reStructuredText'
import sys
from docutils import nodes, utils
from docutils.parsers.rst import Directive
from docutils.parsers.rst import directives, states
from docutils.nodes import fully_normalize_name, whitespace_normalize_name
from docutils.parsers.rst.roles import set_classes
try:
import Image as PIL # PIL
except ImportError:
PIL = None
class Image(Directive):
align_h_values = ('left', 'center', 'right')
align_v_values = ('top', 'middle', 'bottom')
align_values = align_v_values + align_h_values
def align(argument):
# This is not callable as self.align. We cannot make it a
# staticmethod because we're saving an unbound method in
# option_spec below.
return directives.choice(argument, Image.align_values)
required_arguments = 1
optional_arguments = 0
final_argument_whitespace = True
option_spec = {'alt': directives.unchanged,
'height': directives.length_or_unitless,
'width': directives.length_or_percentage_or_unitless,
'scale': directives.percentage,
'align': align,
'target': directives.unchanged_required,
'class': directives.class_option}
def run(self):
if 'align' in self.options:
if isinstance(self.state, states.SubstitutionDef):
# Check for align_v_values.
if self.options['align'] not in self.align_v_values:
raise self.error(
'Error in "%s" directive: "%s" is not a valid value '
'for the "align" option within a substitution '
'definition. Valid values for "align" are: "%s".'
% (self.name, self.options['align'],
'", "'.join(self.align_v_values)))
elif self.options['align'] not in self.align_h_values:
raise self.error(
'Error in "%s" directive: "%s" is not a valid value for '
'the "align" option. Valid values for "align" are: "%s".'
% (self.name, self.options['align'],
'", "'.join(self.align_h_values)))
messages = []
reference = directives.uri(self.arguments[0])
self.options['uri'] = reference
reference_node = None
if 'target' in self.options:
block = states.escape2null(
self.options['target']).splitlines()
block = [line for line in block]
target_type, data = self.state.parse_target(
block, self.block_text, self.lineno)
if target_type == 'refuri':
reference_node = nodes.reference(refuri=data)
elif target_type == 'refname':
reference_node = nodes.reference(
refname=fully_normalize_name(data),
name=whitespace_normalize_name(data))
reference_node.indirect_reference_name = data
self.state.document.note_refname(reference_node)
else: # malformed target
messages.append(data) # data is a system message
del self.options['target']
set_classes(self.options)
image_node = nodes.image(self.block_text, **self.options)
if reference_node:
reference_node += image_node
return messages + [reference_node]
else:
return messages + [image_node]
class Figure(Image):
def align(argument):
return directives.choice(argument, Figure.align_h_values)
def figwidth_value(argument):
if argument.lower() == 'image':
return 'image'
else:
return directives.length_or_percentage_or_unitless(argument, 'px')
option_spec = Image.option_spec.copy()
option_spec['figwidth'] = figwidth_value
option_spec['figclass'] = directives.class_option
option_spec['align'] = align
has_content = True
def run(self):
figwidth = self.options.pop('figwidth', None)
figclasses = self.options.pop('figclass', None)
align = self.options.pop('align', None)
(image_node,) = Image.run(self)
if isinstance(image_node, nodes.system_message):
return [image_node]
figure_node = nodes.figure('', image_node)
if figwidth == 'image':
if PIL and self.state.document.settings.file_insertion_enabled:
# PIL doesn't like Unicode paths:
try:
i = PIL.open(str(image_node['uri']))
except (IOError, UnicodeError):
pass
else:
self.state.document.settings.record_dependencies.add(
image_node['uri'])
figure_node['width'] = i.size[0]
elif figwidth is not None:
figure_node['width'] = figwidth
if figclasses:
figure_node['classes'] += figclasses
if align:
figure_node['align'] = align
if self.content:
node = nodes.Element() # anonymous container for parsing
self.state.nested_parse(self.content, self.content_offset, node)
first_node = node[0]
if isinstance(first_node, nodes.paragraph):
caption = nodes.caption(first_node.rawsource, '',
*first_node.children)
figure_node += caption
elif not (isinstance(first_node, nodes.comment)
and len(first_node) == 0):
error = self.state_machine.reporter.error(
'Figure caption must be a paragraph or empty comment.',
nodes.literal_block(self.block_text, self.block_text),
line=self.lineno)
return [figure_node, error]
if len(node) > 1:
figure_node += nodes.legend('', *node[1:])
return [figure_node]
@@ -0,0 +1,484 @@
# $Id: misc.py 6185 2009-10-25 20:43:42Z milde $
# Authors: David Goodger <goodger@python.org>; Dethe Elza
# Copyright: This module has been placed in the public domain.
"""Miscellaneous directives."""
__docformat__ = 'reStructuredText'
import sys
import os.path
import re
import time
from docutils import io, nodes, statemachine, utils
from docutils.parsers.rst import Directive, convert_directive_function
from docutils.parsers.rst import directives, roles, states
from docutils.transforms import misc
class Include(Directive):
"""
Include content read from a separate source file.
Content may be parsed by the parser, or included as a literal
block. The encoding of the included file can be specified. Only
a part of the given file argument may be included by specifying
start and end line or text to match before and/or after the text
to be used.
"""
required_arguments = 1
optional_arguments = 0
final_argument_whitespace = True
option_spec = {'literal': directives.flag,
'encoding': directives.encoding,
'tab-width': int,
'start-line': int,
'end-line': int,
'start-after': directives.unchanged_required,
'end-before': directives.unchanged_required}
standard_include_path = os.path.join(os.path.dirname(states.__file__),
'include')
def run(self):
"""Include a reST file as part of the content of this reST file."""
if not self.state.document.settings.file_insertion_enabled:
raise self.warning('"%s" directive disabled.' % self.name)
source = self.state_machine.input_lines.source(
self.lineno - self.state_machine.input_offset - 1)
source_dir = os.path.dirname(os.path.abspath(source))
path = directives.path(self.arguments[0])
if path.startswith('<') and path.endswith('>'):
path = os.path.join(self.standard_include_path, path[1:-1])
path = os.path.normpath(os.path.join(source_dir, path))
path = utils.relative_path(None, path)
path = nodes.reprunicode(path)
encoding = self.options.get(
'encoding', self.state.document.settings.input_encoding)
tab_width = self.options.get(
'tab-width', self.state.document.settings.tab_width)
try:
self.state.document.settings.record_dependencies.add(path)
include_file = io.FileInput(
source_path=path, encoding=encoding,
error_handler=(self.state.document.settings.\
input_encoding_error_handler),
handle_io_errors=None)
except IOError, error:
raise self.severe('Problems with "%s" directive path:\n%s: %s.' %
(self.name, error.__class__.__name__, str(error)))
# Hack: Since Python 2.6, the string interpolation returns a
# unicode object if one of the supplied %s replacements is a
# unicode object. IOError has no `__unicode__` method and the
# fallback `__repr__` does not report the file name. Explicitely
# converting to str fixes this for now::
# print '%s\n%s\n%s\n' %(error, str(error), repr(error))
startline = self.options.get('start-line', None)
endline = self.options.get('end-line', None)
try:
if startline or (endline is not None):
lines = include_file.readlines()
rawtext = ''.join(lines[startline:endline])
else:
rawtext = include_file.read()
except UnicodeError, error:
raise self.severe(
'Problem with "%s" directive:\n%s: %s'
% (self.name, error.__class__.__name__, error))
# start-after/end-before: no restrictions on newlines in match-text,
# and no restrictions on matching inside lines vs. line boundaries
after_text = self.options.get('start-after', None)
if after_text:
# skip content in rawtext before *and incl.* a matching text
after_index = rawtext.find(after_text)
if after_index < 0:
raise self.severe('Problem with "start-after" option of "%s" '
'directive:\nText not found.' % self.name)
rawtext = rawtext[after_index + len(after_text):]
before_text = self.options.get('end-before', None)
if before_text:
# skip content in rawtext after *and incl.* a matching text
before_index = rawtext.find(before_text)
if before_index < 0:
raise self.severe('Problem with "end-before" option of "%s" '
'directive:\nText not found.' % self.name)
rawtext = rawtext[:before_index]
if 'literal' in self.options:
# Convert tabs to spaces, if `tab_width` is positive.
if tab_width >= 0:
text = rawtext.expandtabs(tab_width)
else:
text = rawtext
literal_block = nodes.literal_block(rawtext, text, source=path)
literal_block.line = 1
return [literal_block]
else:
include_lines = statemachine.string2lines(
rawtext, tab_width, convert_whitespace=1)
self.state_machine.insert_input(include_lines, path)
return []
class Raw(Directive):
"""
Pass through content unchanged
Content is included in output based on type argument
Content may be included inline (content section of directive) or
imported from a file or url.
"""
required_arguments = 1
optional_arguments = 0
final_argument_whitespace = True
option_spec = {'file': directives.path,
'url': directives.uri,
'encoding': directives.encoding}
has_content = True
def run(self):
if (not self.state.document.settings.raw_enabled
or (not self.state.document.settings.file_insertion_enabled
and ('file' in self.options
or 'url' in self.options))):
raise self.warning('"%s" directive disabled.' % self.name)
attributes = {'format': ' '.join(self.arguments[0].lower().split())}
encoding = self.options.get(
'encoding', self.state.document.settings.input_encoding)
if self.content:
if 'file' in self.options or 'url' in self.options:
raise self.error(
'"%s" directive may not both specify an external file '
'and have content.' % self.name)
text = '\n'.join(self.content)
elif 'file' in self.options:
if 'url' in self.options:
raise self.error(
'The "file" and "url" options may not be simultaneously '
'specified for the "%s" directive.' % self.name)
source_dir = os.path.dirname(
os.path.abspath(self.state.document.current_source))
path = os.path.normpath(os.path.join(source_dir,
self.options['file']))
path = utils.relative_path(None, path)
try:
self.state.document.settings.record_dependencies.add(path)
raw_file = io.FileInput(
source_path=path, encoding=encoding,
error_handler=(self.state.document.settings.\
input_encoding_error_handler),
handle_io_errors=None)
except IOError, error:
raise self.severe('Problems with "%s" directive path:\n%s.'
% (self.name, error))
try:
text = raw_file.read()
except UnicodeError, error:
raise self.severe(
'Problem with "%s" directive:\n%s: %s'
% (self.name, error.__class__.__name__, error))
attributes['source'] = path
elif 'url' in self.options:
source = self.options['url']
# Do not import urllib2 at the top of the module because
# it may fail due to broken SSL dependencies, and it takes
# about 0.15 seconds to load.
import urllib2
try:
raw_text = urllib2.urlopen(source).read()
except (urllib2.URLError, IOError, OSError), error:
raise self.severe(
'Problems with "%s" directive URL "%s":\n%s.'
% (self.name, self.options['url'], error))
raw_file = io.StringInput(
source=raw_text, source_path=source, encoding=encoding,
error_handler=(self.state.document.settings.\
input_encoding_error_handler))
try:
text = raw_file.read()
except UnicodeError, error:
raise self.severe(
'Problem with "%s" directive:\n%s: %s'
% (self.name, error.__class__.__name__, error))
attributes['source'] = source
else:
# This will always fail because there is no content.
self.assert_has_content()
raw_node = nodes.raw('', text, **attributes)
return [raw_node]
class Replace(Directive):
has_content = True
def run(self):
if not isinstance(self.state, states.SubstitutionDef):
raise self.error(
'Invalid context: the "%s" directive can only be used within '
'a substitution definition.' % self.name)
self.assert_has_content()
text = '\n'.join(self.content)
element = nodes.Element(text)
self.state.nested_parse(self.content, self.content_offset,
element)
if ( len(element) != 1
or not isinstance(element[0], nodes.paragraph)):
messages = []
for node in element:
if isinstance(node, nodes.system_message):
node['backrefs'] = []
messages.append(node)
error = self.state_machine.reporter.error(
'Error in "%s" directive: may contain a single paragraph '
'only.' % (self.name), line=self.lineno)
messages.append(error)
return messages
else:
return element[0].children
class Unicode(Directive):
r"""
Convert Unicode character codes (numbers) to characters. Codes may be
decimal numbers, hexadecimal numbers (prefixed by ``0x``, ``x``, ``\x``,
``U+``, ``u``, or ``\u``; e.g. ``U+262E``), or XML-style numeric character
entities (e.g. ``&#x262E;``). Text following ".." is a comment and is
ignored. Spaces are ignored, and any other text remains as-is.
"""
required_arguments = 1
optional_arguments = 0
final_argument_whitespace = True
option_spec = {'trim': directives.flag,
'ltrim': directives.flag,
'rtrim': directives.flag}
comment_pattern = re.compile(r'( |\n|^)\.\. ')
def run(self):
if not isinstance(self.state, states.SubstitutionDef):
raise self.error(
'Invalid context: the "%s" directive can only be used within '
'a substitution definition.' % self.name)
substitution_definition = self.state_machine.node
if 'trim' in self.options:
substitution_definition.attributes['ltrim'] = 1
substitution_definition.attributes['rtrim'] = 1
if 'ltrim' in self.options:
substitution_definition.attributes['ltrim'] = 1
if 'rtrim' in self.options:
substitution_definition.attributes['rtrim'] = 1
codes = self.comment_pattern.split(self.arguments[0])[0].split()
element = nodes.Element()
for code in codes:
try:
decoded = directives.unicode_code(code)
except ValueError, err:
raise self.error(
'Invalid character code: %s\n%s: %s'
% (code, err.__class__.__name__, err))
element += nodes.Text(decoded)
return element.children
class Class(Directive):
"""
Set a "class" attribute on the directive content or the next element.
When applied to the next element, a "pending" element is inserted, and a
transform does the work later.
"""
required_arguments = 1
optional_arguments = 0
final_argument_whitespace = True
has_content = True
def run(self):
try:
class_value = directives.class_option(self.arguments[0])
except ValueError:
raise self.error(
'Invalid class attribute value for "%s" directive: "%s".'
% (self.name, self.arguments[0]))
node_list = []
if self.content:
container = nodes.Element()
self.state.nested_parse(self.content, self.content_offset,
container)
for node in container:
node['classes'].extend(class_value)
node_list.extend(container.children)
else:
pending = nodes.pending(
misc.ClassAttribute,
{'class': class_value, 'directive': self.name},
self.block_text)
self.state_machine.document.note_pending(pending)
node_list.append(pending)
return node_list
class Role(Directive):
has_content = True
argument_pattern = re.compile(r'(%s)\s*(\(\s*(%s)\s*\)\s*)?$'
% ((states.Inliner.simplename,) * 2))
def run(self):
"""Dynamically create and register a custom interpreted text role."""
if self.content_offset > self.lineno or not self.content:
raise self.error('"%s" directive requires arguments on the first '
'line.' % self.name)
args = self.content[0]
match = self.argument_pattern.match(args)
if not match:
raise self.error('"%s" directive arguments not valid role names: '
'"%s".' % (self.name, args))
new_role_name = match.group(1)
base_role_name = match.group(3)
messages = []
if base_role_name:
base_role, messages = roles.role(
base_role_name, self.state_machine.language, self.lineno,
self.state.reporter)
if base_role is None:
error = self.state.reporter.error(
'Unknown interpreted text role "%s".' % base_role_name,
nodes.literal_block(self.block_text, self.block_text),
line=self.lineno)
return messages + [error]
else:
base_role = roles.generic_custom_role
assert not hasattr(base_role, 'arguments'), (
'Supplemental directive arguments for "%s" directive not '
'supported (specified by "%r" role).' % (self.name, base_role))
try:
converted_role = convert_directive_function(base_role)
(arguments, options, content, content_offset) = (
self.state.parse_directive_block(
self.content[1:], self.content_offset, converted_role,
option_presets={}))
except states.MarkupError, detail:
error = self.state_machine.reporter.error(
'Error in "%s" directive:\n%s.' % (self.name, detail),
nodes.literal_block(self.block_text, self.block_text),
line=self.lineno)
return messages + [error]
if 'class' not in options:
try:
options['class'] = directives.class_option(new_role_name)
except ValueError, detail:
error = self.state_machine.reporter.error(
'Invalid argument for "%s" directive:\n%s.'
% (self.name, detail), nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
return messages + [error]
role = roles.CustomRole(new_role_name, base_role, options, content)
roles.register_local_role(new_role_name, role)
return messages
class DefaultRole(Directive):
"""Set the default interpreted text role."""
required_arguments = 0
optional_arguments = 1
final_argument_whitespace = False
def run(self):
if not self.arguments:
if '' in roles._roles:
# restore the "default" default role
del roles._roles['']
return []
role_name = self.arguments[0]
role, messages = roles.role(role_name, self.state_machine.language,
self.lineno, self.state.reporter)
if role is None:
error = self.state.reporter.error(
'Unknown interpreted text role "%s".' % role_name,
nodes.literal_block(self.block_text, self.block_text),
line=self.lineno)
return messages + [error]
roles._roles[''] = role
# @@@ should this be local to the document, not the parser?
return messages
class Title(Directive):
required_arguments = 1
optional_arguments = 0
final_argument_whitespace = True
def run(self):
self.state_machine.document['title'] = self.arguments[0]
return []
class Date(Directive):
has_content = True
def run(self):
if not isinstance(self.state, states.SubstitutionDef):
raise self.error(
'Invalid context: the "%s" directive can only be used within '
'a substitution definition.' % self.name)
format = '\n'.join(self.content) or '%Y-%m-%d'
text = time.strftime(format)
return [nodes.Text(text)]
class TestDirective(Directive):
"""This directive is useful only for testing purposes."""
required_arguments = 0
optional_arguments = 1
final_argument_whitespace = True
option_spec = {'option': directives.unchanged_required}
has_content = True
def run(self):
if self.content:
text = '\n'.join(self.content)
info = self.state_machine.reporter.info(
'Directive processed. Type="%s", arguments=%r, options=%r, '
'content:' % (self.name, self.arguments, self.options),
nodes.literal_block(text, text), line=self.lineno)
else:
info = self.state_machine.reporter.info(
'Directive processed. Type="%s", arguments=%r, options=%r, '
'content: None' % (self.name, self.arguments, self.options),
line=self.lineno)
return [info]
# Old-style, functional definition:
#
# def directive_test_function(name, arguments, options, content, lineno,
# content_offset, block_text, state, state_machine):
# """This directive is useful only for testing purposes."""
# if content:
# text = '\n'.join(content)
# info = state_machine.reporter.info(
# 'Directive processed. Type="%s", arguments=%r, options=%r, '
# 'content:' % (name, arguments, options),
# nodes.literal_block(text, text), line=lineno)
# else:
# info = state_machine.reporter.info(
# 'Directive processed. Type="%s", arguments=%r, options=%r, '
# 'content: None' % (name, arguments, options), line=lineno)
# return [info]
#
# directive_test_function.arguments = (0, 1, 1)
# directive_test_function.options = {'option': directives.unchanged_required}
# directive_test_function.content = 1
@@ -0,0 +1,127 @@
# $Id: parts.py 6385 2010-08-13 12:17:01Z milde $
# Authors: David Goodger <goodger@python.org>; Dmitry Jemerov
# Copyright: This module has been placed in the public domain.
"""
Directives for document parts.
"""
__docformat__ = 'reStructuredText'
from docutils import nodes, languages
from docutils.transforms import parts
from docutils.parsers.rst import Directive
from docutils.parsers.rst import directives
class Contents(Directive):
"""
Table of contents.
The table of contents is generated in two passes: initial parse and
transform. During the initial parse, a 'pending' element is generated
which acts as a placeholder, storing the TOC title and any options
internally. At a later stage in the processing, the 'pending' element is
replaced by a 'topic' element, a title and the table of contents proper.
"""
backlinks_values = ('top', 'entry', 'none')
def backlinks(arg):
value = directives.choice(arg, Contents.backlinks_values)
if value == 'none':
return None
else:
return value
required_arguments = 0
optional_arguments = 1
final_argument_whitespace = True
option_spec = {'depth': directives.nonnegative_int,
'local': directives.flag,
'backlinks': backlinks,
'class': directives.class_option}
def run(self):
if not (self.state_machine.match_titles
or isinstance(self.state_machine.node, nodes.sidebar)):
raise self.error('The "%s" directive may not be used within '
'topics or body elements.' % self.name)
document = self.state_machine.document
language = languages.get_language(document.settings.language_code)
if self.arguments:
title_text = self.arguments[0]
text_nodes, messages = self.state.inline_text(title_text,
self.lineno)
title = nodes.title(title_text, '', *text_nodes)
else:
messages = []
if 'local' in self.options:
title = None
else:
title = nodes.title('', language.labels['contents'])
topic = nodes.topic(classes=['contents'])
topic['classes'] += self.options.get('class', [])
# the latex2e writer needs source and line for a warning:
src, srcline = self.state_machine.get_source_and_line()
topic.source = src
topic.line = srcline - 1
if 'local' in self.options:
topic['classes'].append('local')
if title:
name = title.astext()
topic += title
else:
name = language.labels['contents']
name = nodes.fully_normalize_name(name)
if not document.has_name(name):
topic['names'].append(name)
document.note_implicit_target(topic)
pending = nodes.pending(parts.Contents, rawsource=self.block_text)
pending.details.update(self.options)
document.note_pending(pending)
topic += pending
return [topic] + messages
class Sectnum(Directive):
"""Automatic section numbering."""
option_spec = {'depth': int,
'start': int,
'prefix': directives.unchanged_required,
'suffix': directives.unchanged_required}
def run(self):
pending = nodes.pending(parts.SectNum)
pending.details.update(self.options)
self.state_machine.document.note_pending(pending)
return [pending]
class Header(Directive):
"""Contents of document header."""
has_content = True
def run(self):
self.assert_has_content()
header = self.state_machine.document.get_decoration().get_header()
self.state.nested_parse(self.content, self.content_offset, header)
return []
class Footer(Directive):
"""Contents of document footer."""
has_content = True
def run(self):
self.assert_has_content()
footer = self.state_machine.document.get_decoration().get_footer()
self.state.nested_parse(self.content, self.content_offset, footer)
return []
@@ -0,0 +1,28 @@
# $Id: references.py 4667 2006-07-12 21:40:56Z wiemann $
# Authors: David Goodger <goodger@python.org>; Dmitry Jemerov
# Copyright: This module has been placed in the public domain.
"""
Directives for references and targets.
"""
__docformat__ = 'reStructuredText'
from docutils import nodes
from docutils.transforms import references
from docutils.parsers.rst import Directive
from docutils.parsers.rst import directives
class TargetNotes(Directive):
"""Target footnote generation."""
option_spec = {'class': directives.class_option}
def run(self):
pending = nodes.pending(references.TargetNotes)
pending.details.update(self.options)
self.state_machine.document.note_pending(pending)
nodelist = [pending]
return nodelist
@@ -0,0 +1,447 @@
# $Id: tables.py 6107 2009-08-31 02:29:08Z goodger $
# Authors: David Goodger <goodger@python.org>; David Priest
# Copyright: This module has been placed in the public domain.
"""
Directives for table elements.
"""
__docformat__ = 'reStructuredText'
import sys
import os.path
import csv
from docutils import io, nodes, statemachine, utils
from docutils.utils import SystemMessagePropagation
from docutils.parsers.rst import Directive
from docutils.parsers.rst import directives
class Table(Directive):
"""
Generic table base class.
"""
required_arguments = 0
optional_arguments = 1
final_argument_whitespace = True
option_spec = {'class': directives.class_option}
has_content = True
def make_title(self):
if self.arguments:
title_text = self.arguments[0]
text_nodes, messages = self.state.inline_text(title_text,
self.lineno)
title = nodes.title(title_text, '', *text_nodes)
else:
title = None
messages = []
return title, messages
def process_header_option(self):
source = self.state_machine.get_source(self.lineno - 1)
table_head = []
max_header_cols = 0
if 'header' in self.options: # separate table header in option
rows, max_header_cols = self.parse_csv_data_into_rows(
self.options['header'].split('\n'), self.HeaderDialect(),
source)
table_head.extend(rows)
return table_head, max_header_cols
def check_table_dimensions(self, rows, header_rows, stub_columns):
if len(rows) < header_rows:
error = self.state_machine.reporter.error(
'%s header row(s) specified but only %s row(s) of data '
'supplied ("%s" directive).'
% (header_rows, len(rows), self.name), nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
raise SystemMessagePropagation(error)
if len(rows) == header_rows > 0:
error = self.state_machine.reporter.error(
'Insufficient data supplied (%s row(s)); no data remaining '
'for table body, required by "%s" directive.'
% (len(rows), self.name), nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
raise SystemMessagePropagation(error)
for row in rows:
if len(row) < stub_columns:
error = self.state_machine.reporter.error(
'%s stub column(s) specified but only %s columns(s) of '
'data supplied ("%s" directive).' %
(stub_columns, len(row), self.name), nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
raise SystemMessagePropagation(error)
if len(row) == stub_columns > 0:
error = self.state_machine.reporter.error(
'Insufficient data supplied (%s columns(s)); no data remaining '
'for table body, required by "%s" directive.'
% (len(row), self.name), nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
raise SystemMessagePropagation(error)
def get_column_widths(self, max_cols):
if 'widths' in self.options:
col_widths = self.options['widths']
if len(col_widths) != max_cols:
error = self.state_machine.reporter.error(
'"%s" widths do not match the number of columns in table '
'(%s).' % (self.name, max_cols), nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
raise SystemMessagePropagation(error)
elif max_cols:
col_widths = [100 // max_cols] * max_cols
else:
error = self.state_machine.reporter.error(
'No table data detected in CSV file.', nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
raise SystemMessagePropagation(error)
return col_widths
def extend_short_rows_with_empty_cells(self, columns, parts):
for part in parts:
for row in part:
if len(row) < columns:
row.extend([(0, 0, 0, [])] * (columns - len(row)))
class RSTTable(Table):
def run(self):
if not self.content:
warning = self.state_machine.reporter.warning(
'Content block expected for the "%s" directive; none found.'
% self.name, nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
return [warning]
title, messages = self.make_title()
node = nodes.Element() # anonymous container for parsing
self.state.nested_parse(self.content, self.content_offset, node)
if len(node) != 1 or not isinstance(node[0], nodes.table):
error = self.state_machine.reporter.error(
'Error parsing content block for the "%s" directive: exactly '
'one table expected.' % self.name, nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
return [error]
table_node = node[0]
table_node['classes'] += self.options.get('class', [])
if title:
table_node.insert(0, title)
return [table_node] + messages
class CSVTable(Table):
option_spec = {'header-rows': directives.nonnegative_int,
'stub-columns': directives.nonnegative_int,
'header': directives.unchanged,
'widths': directives.positive_int_list,
'file': directives.path,
'url': directives.uri,
'encoding': directives.encoding,
'class': directives.class_option,
# field delimiter char
'delim': directives.single_char_or_whitespace_or_unicode,
# treat whitespace after delimiter as significant
'keepspace': directives.flag,
# text field quote/unquote char:
'quote': directives.single_char_or_unicode,
# char used to escape delim & quote as-needed:
'escape': directives.single_char_or_unicode,}
class DocutilsDialect(csv.Dialect):
"""CSV dialect for `csv_table` directive."""
delimiter = ','
quotechar = '"'
doublequote = True
skipinitialspace = True
lineterminator = '\n'
quoting = csv.QUOTE_MINIMAL
def __init__(self, options):
if 'delim' in options:
self.delimiter = str(options['delim'])
if 'keepspace' in options:
self.skipinitialspace = False
if 'quote' in options:
self.quotechar = str(options['quote'])
if 'escape' in options:
self.doublequote = False
self.escapechar = str(options['escape'])
csv.Dialect.__init__(self)
class HeaderDialect(csv.Dialect):
"""CSV dialect to use for the "header" option data."""
delimiter = ','
quotechar = '"'
escapechar = '\\'
doublequote = False
skipinitialspace = True
lineterminator = '\n'
quoting = csv.QUOTE_MINIMAL
def check_requirements(self):
pass
def run(self):
try:
if (not self.state.document.settings.file_insertion_enabled
and ('file' in self.options
or 'url' in self.options)):
warning = self.state_machine.reporter.warning(
'File and URL access deactivated; ignoring "%s" '
'directive.' % self.name, nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
return [warning]
self.check_requirements()
title, messages = self.make_title()
csv_data, source = self.get_csv_data()
table_head, max_header_cols = self.process_header_option()
rows, max_cols = self.parse_csv_data_into_rows(
csv_data, self.DocutilsDialect(self.options), source)
max_cols = max(max_cols, max_header_cols)
header_rows = self.options.get('header-rows', 0)
stub_columns = self.options.get('stub-columns', 0)
self.check_table_dimensions(rows, header_rows, stub_columns)
table_head.extend(rows[:header_rows])
table_body = rows[header_rows:]
col_widths = self.get_column_widths(max_cols)
self.extend_short_rows_with_empty_cells(max_cols,
(table_head, table_body))
except SystemMessagePropagation, detail:
return [detail.args[0]]
except csv.Error, detail:
error = self.state_machine.reporter.error(
'Error with CSV data in "%s" directive:\n%s'
% (self.name, detail), nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
return [error]
table = (col_widths, table_head, table_body)
table_node = self.state.build_table(table, self.content_offset,
stub_columns)
table_node['classes'] += self.options.get('class', [])
if title:
table_node.insert(0, title)
return [table_node] + messages
def get_csv_data(self):
"""
Get CSV data from the directive content, from an external
file, or from a URL reference.
"""
encoding = self.options.get(
'encoding', self.state.document.settings.input_encoding)
if self.content:
# CSV data is from directive content.
if 'file' in self.options or 'url' in self.options:
error = self.state_machine.reporter.error(
'"%s" directive may not both specify an external file and'
' have content.' % self.name, nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
raise SystemMessagePropagation(error)
source = self.content.source(0)
csv_data = self.content
elif 'file' in self.options:
# CSV data is from an external file.
if 'url' in self.options:
error = self.state_machine.reporter.error(
'The "file" and "url" options may not be simultaneously'
' specified for the "%s" directive.' % self.name,
nodes.literal_block(self.block_text, self.block_text),
line=self.lineno)
raise SystemMessagePropagation(error)
source_dir = os.path.dirname(
os.path.abspath(self.state.document.current_source))
source = os.path.normpath(os.path.join(source_dir,
self.options['file']))
source = utils.relative_path(None, source)
try:
self.state.document.settings.record_dependencies.add(source)
csv_file = io.FileInput(
source_path=source, encoding=encoding,
error_handler=(self.state.document.settings.\
input_encoding_error_handler),
handle_io_errors=None)
csv_data = csv_file.read().splitlines()
except IOError, error:
severe = self.state_machine.reporter.severe(
'Problems with "%s" directive path:\n%s.'
% (self.name, error), nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
raise SystemMessagePropagation(severe)
elif 'url' in self.options:
# CSV data is from a URL.
# Do not import urllib2 at the top of the module because
# it may fail due to broken SSL dependencies, and it takes
# about 0.15 seconds to load.
import urllib2
source = self.options['url']
try:
csv_text = urllib2.urlopen(source).read()
except (urllib2.URLError, IOError, OSError, ValueError), error:
severe = self.state_machine.reporter.severe(
'Problems with "%s" directive URL "%s":\n%s.'
% (self.name, self.options['url'], error),
nodes.literal_block(self.block_text, self.block_text),
line=self.lineno)
raise SystemMessagePropagation(severe)
csv_file = io.StringInput(
source=csv_text, source_path=source, encoding=encoding,
error_handler=(self.state.document.settings.\
input_encoding_error_handler))
csv_data = csv_file.read().splitlines()
else:
error = self.state_machine.reporter.warning(
'The "%s" directive requires content; none supplied.'
% self.name, nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
raise SystemMessagePropagation(error)
return csv_data, source
if sys.version_info < (3,):
# 2.x csv module doesn't do Unicode
def decode_from_csv(s):
return s.decode('utf-8')
def encode_for_csv(s):
return s.encode('utf-8')
else:
def decode_from_csv(s):
return s
def encode_for_csv(s):
return s
decode_from_csv = staticmethod(decode_from_csv)
encode_for_csv = staticmethod(encode_for_csv)
def parse_csv_data_into_rows(self, csv_data, dialect, source):
# csv.py doesn't do Unicode; encode temporarily as UTF-8
csv_reader = csv.reader([self.encode_for_csv(line + '\n')
for line in csv_data],
dialect=dialect)
rows = []
max_cols = 0
for row in csv_reader:
row_data = []
for cell in row:
# decode UTF-8 back to Unicode
cell_text = self.decode_from_csv(cell)
cell_data = (0, 0, 0, statemachine.StringList(
cell_text.splitlines(), source=source))
row_data.append(cell_data)
rows.append(row_data)
max_cols = max(max_cols, len(row))
return rows, max_cols
class ListTable(Table):
"""
Implement tables whose data is encoded as a uniform two-level bullet list.
For further ideas, see
http://docutils.sf.net/docs/dev/rst/alternatives.html#list-driven-tables
"""
option_spec = {'header-rows': directives.nonnegative_int,
'stub-columns': directives.nonnegative_int,
'widths': directives.positive_int_list,
'class': directives.class_option}
def run(self):
if not self.content:
error = self.state_machine.reporter.error(
'The "%s" directive is empty; content required.' % self.name,
nodes.literal_block(self.block_text, self.block_text),
line=self.lineno)
return [error]
title, messages = self.make_title()
node = nodes.Element() # anonymous container for parsing
self.state.nested_parse(self.content, self.content_offset, node)
try:
num_cols, col_widths = self.check_list_content(node)
table_data = [[item.children for item in row_list[0]]
for row_list in node[0]]
header_rows = self.options.get('header-rows', 0)
stub_columns = self.options.get('stub-columns', 0)
self.check_table_dimensions(table_data, header_rows, stub_columns)
except SystemMessagePropagation, detail:
return [detail.args[0]]
table_node = self.build_table_from_list(table_data, col_widths,
header_rows, stub_columns)
table_node['classes'] += self.options.get('class', [])
if title:
table_node.insert(0, title)
return [table_node] + messages
def check_list_content(self, node):
if len(node) != 1 or not isinstance(node[0], nodes.bullet_list):
error = self.state_machine.reporter.error(
'Error parsing content block for the "%s" directive: '
'exactly one bullet list expected.' % self.name,
nodes.literal_block(self.block_text, self.block_text),
line=self.lineno)
raise SystemMessagePropagation(error)
list_node = node[0]
# Check for a uniform two-level bullet list:
for item_index in range(len(list_node)):
item = list_node[item_index]
if len(item) != 1 or not isinstance(item[0], nodes.bullet_list):
error = self.state_machine.reporter.error(
'Error parsing content block for the "%s" directive: '
'two-level bullet list expected, but row %s does not '
'contain a second-level bullet list.'
% (self.name, item_index + 1), nodes.literal_block(
self.block_text, self.block_text), line=self.lineno)
raise SystemMessagePropagation(error)
elif item_index:
# ATTN pychecker users: num_cols is guaranteed to be set in the
# "else" clause below for item_index==0, before this branch is
# triggered.
if len(item[0]) != num_cols:
error = self.state_machine.reporter.error(
'Error parsing content block for the "%s" directive: '
'uniform two-level bullet list expected, but row %s '
'does not contain the same number of items as row 1 '
'(%s vs %s).'
% (self.name, item_index + 1, len(item[0]), num_cols),
nodes.literal_block(self.block_text, self.block_text),
line=self.lineno)
raise SystemMessagePropagation(error)
else:
num_cols = len(item[0])
col_widths = self.get_column_widths(num_cols)
return num_cols, col_widths
def build_table_from_list(self, table_data, col_widths, header_rows, stub_columns):
table = nodes.table()
tgroup = nodes.tgroup(cols=len(col_widths))
table += tgroup
for col_width in col_widths:
colspec = nodes.colspec(colwidth=col_width)
if stub_columns:
colspec.attributes['stub'] = 1
stub_columns -= 1
tgroup += colspec
rows = []
for row in table_data:
row_node = nodes.row()
for cell in row:
entry = nodes.entry()
entry += cell
row_node += entry
rows.append(row_node)
if header_rows:
thead = nodes.thead()
thead.extend(rows[:header_rows])
tgroup += thead
tbody = nodes.tbody()
tbody.extend(rows[header_rows:])
tgroup += tbody
return table
@@ -0,0 +1,17 @@
============================================
``docutils/parsers/rst/include`` Directory
============================================
This directory contains standard data files intended for inclusion in
reStructuredText documents. To access these files, use the "include"
directive with the special syntax for standard "include" data files,
angle brackets around the file name::
.. include:: <isonum.txt>
See the documentation for the `"include" directive`__ and
`reStructuredText Standard Substitution Definition Sets`__ for
details.
__ http://docutils.sf.net/docs/ref/rst/directives.html#include
__ http://docutils.sf.net/docs/ref/rst/substitutions.html
@@ -0,0 +1,162 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |angzarr| unicode:: U+0237C .. RIGHT ANGLE WITH DOWNWARDS ZIGZAG ARROW
.. |cirmid| unicode:: U+02AEF .. VERTICAL LINE WITH CIRCLE ABOVE
.. |cudarrl| unicode:: U+02938 .. RIGHT-SIDE ARC CLOCKWISE ARROW
.. |cudarrr| unicode:: U+02935 .. ARROW POINTING RIGHTWARDS THEN CURVING DOWNWARDS
.. |cularr| unicode:: U+021B6 .. ANTICLOCKWISE TOP SEMICIRCLE ARROW
.. |cularrp| unicode:: U+0293D .. TOP ARC ANTICLOCKWISE ARROW WITH PLUS
.. |curarr| unicode:: U+021B7 .. CLOCKWISE TOP SEMICIRCLE ARROW
.. |curarrm| unicode:: U+0293C .. TOP ARC CLOCKWISE ARROW WITH MINUS
.. |Darr| unicode:: U+021A1 .. DOWNWARDS TWO HEADED ARROW
.. |dArr| unicode:: U+021D3 .. DOWNWARDS DOUBLE ARROW
.. |darr2| unicode:: U+021CA .. DOWNWARDS PAIRED ARROWS
.. |ddarr| unicode:: U+021CA .. DOWNWARDS PAIRED ARROWS
.. |DDotrahd| unicode:: U+02911 .. RIGHTWARDS ARROW WITH DOTTED STEM
.. |dfisht| unicode:: U+0297F .. DOWN FISH TAIL
.. |dHar| unicode:: U+02965 .. DOWNWARDS HARPOON WITH BARB LEFT BESIDE DOWNWARDS HARPOON WITH BARB RIGHT
.. |dharl| unicode:: U+021C3 .. DOWNWARDS HARPOON WITH BARB LEFTWARDS
.. |dharr| unicode:: U+021C2 .. DOWNWARDS HARPOON WITH BARB RIGHTWARDS
.. |dlarr| unicode:: U+02199 .. SOUTH WEST ARROW
.. |drarr| unicode:: U+02198 .. SOUTH EAST ARROW
.. |duarr| unicode:: U+021F5 .. DOWNWARDS ARROW LEFTWARDS OF UPWARDS ARROW
.. |duhar| unicode:: U+0296F .. DOWNWARDS HARPOON WITH BARB LEFT BESIDE UPWARDS HARPOON WITH BARB RIGHT
.. |dzigrarr| unicode:: U+027FF .. LONG RIGHTWARDS SQUIGGLE ARROW
.. |erarr| unicode:: U+02971 .. EQUALS SIGN ABOVE RIGHTWARDS ARROW
.. |hArr| unicode:: U+021D4 .. LEFT RIGHT DOUBLE ARROW
.. |harr| unicode:: U+02194 .. LEFT RIGHT ARROW
.. |harrcir| unicode:: U+02948 .. LEFT RIGHT ARROW THROUGH SMALL CIRCLE
.. |harrw| unicode:: U+021AD .. LEFT RIGHT WAVE ARROW
.. |hoarr| unicode:: U+021FF .. LEFT RIGHT OPEN-HEADED ARROW
.. |imof| unicode:: U+022B7 .. IMAGE OF
.. |lAarr| unicode:: U+021DA .. LEFTWARDS TRIPLE ARROW
.. |Larr| unicode:: U+0219E .. LEFTWARDS TWO HEADED ARROW
.. |larr2| unicode:: U+021C7 .. LEFTWARDS PAIRED ARROWS
.. |larrbfs| unicode:: U+0291F .. LEFTWARDS ARROW FROM BAR TO BLACK DIAMOND
.. |larrfs| unicode:: U+0291D .. LEFTWARDS ARROW TO BLACK DIAMOND
.. |larrhk| unicode:: U+021A9 .. LEFTWARDS ARROW WITH HOOK
.. |larrlp| unicode:: U+021AB .. LEFTWARDS ARROW WITH LOOP
.. |larrpl| unicode:: U+02939 .. LEFT-SIDE ARC ANTICLOCKWISE ARROW
.. |larrsim| unicode:: U+02973 .. LEFTWARDS ARROW ABOVE TILDE OPERATOR
.. |larrtl| unicode:: U+021A2 .. LEFTWARDS ARROW WITH TAIL
.. |lAtail| unicode:: U+0291B .. LEFTWARDS DOUBLE ARROW-TAIL
.. |latail| unicode:: U+02919 .. LEFTWARDS ARROW-TAIL
.. |lBarr| unicode:: U+0290E .. LEFTWARDS TRIPLE DASH ARROW
.. |lbarr| unicode:: U+0290C .. LEFTWARDS DOUBLE DASH ARROW
.. |ldca| unicode:: U+02936 .. ARROW POINTING DOWNWARDS THEN CURVING LEFTWARDS
.. |ldrdhar| unicode:: U+02967 .. LEFTWARDS HARPOON WITH BARB DOWN ABOVE RIGHTWARDS HARPOON WITH BARB DOWN
.. |ldrushar| unicode:: U+0294B .. LEFT BARB DOWN RIGHT BARB UP HARPOON
.. |ldsh| unicode:: U+021B2 .. DOWNWARDS ARROW WITH TIP LEFTWARDS
.. |lfisht| unicode:: U+0297C .. LEFT FISH TAIL
.. |lHar| unicode:: U+02962 .. LEFTWARDS HARPOON WITH BARB UP ABOVE LEFTWARDS HARPOON WITH BARB DOWN
.. |lhard| unicode:: U+021BD .. LEFTWARDS HARPOON WITH BARB DOWNWARDS
.. |lharu| unicode:: U+021BC .. LEFTWARDS HARPOON WITH BARB UPWARDS
.. |lharul| unicode:: U+0296A .. LEFTWARDS HARPOON WITH BARB UP ABOVE LONG DASH
.. |llarr| unicode:: U+021C7 .. LEFTWARDS PAIRED ARROWS
.. |llhard| unicode:: U+0296B .. LEFTWARDS HARPOON WITH BARB DOWN BELOW LONG DASH
.. |loarr| unicode:: U+021FD .. LEFTWARDS OPEN-HEADED ARROW
.. |lrarr| unicode:: U+021C6 .. LEFTWARDS ARROW OVER RIGHTWARDS ARROW
.. |lrarr2| unicode:: U+021C6 .. LEFTWARDS ARROW OVER RIGHTWARDS ARROW
.. |lrhar| unicode:: U+021CB .. LEFTWARDS HARPOON OVER RIGHTWARDS HARPOON
.. |lrhar2| unicode:: U+021CB .. LEFTWARDS HARPOON OVER RIGHTWARDS HARPOON
.. |lrhard| unicode:: U+0296D .. RIGHTWARDS HARPOON WITH BARB DOWN BELOW LONG DASH
.. |lsh| unicode:: U+021B0 .. UPWARDS ARROW WITH TIP LEFTWARDS
.. |lurdshar| unicode:: U+0294A .. LEFT BARB UP RIGHT BARB DOWN HARPOON
.. |luruhar| unicode:: U+02966 .. LEFTWARDS HARPOON WITH BARB UP ABOVE RIGHTWARDS HARPOON WITH BARB UP
.. |Map| unicode:: U+02905 .. RIGHTWARDS TWO-HEADED ARROW FROM BAR
.. |map| unicode:: U+021A6 .. RIGHTWARDS ARROW FROM BAR
.. |midcir| unicode:: U+02AF0 .. VERTICAL LINE WITH CIRCLE BELOW
.. |mumap| unicode:: U+022B8 .. MULTIMAP
.. |nearhk| unicode:: U+02924 .. NORTH EAST ARROW WITH HOOK
.. |neArr| unicode:: U+021D7 .. NORTH EAST DOUBLE ARROW
.. |nearr| unicode:: U+02197 .. NORTH EAST ARROW
.. |nesear| unicode:: U+02928 .. NORTH EAST ARROW AND SOUTH EAST ARROW
.. |nhArr| unicode:: U+021CE .. LEFT RIGHT DOUBLE ARROW WITH STROKE
.. |nharr| unicode:: U+021AE .. LEFT RIGHT ARROW WITH STROKE
.. |nlArr| unicode:: U+021CD .. LEFTWARDS DOUBLE ARROW WITH STROKE
.. |nlarr| unicode:: U+0219A .. LEFTWARDS ARROW WITH STROKE
.. |nrArr| unicode:: U+021CF .. RIGHTWARDS DOUBLE ARROW WITH STROKE
.. |nrarr| unicode:: U+0219B .. RIGHTWARDS ARROW WITH STROKE
.. |nrarrc| unicode:: U+02933 U+00338 .. WAVE ARROW POINTING DIRECTLY RIGHT with slash
.. |nrarrw| unicode:: U+0219D U+00338 .. RIGHTWARDS WAVE ARROW with slash
.. |nvHarr| unicode:: U+02904 .. LEFT RIGHT DOUBLE ARROW WITH VERTICAL STROKE
.. |nvlArr| unicode:: U+02902 .. LEFTWARDS DOUBLE ARROW WITH VERTICAL STROKE
.. |nvrArr| unicode:: U+02903 .. RIGHTWARDS DOUBLE ARROW WITH VERTICAL STROKE
.. |nwarhk| unicode:: U+02923 .. NORTH WEST ARROW WITH HOOK
.. |nwArr| unicode:: U+021D6 .. NORTH WEST DOUBLE ARROW
.. |nwarr| unicode:: U+02196 .. NORTH WEST ARROW
.. |nwnear| unicode:: U+02927 .. NORTH WEST ARROW AND NORTH EAST ARROW
.. |olarr| unicode:: U+021BA .. ANTICLOCKWISE OPEN CIRCLE ARROW
.. |orarr| unicode:: U+021BB .. CLOCKWISE OPEN CIRCLE ARROW
.. |origof| unicode:: U+022B6 .. ORIGINAL OF
.. |rAarr| unicode:: U+021DB .. RIGHTWARDS TRIPLE ARROW
.. |Rarr| unicode:: U+021A0 .. RIGHTWARDS TWO HEADED ARROW
.. |rarr2| unicode:: U+021C9 .. RIGHTWARDS PAIRED ARROWS
.. |rarrap| unicode:: U+02975 .. RIGHTWARDS ARROW ABOVE ALMOST EQUAL TO
.. |rarrbfs| unicode:: U+02920 .. RIGHTWARDS ARROW FROM BAR TO BLACK DIAMOND
.. |rarrc| unicode:: U+02933 .. WAVE ARROW POINTING DIRECTLY RIGHT
.. |rarrfs| unicode:: U+0291E .. RIGHTWARDS ARROW TO BLACK DIAMOND
.. |rarrhk| unicode:: U+021AA .. RIGHTWARDS ARROW WITH HOOK
.. |rarrlp| unicode:: U+021AC .. RIGHTWARDS ARROW WITH LOOP
.. |rarrpl| unicode:: U+02945 .. RIGHTWARDS ARROW WITH PLUS BELOW
.. |rarrsim| unicode:: U+02974 .. RIGHTWARDS ARROW ABOVE TILDE OPERATOR
.. |Rarrtl| unicode:: U+02916 .. RIGHTWARDS TWO-HEADED ARROW WITH TAIL
.. |rarrtl| unicode:: U+021A3 .. RIGHTWARDS ARROW WITH TAIL
.. |rarrw| unicode:: U+0219D .. RIGHTWARDS WAVE ARROW
.. |rAtail| unicode:: U+0291C .. RIGHTWARDS DOUBLE ARROW-TAIL
.. |ratail| unicode:: U+0291A .. RIGHTWARDS ARROW-TAIL
.. |RBarr| unicode:: U+02910 .. RIGHTWARDS TWO-HEADED TRIPLE DASH ARROW
.. |rBarr| unicode:: U+0290F .. RIGHTWARDS TRIPLE DASH ARROW
.. |rbarr| unicode:: U+0290D .. RIGHTWARDS DOUBLE DASH ARROW
.. |rdca| unicode:: U+02937 .. ARROW POINTING DOWNWARDS THEN CURVING RIGHTWARDS
.. |rdldhar| unicode:: U+02969 .. RIGHTWARDS HARPOON WITH BARB DOWN ABOVE LEFTWARDS HARPOON WITH BARB DOWN
.. |rdsh| unicode:: U+021B3 .. DOWNWARDS ARROW WITH TIP RIGHTWARDS
.. |rfisht| unicode:: U+0297D .. RIGHT FISH TAIL
.. |rHar| unicode:: U+02964 .. RIGHTWARDS HARPOON WITH BARB UP ABOVE RIGHTWARDS HARPOON WITH BARB DOWN
.. |rhard| unicode:: U+021C1 .. RIGHTWARDS HARPOON WITH BARB DOWNWARDS
.. |rharu| unicode:: U+021C0 .. RIGHTWARDS HARPOON WITH BARB UPWARDS
.. |rharul| unicode:: U+0296C .. RIGHTWARDS HARPOON WITH BARB UP ABOVE LONG DASH
.. |rlarr| unicode:: U+021C4 .. RIGHTWARDS ARROW OVER LEFTWARDS ARROW
.. |rlarr2| unicode:: U+021C4 .. RIGHTWARDS ARROW OVER LEFTWARDS ARROW
.. |rlhar| unicode:: U+021CC .. RIGHTWARDS HARPOON OVER LEFTWARDS HARPOON
.. |rlhar2| unicode:: U+021CC .. RIGHTWARDS HARPOON OVER LEFTWARDS HARPOON
.. |roarr| unicode:: U+021FE .. RIGHTWARDS OPEN-HEADED ARROW
.. |rrarr| unicode:: U+021C9 .. RIGHTWARDS PAIRED ARROWS
.. |rsh| unicode:: U+021B1 .. UPWARDS ARROW WITH TIP RIGHTWARDS
.. |ruluhar| unicode:: U+02968 .. RIGHTWARDS HARPOON WITH BARB UP ABOVE LEFTWARDS HARPOON WITH BARB UP
.. |searhk| unicode:: U+02925 .. SOUTH EAST ARROW WITH HOOK
.. |seArr| unicode:: U+021D8 .. SOUTH EAST DOUBLE ARROW
.. |searr| unicode:: U+02198 .. SOUTH EAST ARROW
.. |seswar| unicode:: U+02929 .. SOUTH EAST ARROW AND SOUTH WEST ARROW
.. |simrarr| unicode:: U+02972 .. TILDE OPERATOR ABOVE RIGHTWARDS ARROW
.. |slarr| unicode:: U+02190 .. LEFTWARDS ARROW
.. |srarr| unicode:: U+02192 .. RIGHTWARDS ARROW
.. |swarhk| unicode:: U+02926 .. SOUTH WEST ARROW WITH HOOK
.. |swArr| unicode:: U+021D9 .. SOUTH WEST DOUBLE ARROW
.. |swarr| unicode:: U+02199 .. SOUTH WEST ARROW
.. |swnwar| unicode:: U+0292A .. SOUTH WEST ARROW AND NORTH WEST ARROW
.. |Uarr| unicode:: U+0219F .. UPWARDS TWO HEADED ARROW
.. |uArr| unicode:: U+021D1 .. UPWARDS DOUBLE ARROW
.. |uarr2| unicode:: U+021C8 .. UPWARDS PAIRED ARROWS
.. |Uarrocir| unicode:: U+02949 .. UPWARDS TWO-HEADED ARROW FROM SMALL CIRCLE
.. |udarr| unicode:: U+021C5 .. UPWARDS ARROW LEFTWARDS OF DOWNWARDS ARROW
.. |udhar| unicode:: U+0296E .. UPWARDS HARPOON WITH BARB LEFT BESIDE DOWNWARDS HARPOON WITH BARB RIGHT
.. |ufisht| unicode:: U+0297E .. UP FISH TAIL
.. |uHar| unicode:: U+02963 .. UPWARDS HARPOON WITH BARB LEFT BESIDE UPWARDS HARPOON WITH BARB RIGHT
.. |uharl| unicode:: U+021BF .. UPWARDS HARPOON WITH BARB LEFTWARDS
.. |uharr| unicode:: U+021BE .. UPWARDS HARPOON WITH BARB RIGHTWARDS
.. |uuarr| unicode:: U+021C8 .. UPWARDS PAIRED ARROWS
.. |vArr| unicode:: U+021D5 .. UP DOWN DOUBLE ARROW
.. |varr| unicode:: U+02195 .. UP DOWN ARROW
.. |xhArr| unicode:: U+027FA .. LONG LEFT RIGHT DOUBLE ARROW
.. |xharr| unicode:: U+027F7 .. LONG LEFT RIGHT ARROW
.. |xlArr| unicode:: U+027F8 .. LONG LEFTWARDS DOUBLE ARROW
.. |xlarr| unicode:: U+027F5 .. LONG LEFTWARDS ARROW
.. |xmap| unicode:: U+027FC .. LONG RIGHTWARDS ARROW FROM BAR
.. |xrArr| unicode:: U+027F9 .. LONG RIGHTWARDS DOUBLE ARROW
.. |xrarr| unicode:: U+027F6 .. LONG RIGHTWARDS ARROW
.. |zigrarr| unicode:: U+021DD .. RIGHTWARDS SQUIGGLE ARROW
@@ -0,0 +1,126 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |ac| unicode:: U+0223E .. INVERTED LAZY S
.. |acE| unicode:: U+0223E U+00333 .. INVERTED LAZY S with double underline
.. |amalg| unicode:: U+02A3F .. AMALGAMATION OR COPRODUCT
.. |barvee| unicode:: U+022BD .. NOR
.. |Barwed| unicode:: U+02306 .. PERSPECTIVE
.. |barwed| unicode:: U+02305 .. PROJECTIVE
.. |bsolb| unicode:: U+029C5 .. SQUARED FALLING DIAGONAL SLASH
.. |Cap| unicode:: U+022D2 .. DOUBLE INTERSECTION
.. |capand| unicode:: U+02A44 .. INTERSECTION WITH LOGICAL AND
.. |capbrcup| unicode:: U+02A49 .. INTERSECTION ABOVE BAR ABOVE UNION
.. |capcap| unicode:: U+02A4B .. INTERSECTION BESIDE AND JOINED WITH INTERSECTION
.. |capcup| unicode:: U+02A47 .. INTERSECTION ABOVE UNION
.. |capdot| unicode:: U+02A40 .. INTERSECTION WITH DOT
.. |caps| unicode:: U+02229 U+0FE00 .. INTERSECTION with serifs
.. |ccaps| unicode:: U+02A4D .. CLOSED INTERSECTION WITH SERIFS
.. |ccups| unicode:: U+02A4C .. CLOSED UNION WITH SERIFS
.. |ccupssm| unicode:: U+02A50 .. CLOSED UNION WITH SERIFS AND SMASH PRODUCT
.. |coprod| unicode:: U+02210 .. N-ARY COPRODUCT
.. |Cup| unicode:: U+022D3 .. DOUBLE UNION
.. |cupbrcap| unicode:: U+02A48 .. UNION ABOVE BAR ABOVE INTERSECTION
.. |cupcap| unicode:: U+02A46 .. UNION ABOVE INTERSECTION
.. |cupcup| unicode:: U+02A4A .. UNION BESIDE AND JOINED WITH UNION
.. |cupdot| unicode:: U+0228D .. MULTISET MULTIPLICATION
.. |cupor| unicode:: U+02A45 .. UNION WITH LOGICAL OR
.. |cups| unicode:: U+0222A U+0FE00 .. UNION with serifs
.. |cuvee| unicode:: U+022CE .. CURLY LOGICAL OR
.. |cuwed| unicode:: U+022CF .. CURLY LOGICAL AND
.. |Dagger| unicode:: U+02021 .. DOUBLE DAGGER
.. |dagger| unicode:: U+02020 .. DAGGER
.. |diam| unicode:: U+022C4 .. DIAMOND OPERATOR
.. |divonx| unicode:: U+022C7 .. DIVISION TIMES
.. |eplus| unicode:: U+02A71 .. EQUALS SIGN ABOVE PLUS SIGN
.. |hercon| unicode:: U+022B9 .. HERMITIAN CONJUGATE MATRIX
.. |intcal| unicode:: U+022BA .. INTERCALATE
.. |iprod| unicode:: U+02A3C .. INTERIOR PRODUCT
.. |loplus| unicode:: U+02A2D .. PLUS SIGN IN LEFT HALF CIRCLE
.. |lotimes| unicode:: U+02A34 .. MULTIPLICATION SIGN IN LEFT HALF CIRCLE
.. |lthree| unicode:: U+022CB .. LEFT SEMIDIRECT PRODUCT
.. |ltimes| unicode:: U+022C9 .. LEFT NORMAL FACTOR SEMIDIRECT PRODUCT
.. |midast| unicode:: U+0002A .. ASTERISK
.. |minusb| unicode:: U+0229F .. SQUARED MINUS
.. |minusd| unicode:: U+02238 .. DOT MINUS
.. |minusdu| unicode:: U+02A2A .. MINUS SIGN WITH DOT BELOW
.. |ncap| unicode:: U+02A43 .. INTERSECTION WITH OVERBAR
.. |ncup| unicode:: U+02A42 .. UNION WITH OVERBAR
.. |oast| unicode:: U+0229B .. CIRCLED ASTERISK OPERATOR
.. |ocir| unicode:: U+0229A .. CIRCLED RING OPERATOR
.. |odash| unicode:: U+0229D .. CIRCLED DASH
.. |odiv| unicode:: U+02A38 .. CIRCLED DIVISION SIGN
.. |odot| unicode:: U+02299 .. CIRCLED DOT OPERATOR
.. |odsold| unicode:: U+029BC .. CIRCLED ANTICLOCKWISE-ROTATED DIVISION SIGN
.. |ofcir| unicode:: U+029BF .. CIRCLED BULLET
.. |ogt| unicode:: U+029C1 .. CIRCLED GREATER-THAN
.. |ohbar| unicode:: U+029B5 .. CIRCLE WITH HORIZONTAL BAR
.. |olcir| unicode:: U+029BE .. CIRCLED WHITE BULLET
.. |olt| unicode:: U+029C0 .. CIRCLED LESS-THAN
.. |omid| unicode:: U+029B6 .. CIRCLED VERTICAL BAR
.. |ominus| unicode:: U+02296 .. CIRCLED MINUS
.. |opar| unicode:: U+029B7 .. CIRCLED PARALLEL
.. |operp| unicode:: U+029B9 .. CIRCLED PERPENDICULAR
.. |oplus| unicode:: U+02295 .. CIRCLED PLUS
.. |osol| unicode:: U+02298 .. CIRCLED DIVISION SLASH
.. |Otimes| unicode:: U+02A37 .. MULTIPLICATION SIGN IN DOUBLE CIRCLE
.. |otimes| unicode:: U+02297 .. CIRCLED TIMES
.. |otimesas| unicode:: U+02A36 .. CIRCLED MULTIPLICATION SIGN WITH CIRCUMFLEX ACCENT
.. |ovbar| unicode:: U+0233D .. APL FUNCTIONAL SYMBOL CIRCLE STILE
.. |plusacir| unicode:: U+02A23 .. PLUS SIGN WITH CIRCUMFLEX ACCENT ABOVE
.. |plusb| unicode:: U+0229E .. SQUARED PLUS
.. |pluscir| unicode:: U+02A22 .. PLUS SIGN WITH SMALL CIRCLE ABOVE
.. |plusdo| unicode:: U+02214 .. DOT PLUS
.. |plusdu| unicode:: U+02A25 .. PLUS SIGN WITH DOT BELOW
.. |pluse| unicode:: U+02A72 .. PLUS SIGN ABOVE EQUALS SIGN
.. |plussim| unicode:: U+02A26 .. PLUS SIGN WITH TILDE BELOW
.. |plustwo| unicode:: U+02A27 .. PLUS SIGN WITH SUBSCRIPT TWO
.. |prod| unicode:: U+0220F .. N-ARY PRODUCT
.. |race| unicode:: U+029DA .. LEFT DOUBLE WIGGLY FENCE
.. |roplus| unicode:: U+02A2E .. PLUS SIGN IN RIGHT HALF CIRCLE
.. |rotimes| unicode:: U+02A35 .. MULTIPLICATION SIGN IN RIGHT HALF CIRCLE
.. |rthree| unicode:: U+022CC .. RIGHT SEMIDIRECT PRODUCT
.. |rtimes| unicode:: U+022CA .. RIGHT NORMAL FACTOR SEMIDIRECT PRODUCT
.. |sdot| unicode:: U+022C5 .. DOT OPERATOR
.. |sdotb| unicode:: U+022A1 .. SQUARED DOT OPERATOR
.. |setmn| unicode:: U+02216 .. SET MINUS
.. |simplus| unicode:: U+02A24 .. PLUS SIGN WITH TILDE ABOVE
.. |smashp| unicode:: U+02A33 .. SMASH PRODUCT
.. |solb| unicode:: U+029C4 .. SQUARED RISING DIAGONAL SLASH
.. |sqcap| unicode:: U+02293 .. SQUARE CAP
.. |sqcaps| unicode:: U+02293 U+0FE00 .. SQUARE CAP with serifs
.. |sqcup| unicode:: U+02294 .. SQUARE CUP
.. |sqcups| unicode:: U+02294 U+0FE00 .. SQUARE CUP with serifs
.. |ssetmn| unicode:: U+02216 .. SET MINUS
.. |sstarf| unicode:: U+022C6 .. STAR OPERATOR
.. |subdot| unicode:: U+02ABD .. SUBSET WITH DOT
.. |sum| unicode:: U+02211 .. N-ARY SUMMATION
.. |supdot| unicode:: U+02ABE .. SUPERSET WITH DOT
.. |timesb| unicode:: U+022A0 .. SQUARED TIMES
.. |timesbar| unicode:: U+02A31 .. MULTIPLICATION SIGN WITH UNDERBAR
.. |timesd| unicode:: U+02A30 .. MULTIPLICATION SIGN WITH DOT ABOVE
.. |top| unicode:: U+022A4 .. DOWN TACK
.. |tridot| unicode:: U+025EC .. WHITE UP-POINTING TRIANGLE WITH DOT
.. |triminus| unicode:: U+02A3A .. MINUS SIGN IN TRIANGLE
.. |triplus| unicode:: U+02A39 .. PLUS SIGN IN TRIANGLE
.. |trisb| unicode:: U+029CD .. TRIANGLE WITH SERIFS AT BOTTOM
.. |tritime| unicode:: U+02A3B .. MULTIPLICATION SIGN IN TRIANGLE
.. |uplus| unicode:: U+0228E .. MULTISET UNION
.. |veebar| unicode:: U+022BB .. XOR
.. |wedbar| unicode:: U+02A5F .. LOGICAL AND WITH UNDERBAR
.. |wreath| unicode:: U+02240 .. WREATH PRODUCT
.. |xcap| unicode:: U+022C2 .. N-ARY INTERSECTION
.. |xcirc| unicode:: U+025EF .. LARGE CIRCLE
.. |xcup| unicode:: U+022C3 .. N-ARY UNION
.. |xdtri| unicode:: U+025BD .. WHITE DOWN-POINTING TRIANGLE
.. |xodot| unicode:: U+02A00 .. N-ARY CIRCLED DOT OPERATOR
.. |xoplus| unicode:: U+02A01 .. N-ARY CIRCLED PLUS OPERATOR
.. |xotime| unicode:: U+02A02 .. N-ARY CIRCLED TIMES OPERATOR
.. |xsqcup| unicode:: U+02A06 .. N-ARY SQUARE UNION OPERATOR
.. |xuplus| unicode:: U+02A04 .. N-ARY UNION OPERATOR WITH PLUS
.. |xutri| unicode:: U+025B3 .. WHITE UP-POINTING TRIANGLE
.. |xvee| unicode:: U+022C1 .. N-ARY LOGICAL OR
.. |xwedge| unicode:: U+022C0 .. N-ARY LOGICAL AND
@@ -0,0 +1,29 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |dlcorn| unicode:: U+0231E .. BOTTOM LEFT CORNER
.. |drcorn| unicode:: U+0231F .. BOTTOM RIGHT CORNER
.. |gtlPar| unicode:: U+02995 .. DOUBLE LEFT ARC GREATER-THAN BRACKET
.. |langd| unicode:: U+02991 .. LEFT ANGLE BRACKET WITH DOT
.. |lbrke| unicode:: U+0298B .. LEFT SQUARE BRACKET WITH UNDERBAR
.. |lbrksld| unicode:: U+0298F .. LEFT SQUARE BRACKET WITH TICK IN BOTTOM CORNER
.. |lbrkslu| unicode:: U+0298D .. LEFT SQUARE BRACKET WITH TICK IN TOP CORNER
.. |lceil| unicode:: U+02308 .. LEFT CEILING
.. |lfloor| unicode:: U+0230A .. LEFT FLOOR
.. |lmoust| unicode:: U+023B0 .. UPPER LEFT OR LOWER RIGHT CURLY BRACKET SECTION
.. |lpargt| unicode:: U+029A0 .. SPHERICAL ANGLE OPENING LEFT
.. |lparlt| unicode:: U+02993 .. LEFT ARC LESS-THAN BRACKET
.. |ltrPar| unicode:: U+02996 .. DOUBLE RIGHT ARC LESS-THAN BRACKET
.. |rangd| unicode:: U+02992 .. RIGHT ANGLE BRACKET WITH DOT
.. |rbrke| unicode:: U+0298C .. RIGHT SQUARE BRACKET WITH UNDERBAR
.. |rbrksld| unicode:: U+0298E .. RIGHT SQUARE BRACKET WITH TICK IN BOTTOM CORNER
.. |rbrkslu| unicode:: U+02990 .. RIGHT SQUARE BRACKET WITH TICK IN TOP CORNER
.. |rceil| unicode:: U+02309 .. RIGHT CEILING
.. |rfloor| unicode:: U+0230B .. RIGHT FLOOR
.. |rmoust| unicode:: U+023B1 .. UPPER RIGHT OR LOWER LEFT CURLY BRACKET SECTION
.. |rpargt| unicode:: U+02994 .. RIGHT ARC GREATER-THAN BRACKET
.. |ulcorn| unicode:: U+0231C .. TOP LEFT CORNER
.. |urcorn| unicode:: U+0231D .. TOP RIGHT CORNER
@@ -0,0 +1,96 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |gnap| unicode:: U+02A8A .. GREATER-THAN AND NOT APPROXIMATE
.. |gnE| unicode:: U+02269 .. GREATER-THAN BUT NOT EQUAL TO
.. |gne| unicode:: U+02A88 .. GREATER-THAN AND SINGLE-LINE NOT EQUAL TO
.. |gnsim| unicode:: U+022E7 .. GREATER-THAN BUT NOT EQUIVALENT TO
.. |gvnE| unicode:: U+02269 U+0FE00 .. GREATER-THAN BUT NOT EQUAL TO - with vertical stroke
.. |lnap| unicode:: U+02A89 .. LESS-THAN AND NOT APPROXIMATE
.. |lnE| unicode:: U+02268 .. LESS-THAN BUT NOT EQUAL TO
.. |lne| unicode:: U+02A87 .. LESS-THAN AND SINGLE-LINE NOT EQUAL TO
.. |lnsim| unicode:: U+022E6 .. LESS-THAN BUT NOT EQUIVALENT TO
.. |lvnE| unicode:: U+02268 U+0FE00 .. LESS-THAN BUT NOT EQUAL TO - with vertical stroke
.. |nap| unicode:: U+02249 .. NOT ALMOST EQUAL TO
.. |napE| unicode:: U+02A70 U+00338 .. APPROXIMATELY EQUAL OR EQUAL TO with slash
.. |napid| unicode:: U+0224B U+00338 .. TRIPLE TILDE with slash
.. |ncong| unicode:: U+02247 .. NEITHER APPROXIMATELY NOR ACTUALLY EQUAL TO
.. |ncongdot| unicode:: U+02A6D U+00338 .. CONGRUENT WITH DOT ABOVE with slash
.. |nequiv| unicode:: U+02262 .. NOT IDENTICAL TO
.. |ngE| unicode:: U+02267 U+00338 .. GREATER-THAN OVER EQUAL TO with slash
.. |nge| unicode:: U+02271 .. NEITHER GREATER-THAN NOR EQUAL TO
.. |nges| unicode:: U+02A7E U+00338 .. GREATER-THAN OR SLANTED EQUAL TO with slash
.. |nGg| unicode:: U+022D9 U+00338 .. VERY MUCH GREATER-THAN with slash
.. |ngsim| unicode:: U+02275 .. NEITHER GREATER-THAN NOR EQUIVALENT TO
.. |nGt| unicode:: U+0226B U+020D2 .. MUCH GREATER THAN with vertical line
.. |ngt| unicode:: U+0226F .. NOT GREATER-THAN
.. |nGtv| unicode:: U+0226B U+00338 .. MUCH GREATER THAN with slash
.. |nlE| unicode:: U+02266 U+00338 .. LESS-THAN OVER EQUAL TO with slash
.. |nle| unicode:: U+02270 .. NEITHER LESS-THAN NOR EQUAL TO
.. |nles| unicode:: U+02A7D U+00338 .. LESS-THAN OR SLANTED EQUAL TO with slash
.. |nLl| unicode:: U+022D8 U+00338 .. VERY MUCH LESS-THAN with slash
.. |nlsim| unicode:: U+02274 .. NEITHER LESS-THAN NOR EQUIVALENT TO
.. |nLt| unicode:: U+0226A U+020D2 .. MUCH LESS THAN with vertical line
.. |nlt| unicode:: U+0226E .. NOT LESS-THAN
.. |nltri| unicode:: U+022EA .. NOT NORMAL SUBGROUP OF
.. |nltrie| unicode:: U+022EC .. NOT NORMAL SUBGROUP OF OR EQUAL TO
.. |nLtv| unicode:: U+0226A U+00338 .. MUCH LESS THAN with slash
.. |nmid| unicode:: U+02224 .. DOES NOT DIVIDE
.. |npar| unicode:: U+02226 .. NOT PARALLEL TO
.. |npr| unicode:: U+02280 .. DOES NOT PRECEDE
.. |nprcue| unicode:: U+022E0 .. DOES NOT PRECEDE OR EQUAL
.. |npre| unicode:: U+02AAF U+00338 .. PRECEDES ABOVE SINGLE-LINE EQUALS SIGN with slash
.. |nrtri| unicode:: U+022EB .. DOES NOT CONTAIN AS NORMAL SUBGROUP
.. |nrtrie| unicode:: U+022ED .. DOES NOT CONTAIN AS NORMAL SUBGROUP OR EQUAL
.. |nsc| unicode:: U+02281 .. DOES NOT SUCCEED
.. |nsccue| unicode:: U+022E1 .. DOES NOT SUCCEED OR EQUAL
.. |nsce| unicode:: U+02AB0 U+00338 .. SUCCEEDS ABOVE SINGLE-LINE EQUALS SIGN with slash
.. |nsim| unicode:: U+02241 .. NOT TILDE
.. |nsime| unicode:: U+02244 .. NOT ASYMPTOTICALLY EQUAL TO
.. |nsmid| unicode:: U+02224 .. DOES NOT DIVIDE
.. |nspar| unicode:: U+02226 .. NOT PARALLEL TO
.. |nsqsube| unicode:: U+022E2 .. NOT SQUARE IMAGE OF OR EQUAL TO
.. |nsqsupe| unicode:: U+022E3 .. NOT SQUARE ORIGINAL OF OR EQUAL TO
.. |nsub| unicode:: U+02284 .. NOT A SUBSET OF
.. |nsubE| unicode:: U+02AC5 U+00338 .. SUBSET OF ABOVE EQUALS SIGN with slash
.. |nsube| unicode:: U+02288 .. NEITHER A SUBSET OF NOR EQUAL TO
.. |nsup| unicode:: U+02285 .. NOT A SUPERSET OF
.. |nsupE| unicode:: U+02AC6 U+00338 .. SUPERSET OF ABOVE EQUALS SIGN with slash
.. |nsupe| unicode:: U+02289 .. NEITHER A SUPERSET OF NOR EQUAL TO
.. |ntgl| unicode:: U+02279 .. NEITHER GREATER-THAN NOR LESS-THAN
.. |ntlg| unicode:: U+02278 .. NEITHER LESS-THAN NOR GREATER-THAN
.. |nvap| unicode:: U+0224D U+020D2 .. EQUIVALENT TO with vertical line
.. |nVDash| unicode:: U+022AF .. NEGATED DOUBLE VERTICAL BAR DOUBLE RIGHT TURNSTILE
.. |nVdash| unicode:: U+022AE .. DOES NOT FORCE
.. |nvDash| unicode:: U+022AD .. NOT TRUE
.. |nvdash| unicode:: U+022AC .. DOES NOT PROVE
.. |nvge| unicode:: U+02265 U+020D2 .. GREATER-THAN OR EQUAL TO with vertical line
.. |nvgt| unicode:: U+0003E U+020D2 .. GREATER-THAN SIGN with vertical line
.. |nvle| unicode:: U+02264 U+020D2 .. LESS-THAN OR EQUAL TO with vertical line
.. |nvlt| unicode:: U+0003C U+020D2 .. LESS-THAN SIGN with vertical line
.. |nvltrie| unicode:: U+022B4 U+020D2 .. NORMAL SUBGROUP OF OR EQUAL TO with vertical line
.. |nvrtrie| unicode:: U+022B5 U+020D2 .. CONTAINS AS NORMAL SUBGROUP OR EQUAL TO with vertical line
.. |nvsim| unicode:: U+0223C U+020D2 .. TILDE OPERATOR with vertical line
.. |parsim| unicode:: U+02AF3 .. PARALLEL WITH TILDE OPERATOR
.. |prnap| unicode:: U+02AB9 .. PRECEDES ABOVE NOT ALMOST EQUAL TO
.. |prnE| unicode:: U+02AB5 .. PRECEDES ABOVE NOT EQUAL TO
.. |prnsim| unicode:: U+022E8 .. PRECEDES BUT NOT EQUIVALENT TO
.. |rnmid| unicode:: U+02AEE .. DOES NOT DIVIDE WITH REVERSED NEGATION SLASH
.. |scnap| unicode:: U+02ABA .. SUCCEEDS ABOVE NOT ALMOST EQUAL TO
.. |scnE| unicode:: U+02AB6 .. SUCCEEDS ABOVE NOT EQUAL TO
.. |scnsim| unicode:: U+022E9 .. SUCCEEDS BUT NOT EQUIVALENT TO
.. |simne| unicode:: U+02246 .. APPROXIMATELY BUT NOT ACTUALLY EQUAL TO
.. |solbar| unicode:: U+0233F .. APL FUNCTIONAL SYMBOL SLASH BAR
.. |subnE| unicode:: U+02ACB .. SUBSET OF ABOVE NOT EQUAL TO
.. |subne| unicode:: U+0228A .. SUBSET OF WITH NOT EQUAL TO
.. |supnE| unicode:: U+02ACC .. SUPERSET OF ABOVE NOT EQUAL TO
.. |supne| unicode:: U+0228B .. SUPERSET OF WITH NOT EQUAL TO
.. |vnsub| unicode:: U+02282 U+020D2 .. SUBSET OF with vertical line
.. |vnsup| unicode:: U+02283 U+020D2 .. SUPERSET OF with vertical line
.. |vsubnE| unicode:: U+02ACB U+0FE00 .. SUBSET OF ABOVE NOT EQUAL TO - variant with stroke through bottom members
.. |vsubne| unicode:: U+0228A U+0FE00 .. SUBSET OF WITH NOT EQUAL TO - variant with stroke through bottom members
.. |vsupnE| unicode:: U+02ACC U+0FE00 .. SUPERSET OF ABOVE NOT EQUAL TO - variant with stroke through bottom members
.. |vsupne| unicode:: U+0228B U+0FE00 .. SUPERSET OF WITH NOT EQUAL TO - variant with stroke through bottom members
@@ -0,0 +1,62 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |ang| unicode:: U+02220 .. ANGLE
.. |ange| unicode:: U+029A4 .. ANGLE WITH UNDERBAR
.. |angmsd| unicode:: U+02221 .. MEASURED ANGLE
.. |angmsdaa| unicode:: U+029A8 .. MEASURED ANGLE WITH OPEN ARM ENDING IN ARROW POINTING UP AND RIGHT
.. |angmsdab| unicode:: U+029A9 .. MEASURED ANGLE WITH OPEN ARM ENDING IN ARROW POINTING UP AND LEFT
.. |angmsdac| unicode:: U+029AA .. MEASURED ANGLE WITH OPEN ARM ENDING IN ARROW POINTING DOWN AND RIGHT
.. |angmsdad| unicode:: U+029AB .. MEASURED ANGLE WITH OPEN ARM ENDING IN ARROW POINTING DOWN AND LEFT
.. |angmsdae| unicode:: U+029AC .. MEASURED ANGLE WITH OPEN ARM ENDING IN ARROW POINTING RIGHT AND UP
.. |angmsdaf| unicode:: U+029AD .. MEASURED ANGLE WITH OPEN ARM ENDING IN ARROW POINTING LEFT AND UP
.. |angmsdag| unicode:: U+029AE .. MEASURED ANGLE WITH OPEN ARM ENDING IN ARROW POINTING RIGHT AND DOWN
.. |angmsdah| unicode:: U+029AF .. MEASURED ANGLE WITH OPEN ARM ENDING IN ARROW POINTING LEFT AND DOWN
.. |angrtvb| unicode:: U+022BE .. RIGHT ANGLE WITH ARC
.. |angrtvbd| unicode:: U+0299D .. MEASURED RIGHT ANGLE WITH DOT
.. |bbrk| unicode:: U+023B5 .. BOTTOM SQUARE BRACKET
.. |bbrktbrk| unicode:: U+023B6 .. BOTTOM SQUARE BRACKET OVER TOP SQUARE BRACKET
.. |bemptyv| unicode:: U+029B0 .. REVERSED EMPTY SET
.. |beth| unicode:: U+02136 .. BET SYMBOL
.. |boxbox| unicode:: U+029C9 .. TWO JOINED SQUARES
.. |bprime| unicode:: U+02035 .. REVERSED PRIME
.. |bsemi| unicode:: U+0204F .. REVERSED SEMICOLON
.. |cemptyv| unicode:: U+029B2 .. EMPTY SET WITH SMALL CIRCLE ABOVE
.. |cirE| unicode:: U+029C3 .. CIRCLE WITH TWO HORIZONTAL STROKES TO THE RIGHT
.. |cirscir| unicode:: U+029C2 .. CIRCLE WITH SMALL CIRCLE TO THE RIGHT
.. |comp| unicode:: U+02201 .. COMPLEMENT
.. |daleth| unicode:: U+02138 .. DALET SYMBOL
.. |demptyv| unicode:: U+029B1 .. EMPTY SET WITH OVERBAR
.. |ell| unicode:: U+02113 .. SCRIPT SMALL L
.. |empty| unicode:: U+02205 .. EMPTY SET
.. |emptyv| unicode:: U+02205 .. EMPTY SET
.. |gimel| unicode:: U+02137 .. GIMEL SYMBOL
.. |iiota| unicode:: U+02129 .. TURNED GREEK SMALL LETTER IOTA
.. |image| unicode:: U+02111 .. BLACK-LETTER CAPITAL I
.. |imath| unicode:: U+00131 .. LATIN SMALL LETTER DOTLESS I
.. |inodot| unicode:: U+00131 .. LATIN SMALL LETTER DOTLESS I
.. |jmath| unicode:: U+0006A .. LATIN SMALL LETTER J
.. |jnodot| unicode:: U+0006A .. LATIN SMALL LETTER J
.. |laemptyv| unicode:: U+029B4 .. EMPTY SET WITH LEFT ARROW ABOVE
.. |lltri| unicode:: U+025FA .. LOWER LEFT TRIANGLE
.. |lrtri| unicode:: U+022BF .. RIGHT TRIANGLE
.. |mho| unicode:: U+02127 .. INVERTED OHM SIGN
.. |nang| unicode:: U+02220 U+020D2 .. ANGLE with vertical line
.. |nexist| unicode:: U+02204 .. THERE DOES NOT EXIST
.. |oS| unicode:: U+024C8 .. CIRCLED LATIN CAPITAL LETTER S
.. |planck| unicode:: U+0210F .. PLANCK CONSTANT OVER TWO PI
.. |plankv| unicode:: U+0210F .. PLANCK CONSTANT OVER TWO PI
.. |raemptyv| unicode:: U+029B3 .. EMPTY SET WITH RIGHT ARROW ABOVE
.. |range| unicode:: U+029A5 .. REVERSED ANGLE WITH UNDERBAR
.. |real| unicode:: U+0211C .. BLACK-LETTER CAPITAL R
.. |sbsol| unicode:: U+0FE68 .. SMALL REVERSE SOLIDUS
.. |tbrk| unicode:: U+023B4 .. TOP SQUARE BRACKET
.. |trpezium| unicode:: U+0FFFD .. REPLACEMENT CHARACTER
.. |ultri| unicode:: U+025F8 .. UPPER LEFT TRIANGLE
.. |urtri| unicode:: U+025F9 .. UPPER RIGHT TRIANGLE
.. |vprime| unicode:: U+02032 .. PRIME
.. |vzigzag| unicode:: U+0299A .. VERTICAL ZIGZAG LINE
.. |weierp| unicode:: U+02118 .. SCRIPT CAPITAL P
@@ -0,0 +1,191 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |apE| unicode:: U+02A70 .. APPROXIMATELY EQUAL OR EQUAL TO
.. |ape| unicode:: U+0224A .. ALMOST EQUAL OR EQUAL TO
.. |apid| unicode:: U+0224B .. TRIPLE TILDE
.. |asymp| unicode:: U+02248 .. ALMOST EQUAL TO
.. |Barv| unicode:: U+02AE7 .. SHORT DOWN TACK WITH OVERBAR
.. |bcong| unicode:: U+0224C .. ALL EQUAL TO
.. |bepsi| unicode:: U+003F6 .. GREEK REVERSED LUNATE EPSILON SYMBOL
.. |bowtie| unicode:: U+022C8 .. BOWTIE
.. |bsim| unicode:: U+0223D .. REVERSED TILDE
.. |bsime| unicode:: U+022CD .. REVERSED TILDE EQUALS
.. |bsolhsub| unicode:: U+0005C U+02282 .. REVERSE SOLIDUS, SUBSET OF
.. |bump| unicode:: U+0224E .. GEOMETRICALLY EQUIVALENT TO
.. |bumpE| unicode:: U+02AAE .. EQUALS SIGN WITH BUMPY ABOVE
.. |bumpe| unicode:: U+0224F .. DIFFERENCE BETWEEN
.. |cire| unicode:: U+02257 .. RING EQUAL TO
.. |Colon| unicode:: U+02237 .. PROPORTION
.. |Colone| unicode:: U+02A74 .. DOUBLE COLON EQUAL
.. |colone| unicode:: U+02254 .. COLON EQUALS
.. |congdot| unicode:: U+02A6D .. CONGRUENT WITH DOT ABOVE
.. |csub| unicode:: U+02ACF .. CLOSED SUBSET
.. |csube| unicode:: U+02AD1 .. CLOSED SUBSET OR EQUAL TO
.. |csup| unicode:: U+02AD0 .. CLOSED SUPERSET
.. |csupe| unicode:: U+02AD2 .. CLOSED SUPERSET OR EQUAL TO
.. |cuepr| unicode:: U+022DE .. EQUAL TO OR PRECEDES
.. |cuesc| unicode:: U+022DF .. EQUAL TO OR SUCCEEDS
.. |cupre| unicode:: U+0227C .. PRECEDES OR EQUAL TO
.. |Dashv| unicode:: U+02AE4 .. VERTICAL BAR DOUBLE LEFT TURNSTILE
.. |dashv| unicode:: U+022A3 .. LEFT TACK
.. |easter| unicode:: U+02A6E .. EQUALS WITH ASTERISK
.. |ecir| unicode:: U+02256 .. RING IN EQUAL TO
.. |ecolon| unicode:: U+02255 .. EQUALS COLON
.. |eDDot| unicode:: U+02A77 .. EQUALS SIGN WITH TWO DOTS ABOVE AND TWO DOTS BELOW
.. |eDot| unicode:: U+02251 .. GEOMETRICALLY EQUAL TO
.. |efDot| unicode:: U+02252 .. APPROXIMATELY EQUAL TO OR THE IMAGE OF
.. |eg| unicode:: U+02A9A .. DOUBLE-LINE EQUAL TO OR GREATER-THAN
.. |egs| unicode:: U+02A96 .. SLANTED EQUAL TO OR GREATER-THAN
.. |egsdot| unicode:: U+02A98 .. SLANTED EQUAL TO OR GREATER-THAN WITH DOT INSIDE
.. |el| unicode:: U+02A99 .. DOUBLE-LINE EQUAL TO OR LESS-THAN
.. |els| unicode:: U+02A95 .. SLANTED EQUAL TO OR LESS-THAN
.. |elsdot| unicode:: U+02A97 .. SLANTED EQUAL TO OR LESS-THAN WITH DOT INSIDE
.. |equest| unicode:: U+0225F .. QUESTIONED EQUAL TO
.. |equivDD| unicode:: U+02A78 .. EQUIVALENT WITH FOUR DOTS ABOVE
.. |erDot| unicode:: U+02253 .. IMAGE OF OR APPROXIMATELY EQUAL TO
.. |esdot| unicode:: U+02250 .. APPROACHES THE LIMIT
.. |Esim| unicode:: U+02A73 .. EQUALS SIGN ABOVE TILDE OPERATOR
.. |esim| unicode:: U+02242 .. MINUS TILDE
.. |fork| unicode:: U+022D4 .. PITCHFORK
.. |forkv| unicode:: U+02AD9 .. ELEMENT OF OPENING DOWNWARDS
.. |frown| unicode:: U+02322 .. FROWN
.. |gap| unicode:: U+02A86 .. GREATER-THAN OR APPROXIMATE
.. |gE| unicode:: U+02267 .. GREATER-THAN OVER EQUAL TO
.. |gEl| unicode:: U+02A8C .. GREATER-THAN ABOVE DOUBLE-LINE EQUAL ABOVE LESS-THAN
.. |gel| unicode:: U+022DB .. GREATER-THAN EQUAL TO OR LESS-THAN
.. |ges| unicode:: U+02A7E .. GREATER-THAN OR SLANTED EQUAL TO
.. |gescc| unicode:: U+02AA9 .. GREATER-THAN CLOSED BY CURVE ABOVE SLANTED EQUAL
.. |gesdot| unicode:: U+02A80 .. GREATER-THAN OR SLANTED EQUAL TO WITH DOT INSIDE
.. |gesdoto| unicode:: U+02A82 .. GREATER-THAN OR SLANTED EQUAL TO WITH DOT ABOVE
.. |gesdotol| unicode:: U+02A84 .. GREATER-THAN OR SLANTED EQUAL TO WITH DOT ABOVE LEFT
.. |gesl| unicode:: U+022DB U+0FE00 .. GREATER-THAN slanted EQUAL TO OR LESS-THAN
.. |gesles| unicode:: U+02A94 .. GREATER-THAN ABOVE SLANTED EQUAL ABOVE LESS-THAN ABOVE SLANTED EQUAL
.. |Gg| unicode:: U+022D9 .. VERY MUCH GREATER-THAN
.. |gl| unicode:: U+02277 .. GREATER-THAN OR LESS-THAN
.. |gla| unicode:: U+02AA5 .. GREATER-THAN BESIDE LESS-THAN
.. |glE| unicode:: U+02A92 .. GREATER-THAN ABOVE LESS-THAN ABOVE DOUBLE-LINE EQUAL
.. |glj| unicode:: U+02AA4 .. GREATER-THAN OVERLAPPING LESS-THAN
.. |gsdot| unicode:: U+022D7 .. GREATER-THAN WITH DOT
.. |gsim| unicode:: U+02273 .. GREATER-THAN OR EQUIVALENT TO
.. |gsime| unicode:: U+02A8E .. GREATER-THAN ABOVE SIMILAR OR EQUAL
.. |gsiml| unicode:: U+02A90 .. GREATER-THAN ABOVE SIMILAR ABOVE LESS-THAN
.. |Gt| unicode:: U+0226B .. MUCH GREATER-THAN
.. |gtcc| unicode:: U+02AA7 .. GREATER-THAN CLOSED BY CURVE
.. |gtcir| unicode:: U+02A7A .. GREATER-THAN WITH CIRCLE INSIDE
.. |gtdot| unicode:: U+022D7 .. GREATER-THAN WITH DOT
.. |gtquest| unicode:: U+02A7C .. GREATER-THAN WITH QUESTION MARK ABOVE
.. |gtrarr| unicode:: U+02978 .. GREATER-THAN ABOVE RIGHTWARDS ARROW
.. |homtht| unicode:: U+0223B .. HOMOTHETIC
.. |lap| unicode:: U+02A85 .. LESS-THAN OR APPROXIMATE
.. |lat| unicode:: U+02AAB .. LARGER THAN
.. |late| unicode:: U+02AAD .. LARGER THAN OR EQUAL TO
.. |lates| unicode:: U+02AAD U+0FE00 .. LARGER THAN OR slanted EQUAL
.. |ldot| unicode:: U+022D6 .. LESS-THAN WITH DOT
.. |lE| unicode:: U+02266 .. LESS-THAN OVER EQUAL TO
.. |lEg| unicode:: U+02A8B .. LESS-THAN ABOVE DOUBLE-LINE EQUAL ABOVE GREATER-THAN
.. |leg| unicode:: U+022DA .. LESS-THAN EQUAL TO OR GREATER-THAN
.. |les| unicode:: U+02A7D .. LESS-THAN OR SLANTED EQUAL TO
.. |lescc| unicode:: U+02AA8 .. LESS-THAN CLOSED BY CURVE ABOVE SLANTED EQUAL
.. |lesdot| unicode:: U+02A7F .. LESS-THAN OR SLANTED EQUAL TO WITH DOT INSIDE
.. |lesdoto| unicode:: U+02A81 .. LESS-THAN OR SLANTED EQUAL TO WITH DOT ABOVE
.. |lesdotor| unicode:: U+02A83 .. LESS-THAN OR SLANTED EQUAL TO WITH DOT ABOVE RIGHT
.. |lesg| unicode:: U+022DA U+0FE00 .. LESS-THAN slanted EQUAL TO OR GREATER-THAN
.. |lesges| unicode:: U+02A93 .. LESS-THAN ABOVE SLANTED EQUAL ABOVE GREATER-THAN ABOVE SLANTED EQUAL
.. |lg| unicode:: U+02276 .. LESS-THAN OR GREATER-THAN
.. |lgE| unicode:: U+02A91 .. LESS-THAN ABOVE GREATER-THAN ABOVE DOUBLE-LINE EQUAL
.. |Ll| unicode:: U+022D8 .. VERY MUCH LESS-THAN
.. |lsim| unicode:: U+02272 .. LESS-THAN OR EQUIVALENT TO
.. |lsime| unicode:: U+02A8D .. LESS-THAN ABOVE SIMILAR OR EQUAL
.. |lsimg| unicode:: U+02A8F .. LESS-THAN ABOVE SIMILAR ABOVE GREATER-THAN
.. |Lt| unicode:: U+0226A .. MUCH LESS-THAN
.. |ltcc| unicode:: U+02AA6 .. LESS-THAN CLOSED BY CURVE
.. |ltcir| unicode:: U+02A79 .. LESS-THAN WITH CIRCLE INSIDE
.. |ltdot| unicode:: U+022D6 .. LESS-THAN WITH DOT
.. |ltlarr| unicode:: U+02976 .. LESS-THAN ABOVE LEFTWARDS ARROW
.. |ltquest| unicode:: U+02A7B .. LESS-THAN WITH QUESTION MARK ABOVE
.. |ltrie| unicode:: U+022B4 .. NORMAL SUBGROUP OF OR EQUAL TO
.. |mcomma| unicode:: U+02A29 .. MINUS SIGN WITH COMMA ABOVE
.. |mDDot| unicode:: U+0223A .. GEOMETRIC PROPORTION
.. |mid| unicode:: U+02223 .. DIVIDES
.. |mlcp| unicode:: U+02ADB .. TRANSVERSAL INTERSECTION
.. |models| unicode:: U+022A7 .. MODELS
.. |mstpos| unicode:: U+0223E .. INVERTED LAZY S
.. |Pr| unicode:: U+02ABB .. DOUBLE PRECEDES
.. |pr| unicode:: U+0227A .. PRECEDES
.. |prap| unicode:: U+02AB7 .. PRECEDES ABOVE ALMOST EQUAL TO
.. |prcue| unicode:: U+0227C .. PRECEDES OR EQUAL TO
.. |prE| unicode:: U+02AB3 .. PRECEDES ABOVE EQUALS SIGN
.. |pre| unicode:: U+02AAF .. PRECEDES ABOVE SINGLE-LINE EQUALS SIGN
.. |prsim| unicode:: U+0227E .. PRECEDES OR EQUIVALENT TO
.. |prurel| unicode:: U+022B0 .. PRECEDES UNDER RELATION
.. |ratio| unicode:: U+02236 .. RATIO
.. |rtrie| unicode:: U+022B5 .. CONTAINS AS NORMAL SUBGROUP OR EQUAL TO
.. |rtriltri| unicode:: U+029CE .. RIGHT TRIANGLE ABOVE LEFT TRIANGLE
.. |samalg| unicode:: U+02210 .. N-ARY COPRODUCT
.. |Sc| unicode:: U+02ABC .. DOUBLE SUCCEEDS
.. |sc| unicode:: U+0227B .. SUCCEEDS
.. |scap| unicode:: U+02AB8 .. SUCCEEDS ABOVE ALMOST EQUAL TO
.. |sccue| unicode:: U+0227D .. SUCCEEDS OR EQUAL TO
.. |scE| unicode:: U+02AB4 .. SUCCEEDS ABOVE EQUALS SIGN
.. |sce| unicode:: U+02AB0 .. SUCCEEDS ABOVE SINGLE-LINE EQUALS SIGN
.. |scsim| unicode:: U+0227F .. SUCCEEDS OR EQUIVALENT TO
.. |sdote| unicode:: U+02A66 .. EQUALS SIGN WITH DOT BELOW
.. |sfrown| unicode:: U+02322 .. FROWN
.. |simg| unicode:: U+02A9E .. SIMILAR OR GREATER-THAN
.. |simgE| unicode:: U+02AA0 .. SIMILAR ABOVE GREATER-THAN ABOVE EQUALS SIGN
.. |siml| unicode:: U+02A9D .. SIMILAR OR LESS-THAN
.. |simlE| unicode:: U+02A9F .. SIMILAR ABOVE LESS-THAN ABOVE EQUALS SIGN
.. |smid| unicode:: U+02223 .. DIVIDES
.. |smile| unicode:: U+02323 .. SMILE
.. |smt| unicode:: U+02AAA .. SMALLER THAN
.. |smte| unicode:: U+02AAC .. SMALLER THAN OR EQUAL TO
.. |smtes| unicode:: U+02AAC U+0FE00 .. SMALLER THAN OR slanted EQUAL
.. |spar| unicode:: U+02225 .. PARALLEL TO
.. |sqsub| unicode:: U+0228F .. SQUARE IMAGE OF
.. |sqsube| unicode:: U+02291 .. SQUARE IMAGE OF OR EQUAL TO
.. |sqsup| unicode:: U+02290 .. SQUARE ORIGINAL OF
.. |sqsupe| unicode:: U+02292 .. SQUARE ORIGINAL OF OR EQUAL TO
.. |ssmile| unicode:: U+02323 .. SMILE
.. |Sub| unicode:: U+022D0 .. DOUBLE SUBSET
.. |subE| unicode:: U+02AC5 .. SUBSET OF ABOVE EQUALS SIGN
.. |subedot| unicode:: U+02AC3 .. SUBSET OF OR EQUAL TO WITH DOT ABOVE
.. |submult| unicode:: U+02AC1 .. SUBSET WITH MULTIPLICATION SIGN BELOW
.. |subplus| unicode:: U+02ABF .. SUBSET WITH PLUS SIGN BELOW
.. |subrarr| unicode:: U+02979 .. SUBSET ABOVE RIGHTWARDS ARROW
.. |subsim| unicode:: U+02AC7 .. SUBSET OF ABOVE TILDE OPERATOR
.. |subsub| unicode:: U+02AD5 .. SUBSET ABOVE SUBSET
.. |subsup| unicode:: U+02AD3 .. SUBSET ABOVE SUPERSET
.. |Sup| unicode:: U+022D1 .. DOUBLE SUPERSET
.. |supdsub| unicode:: U+02AD8 .. SUPERSET BESIDE AND JOINED BY DASH WITH SUBSET
.. |supE| unicode:: U+02AC6 .. SUPERSET OF ABOVE EQUALS SIGN
.. |supedot| unicode:: U+02AC4 .. SUPERSET OF OR EQUAL TO WITH DOT ABOVE
.. |suphsol| unicode:: U+02283 U+0002F .. SUPERSET OF, SOLIDUS
.. |suphsub| unicode:: U+02AD7 .. SUPERSET BESIDE SUBSET
.. |suplarr| unicode:: U+0297B .. SUPERSET ABOVE LEFTWARDS ARROW
.. |supmult| unicode:: U+02AC2 .. SUPERSET WITH MULTIPLICATION SIGN BELOW
.. |supplus| unicode:: U+02AC0 .. SUPERSET WITH PLUS SIGN BELOW
.. |supsim| unicode:: U+02AC8 .. SUPERSET OF ABOVE TILDE OPERATOR
.. |supsub| unicode:: U+02AD4 .. SUPERSET ABOVE SUBSET
.. |supsup| unicode:: U+02AD6 .. SUPERSET ABOVE SUPERSET
.. |thkap| unicode:: U+02248 .. ALMOST EQUAL TO
.. |thksim| unicode:: U+0223C .. TILDE OPERATOR
.. |topfork| unicode:: U+02ADA .. PITCHFORK WITH TEE TOP
.. |trie| unicode:: U+0225C .. DELTA EQUAL TO
.. |twixt| unicode:: U+0226C .. BETWEEN
.. |Vbar| unicode:: U+02AEB .. DOUBLE UP TACK
.. |vBar| unicode:: U+02AE8 .. SHORT UP TACK WITH UNDERBAR
.. |vBarv| unicode:: U+02AE9 .. SHORT UP TACK ABOVE SHORT DOWN TACK
.. |VDash| unicode:: U+022AB .. DOUBLE VERTICAL BAR DOUBLE RIGHT TURNSTILE
.. |Vdash| unicode:: U+022A9 .. FORCES
.. |vDash| unicode:: U+022A8 .. TRUE
.. |vdash| unicode:: U+022A2 .. RIGHT TACK
.. |Vdashl| unicode:: U+02AE6 .. LONG DASH FROM LEFT MEMBER OF DOUBLE VERTICAL
.. |veebar| unicode:: U+022BB .. XOR
.. |vltri| unicode:: U+022B2 .. NORMAL SUBGROUP OF
.. |vprop| unicode:: U+0221D .. PROPORTIONAL TO
.. |vrtri| unicode:: U+022B3 .. CONTAINS AS NORMAL SUBGROUP
.. |Vvdash| unicode:: U+022AA .. TRIPLE VERTICAL BAR RIGHT TURNSTILE
@@ -0,0 +1,46 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |boxDL| unicode:: U+02557 .. BOX DRAWINGS DOUBLE DOWN AND LEFT
.. |boxDl| unicode:: U+02556 .. BOX DRAWINGS DOWN DOUBLE AND LEFT SINGLE
.. |boxdL| unicode:: U+02555 .. BOX DRAWINGS DOWN SINGLE AND LEFT DOUBLE
.. |boxdl| unicode:: U+02510 .. BOX DRAWINGS LIGHT DOWN AND LEFT
.. |boxDR| unicode:: U+02554 .. BOX DRAWINGS DOUBLE DOWN AND RIGHT
.. |boxDr| unicode:: U+02553 .. BOX DRAWINGS DOWN DOUBLE AND RIGHT SINGLE
.. |boxdR| unicode:: U+02552 .. BOX DRAWINGS DOWN SINGLE AND RIGHT DOUBLE
.. |boxdr| unicode:: U+0250C .. BOX DRAWINGS LIGHT DOWN AND RIGHT
.. |boxH| unicode:: U+02550 .. BOX DRAWINGS DOUBLE HORIZONTAL
.. |boxh| unicode:: U+02500 .. BOX DRAWINGS LIGHT HORIZONTAL
.. |boxHD| unicode:: U+02566 .. BOX DRAWINGS DOUBLE DOWN AND HORIZONTAL
.. |boxHd| unicode:: U+02564 .. BOX DRAWINGS DOWN SINGLE AND HORIZONTAL DOUBLE
.. |boxhD| unicode:: U+02565 .. BOX DRAWINGS DOWN DOUBLE AND HORIZONTAL SINGLE
.. |boxhd| unicode:: U+0252C .. BOX DRAWINGS LIGHT DOWN AND HORIZONTAL
.. |boxHU| unicode:: U+02569 .. BOX DRAWINGS DOUBLE UP AND HORIZONTAL
.. |boxHu| unicode:: U+02567 .. BOX DRAWINGS UP SINGLE AND HORIZONTAL DOUBLE
.. |boxhU| unicode:: U+02568 .. BOX DRAWINGS UP DOUBLE AND HORIZONTAL SINGLE
.. |boxhu| unicode:: U+02534 .. BOX DRAWINGS LIGHT UP AND HORIZONTAL
.. |boxUL| unicode:: U+0255D .. BOX DRAWINGS DOUBLE UP AND LEFT
.. |boxUl| unicode:: U+0255C .. BOX DRAWINGS UP DOUBLE AND LEFT SINGLE
.. |boxuL| unicode:: U+0255B .. BOX DRAWINGS UP SINGLE AND LEFT DOUBLE
.. |boxul| unicode:: U+02518 .. BOX DRAWINGS LIGHT UP AND LEFT
.. |boxUR| unicode:: U+0255A .. BOX DRAWINGS DOUBLE UP AND RIGHT
.. |boxUr| unicode:: U+02559 .. BOX DRAWINGS UP DOUBLE AND RIGHT SINGLE
.. |boxuR| unicode:: U+02558 .. BOX DRAWINGS UP SINGLE AND RIGHT DOUBLE
.. |boxur| unicode:: U+02514 .. BOX DRAWINGS LIGHT UP AND RIGHT
.. |boxV| unicode:: U+02551 .. BOX DRAWINGS DOUBLE VERTICAL
.. |boxv| unicode:: U+02502 .. BOX DRAWINGS LIGHT VERTICAL
.. |boxVH| unicode:: U+0256C .. BOX DRAWINGS DOUBLE VERTICAL AND HORIZONTAL
.. |boxVh| unicode:: U+0256B .. BOX DRAWINGS VERTICAL DOUBLE AND HORIZONTAL SINGLE
.. |boxvH| unicode:: U+0256A .. BOX DRAWINGS VERTICAL SINGLE AND HORIZONTAL DOUBLE
.. |boxvh| unicode:: U+0253C .. BOX DRAWINGS LIGHT VERTICAL AND HORIZONTAL
.. |boxVL| unicode:: U+02563 .. BOX DRAWINGS DOUBLE VERTICAL AND LEFT
.. |boxVl| unicode:: U+02562 .. BOX DRAWINGS VERTICAL DOUBLE AND LEFT SINGLE
.. |boxvL| unicode:: U+02561 .. BOX DRAWINGS VERTICAL SINGLE AND LEFT DOUBLE
.. |boxvl| unicode:: U+02524 .. BOX DRAWINGS LIGHT VERTICAL AND LEFT
.. |boxVR| unicode:: U+02560 .. BOX DRAWINGS DOUBLE VERTICAL AND RIGHT
.. |boxVr| unicode:: U+0255F .. BOX DRAWINGS VERTICAL DOUBLE AND RIGHT SINGLE
.. |boxvR| unicode:: U+0255E .. BOX DRAWINGS VERTICAL SINGLE AND RIGHT DOUBLE
.. |boxvr| unicode:: U+0251C .. BOX DRAWINGS LIGHT VERTICAL AND RIGHT
@@ -0,0 +1,73 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |Acy| unicode:: U+00410 .. CYRILLIC CAPITAL LETTER A
.. |acy| unicode:: U+00430 .. CYRILLIC SMALL LETTER A
.. |Bcy| unicode:: U+00411 .. CYRILLIC CAPITAL LETTER BE
.. |bcy| unicode:: U+00431 .. CYRILLIC SMALL LETTER BE
.. |CHcy| unicode:: U+00427 .. CYRILLIC CAPITAL LETTER CHE
.. |chcy| unicode:: U+00447 .. CYRILLIC SMALL LETTER CHE
.. |Dcy| unicode:: U+00414 .. CYRILLIC CAPITAL LETTER DE
.. |dcy| unicode:: U+00434 .. CYRILLIC SMALL LETTER DE
.. |Ecy| unicode:: U+0042D .. CYRILLIC CAPITAL LETTER E
.. |ecy| unicode:: U+0044D .. CYRILLIC SMALL LETTER E
.. |Fcy| unicode:: U+00424 .. CYRILLIC CAPITAL LETTER EF
.. |fcy| unicode:: U+00444 .. CYRILLIC SMALL LETTER EF
.. |Gcy| unicode:: U+00413 .. CYRILLIC CAPITAL LETTER GHE
.. |gcy| unicode:: U+00433 .. CYRILLIC SMALL LETTER GHE
.. |HARDcy| unicode:: U+0042A .. CYRILLIC CAPITAL LETTER HARD SIGN
.. |hardcy| unicode:: U+0044A .. CYRILLIC SMALL LETTER HARD SIGN
.. |Icy| unicode:: U+00418 .. CYRILLIC CAPITAL LETTER I
.. |icy| unicode:: U+00438 .. CYRILLIC SMALL LETTER I
.. |IEcy| unicode:: U+00415 .. CYRILLIC CAPITAL LETTER IE
.. |iecy| unicode:: U+00435 .. CYRILLIC SMALL LETTER IE
.. |IOcy| unicode:: U+00401 .. CYRILLIC CAPITAL LETTER IO
.. |iocy| unicode:: U+00451 .. CYRILLIC SMALL LETTER IO
.. |Jcy| unicode:: U+00419 .. CYRILLIC CAPITAL LETTER SHORT I
.. |jcy| unicode:: U+00439 .. CYRILLIC SMALL LETTER SHORT I
.. |Kcy| unicode:: U+0041A .. CYRILLIC CAPITAL LETTER KA
.. |kcy| unicode:: U+0043A .. CYRILLIC SMALL LETTER KA
.. |KHcy| unicode:: U+00425 .. CYRILLIC CAPITAL LETTER HA
.. |khcy| unicode:: U+00445 .. CYRILLIC SMALL LETTER HA
.. |Lcy| unicode:: U+0041B .. CYRILLIC CAPITAL LETTER EL
.. |lcy| unicode:: U+0043B .. CYRILLIC SMALL LETTER EL
.. |Mcy| unicode:: U+0041C .. CYRILLIC CAPITAL LETTER EM
.. |mcy| unicode:: U+0043C .. CYRILLIC SMALL LETTER EM
.. |Ncy| unicode:: U+0041D .. CYRILLIC CAPITAL LETTER EN
.. |ncy| unicode:: U+0043D .. CYRILLIC SMALL LETTER EN
.. |numero| unicode:: U+02116 .. NUMERO SIGN
.. |Ocy| unicode:: U+0041E .. CYRILLIC CAPITAL LETTER O
.. |ocy| unicode:: U+0043E .. CYRILLIC SMALL LETTER O
.. |Pcy| unicode:: U+0041F .. CYRILLIC CAPITAL LETTER PE
.. |pcy| unicode:: U+0043F .. CYRILLIC SMALL LETTER PE
.. |Rcy| unicode:: U+00420 .. CYRILLIC CAPITAL LETTER ER
.. |rcy| unicode:: U+00440 .. CYRILLIC SMALL LETTER ER
.. |Scy| unicode:: U+00421 .. CYRILLIC CAPITAL LETTER ES
.. |scy| unicode:: U+00441 .. CYRILLIC SMALL LETTER ES
.. |SHCHcy| unicode:: U+00429 .. CYRILLIC CAPITAL LETTER SHCHA
.. |shchcy| unicode:: U+00449 .. CYRILLIC SMALL LETTER SHCHA
.. |SHcy| unicode:: U+00428 .. CYRILLIC CAPITAL LETTER SHA
.. |shcy| unicode:: U+00448 .. CYRILLIC SMALL LETTER SHA
.. |SOFTcy| unicode:: U+0042C .. CYRILLIC CAPITAL LETTER SOFT SIGN
.. |softcy| unicode:: U+0044C .. CYRILLIC SMALL LETTER SOFT SIGN
.. |Tcy| unicode:: U+00422 .. CYRILLIC CAPITAL LETTER TE
.. |tcy| unicode:: U+00442 .. CYRILLIC SMALL LETTER TE
.. |TScy| unicode:: U+00426 .. CYRILLIC CAPITAL LETTER TSE
.. |tscy| unicode:: U+00446 .. CYRILLIC SMALL LETTER TSE
.. |Ucy| unicode:: U+00423 .. CYRILLIC CAPITAL LETTER U
.. |ucy| unicode:: U+00443 .. CYRILLIC SMALL LETTER U
.. |Vcy| unicode:: U+00412 .. CYRILLIC CAPITAL LETTER VE
.. |vcy| unicode:: U+00432 .. CYRILLIC SMALL LETTER VE
.. |YAcy| unicode:: U+0042F .. CYRILLIC CAPITAL LETTER YA
.. |yacy| unicode:: U+0044F .. CYRILLIC SMALL LETTER YA
.. |Ycy| unicode:: U+0042B .. CYRILLIC CAPITAL LETTER YERU
.. |ycy| unicode:: U+0044B .. CYRILLIC SMALL LETTER YERU
.. |YUcy| unicode:: U+0042E .. CYRILLIC CAPITAL LETTER YU
.. |yucy| unicode:: U+0044E .. CYRILLIC SMALL LETTER YU
.. |Zcy| unicode:: U+00417 .. CYRILLIC CAPITAL LETTER ZE
.. |zcy| unicode:: U+00437 .. CYRILLIC SMALL LETTER ZE
.. |ZHcy| unicode:: U+00416 .. CYRILLIC CAPITAL LETTER ZHE
.. |zhcy| unicode:: U+00436 .. CYRILLIC SMALL LETTER ZHE
@@ -0,0 +1,32 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |DJcy| unicode:: U+00402 .. CYRILLIC CAPITAL LETTER DJE
.. |djcy| unicode:: U+00452 .. CYRILLIC SMALL LETTER DJE
.. |DScy| unicode:: U+00405 .. CYRILLIC CAPITAL LETTER DZE
.. |dscy| unicode:: U+00455 .. CYRILLIC SMALL LETTER DZE
.. |DZcy| unicode:: U+0040F .. CYRILLIC CAPITAL LETTER DZHE
.. |dzcy| unicode:: U+0045F .. CYRILLIC SMALL LETTER DZHE
.. |GJcy| unicode:: U+00403 .. CYRILLIC CAPITAL LETTER GJE
.. |gjcy| unicode:: U+00453 .. CYRILLIC SMALL LETTER GJE
.. |Iukcy| unicode:: U+00406 .. CYRILLIC CAPITAL LETTER BYELORUSSIAN-UKRAINIAN I
.. |iukcy| unicode:: U+00456 .. CYRILLIC SMALL LETTER BYELORUSSIAN-UKRAINIAN I
.. |Jsercy| unicode:: U+00408 .. CYRILLIC CAPITAL LETTER JE
.. |jsercy| unicode:: U+00458 .. CYRILLIC SMALL LETTER JE
.. |Jukcy| unicode:: U+00404 .. CYRILLIC CAPITAL LETTER UKRAINIAN IE
.. |jukcy| unicode:: U+00454 .. CYRILLIC SMALL LETTER UKRAINIAN IE
.. |KJcy| unicode:: U+0040C .. CYRILLIC CAPITAL LETTER KJE
.. |kjcy| unicode:: U+0045C .. CYRILLIC SMALL LETTER KJE
.. |LJcy| unicode:: U+00409 .. CYRILLIC CAPITAL LETTER LJE
.. |ljcy| unicode:: U+00459 .. CYRILLIC SMALL LETTER LJE
.. |NJcy| unicode:: U+0040A .. CYRILLIC CAPITAL LETTER NJE
.. |njcy| unicode:: U+0045A .. CYRILLIC SMALL LETTER NJE
.. |TSHcy| unicode:: U+0040B .. CYRILLIC CAPITAL LETTER TSHE
.. |tshcy| unicode:: U+0045B .. CYRILLIC SMALL LETTER TSHE
.. |Ubrcy| unicode:: U+0040E .. CYRILLIC CAPITAL LETTER SHORT U
.. |ubrcy| unicode:: U+0045E .. CYRILLIC SMALL LETTER SHORT U
.. |YIcy| unicode:: U+00407 .. CYRILLIC CAPITAL LETTER YI
.. |yicy| unicode:: U+00457 .. CYRILLIC SMALL LETTER YI
@@ -0,0 +1,20 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |acute| unicode:: U+000B4 .. ACUTE ACCENT
.. |breve| unicode:: U+002D8 .. BREVE
.. |caron| unicode:: U+002C7 .. CARON
.. |cedil| unicode:: U+000B8 .. CEDILLA
.. |circ| unicode:: U+002C6 .. MODIFIER LETTER CIRCUMFLEX ACCENT
.. |dblac| unicode:: U+002DD .. DOUBLE ACUTE ACCENT
.. |die| unicode:: U+000A8 .. DIAERESIS
.. |dot| unicode:: U+002D9 .. DOT ABOVE
.. |grave| unicode:: U+00060 .. GRAVE ACCENT
.. |macr| unicode:: U+000AF .. MACRON
.. |ogon| unicode:: U+002DB .. OGONEK
.. |ring| unicode:: U+002DA .. RING ABOVE
.. |tilde| unicode:: U+002DC .. SMALL TILDE
.. |uml| unicode:: U+000A8 .. DIAERESIS
@@ -0,0 +1,55 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |Agr| unicode:: U+00391 .. GREEK CAPITAL LETTER ALPHA
.. |agr| unicode:: U+003B1 .. GREEK SMALL LETTER ALPHA
.. |Bgr| unicode:: U+00392 .. GREEK CAPITAL LETTER BETA
.. |bgr| unicode:: U+003B2 .. GREEK SMALL LETTER BETA
.. |Dgr| unicode:: U+00394 .. GREEK CAPITAL LETTER DELTA
.. |dgr| unicode:: U+003B4 .. GREEK SMALL LETTER DELTA
.. |EEgr| unicode:: U+00397 .. GREEK CAPITAL LETTER ETA
.. |eegr| unicode:: U+003B7 .. GREEK SMALL LETTER ETA
.. |Egr| unicode:: U+00395 .. GREEK CAPITAL LETTER EPSILON
.. |egr| unicode:: U+003B5 .. GREEK SMALL LETTER EPSILON
.. |Ggr| unicode:: U+00393 .. GREEK CAPITAL LETTER GAMMA
.. |ggr| unicode:: U+003B3 .. GREEK SMALL LETTER GAMMA
.. |Igr| unicode:: U+00399 .. GREEK CAPITAL LETTER IOTA
.. |igr| unicode:: U+003B9 .. GREEK SMALL LETTER IOTA
.. |Kgr| unicode:: U+0039A .. GREEK CAPITAL LETTER KAPPA
.. |kgr| unicode:: U+003BA .. GREEK SMALL LETTER KAPPA
.. |KHgr| unicode:: U+003A7 .. GREEK CAPITAL LETTER CHI
.. |khgr| unicode:: U+003C7 .. GREEK SMALL LETTER CHI
.. |Lgr| unicode:: U+0039B .. GREEK CAPITAL LETTER LAMDA
.. |lgr| unicode:: U+003BB .. GREEK SMALL LETTER LAMDA
.. |Mgr| unicode:: U+0039C .. GREEK CAPITAL LETTER MU
.. |mgr| unicode:: U+003BC .. GREEK SMALL LETTER MU
.. |Ngr| unicode:: U+0039D .. GREEK CAPITAL LETTER NU
.. |ngr| unicode:: U+003BD .. GREEK SMALL LETTER NU
.. |Ogr| unicode:: U+0039F .. GREEK CAPITAL LETTER OMICRON
.. |ogr| unicode:: U+003BF .. GREEK SMALL LETTER OMICRON
.. |OHgr| unicode:: U+003A9 .. GREEK CAPITAL LETTER OMEGA
.. |ohgr| unicode:: U+003C9 .. GREEK SMALL LETTER OMEGA
.. |Pgr| unicode:: U+003A0 .. GREEK CAPITAL LETTER PI
.. |pgr| unicode:: U+003C0 .. GREEK SMALL LETTER PI
.. |PHgr| unicode:: U+003A6 .. GREEK CAPITAL LETTER PHI
.. |phgr| unicode:: U+003C6 .. GREEK SMALL LETTER PHI
.. |PSgr| unicode:: U+003A8 .. GREEK CAPITAL LETTER PSI
.. |psgr| unicode:: U+003C8 .. GREEK SMALL LETTER PSI
.. |Rgr| unicode:: U+003A1 .. GREEK CAPITAL LETTER RHO
.. |rgr| unicode:: U+003C1 .. GREEK SMALL LETTER RHO
.. |sfgr| unicode:: U+003C2 .. GREEK SMALL LETTER FINAL SIGMA
.. |Sgr| unicode:: U+003A3 .. GREEK CAPITAL LETTER SIGMA
.. |sgr| unicode:: U+003C3 .. GREEK SMALL LETTER SIGMA
.. |Tgr| unicode:: U+003A4 .. GREEK CAPITAL LETTER TAU
.. |tgr| unicode:: U+003C4 .. GREEK SMALL LETTER TAU
.. |THgr| unicode:: U+00398 .. GREEK CAPITAL LETTER THETA
.. |thgr| unicode:: U+003B8 .. GREEK SMALL LETTER THETA
.. |Ugr| unicode:: U+003A5 .. GREEK CAPITAL LETTER UPSILON
.. |ugr| unicode:: U+003C5 .. GREEK SMALL LETTER UPSILON
.. |Xgr| unicode:: U+0039E .. GREEK CAPITAL LETTER XI
.. |xgr| unicode:: U+003BE .. GREEK SMALL LETTER XI
.. |Zgr| unicode:: U+00396 .. GREEK CAPITAL LETTER ZETA
.. |zgr| unicode:: U+003B6 .. GREEK SMALL LETTER ZETA
@@ -0,0 +1,26 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |Aacgr| unicode:: U+00386 .. GREEK CAPITAL LETTER ALPHA WITH TONOS
.. |aacgr| unicode:: U+003AC .. GREEK SMALL LETTER ALPHA WITH TONOS
.. |Eacgr| unicode:: U+00388 .. GREEK CAPITAL LETTER EPSILON WITH TONOS
.. |eacgr| unicode:: U+003AD .. GREEK SMALL LETTER EPSILON WITH TONOS
.. |EEacgr| unicode:: U+00389 .. GREEK CAPITAL LETTER ETA WITH TONOS
.. |eeacgr| unicode:: U+003AE .. GREEK SMALL LETTER ETA WITH TONOS
.. |Iacgr| unicode:: U+0038A .. GREEK CAPITAL LETTER IOTA WITH TONOS
.. |iacgr| unicode:: U+003AF .. GREEK SMALL LETTER IOTA WITH TONOS
.. |idiagr| unicode:: U+00390 .. GREEK SMALL LETTER IOTA WITH DIALYTIKA AND TONOS
.. |Idigr| unicode:: U+003AA .. GREEK CAPITAL LETTER IOTA WITH DIALYTIKA
.. |idigr| unicode:: U+003CA .. GREEK SMALL LETTER IOTA WITH DIALYTIKA
.. |Oacgr| unicode:: U+0038C .. GREEK CAPITAL LETTER OMICRON WITH TONOS
.. |oacgr| unicode:: U+003CC .. GREEK SMALL LETTER OMICRON WITH TONOS
.. |OHacgr| unicode:: U+0038F .. GREEK CAPITAL LETTER OMEGA WITH TONOS
.. |ohacgr| unicode:: U+003CE .. GREEK SMALL LETTER OMEGA WITH TONOS
.. |Uacgr| unicode:: U+0038E .. GREEK CAPITAL LETTER UPSILON WITH TONOS
.. |uacgr| unicode:: U+003CD .. GREEK SMALL LETTER UPSILON WITH TONOS
.. |udiagr| unicode:: U+003B0 .. GREEK SMALL LETTER UPSILON WITH DIALYTIKA AND TONOS
.. |Udigr| unicode:: U+003AB .. GREEK CAPITAL LETTER UPSILON WITH DIALYTIKA
.. |udigr| unicode:: U+003CB .. GREEK SMALL LETTER UPSILON WITH DIALYTIKA
@@ -0,0 +1,52 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |alpha| unicode:: U+003B1 .. GREEK SMALL LETTER ALPHA
.. |beta| unicode:: U+003B2 .. GREEK SMALL LETTER BETA
.. |chi| unicode:: U+003C7 .. GREEK SMALL LETTER CHI
.. |Delta| unicode:: U+00394 .. GREEK CAPITAL LETTER DELTA
.. |delta| unicode:: U+003B4 .. GREEK SMALL LETTER DELTA
.. |epsi| unicode:: U+003F5 .. GREEK LUNATE EPSILON SYMBOL
.. |epsis| unicode:: U+003F5 .. GREEK LUNATE EPSILON SYMBOL
.. |epsiv| unicode:: U+003B5 .. GREEK SMALL LETTER EPSILON
.. |eta| unicode:: U+003B7 .. GREEK SMALL LETTER ETA
.. |Gamma| unicode:: U+00393 .. GREEK CAPITAL LETTER GAMMA
.. |gamma| unicode:: U+003B3 .. GREEK SMALL LETTER GAMMA
.. |Gammad| unicode:: U+003DC .. GREEK LETTER DIGAMMA
.. |gammad| unicode:: U+003DD .. GREEK SMALL LETTER DIGAMMA
.. |iota| unicode:: U+003B9 .. GREEK SMALL LETTER IOTA
.. |kappa| unicode:: U+003BA .. GREEK SMALL LETTER KAPPA
.. |kappav| unicode:: U+003F0 .. GREEK KAPPA SYMBOL
.. |Lambda| unicode:: U+0039B .. GREEK CAPITAL LETTER LAMDA
.. |lambda| unicode:: U+003BB .. GREEK SMALL LETTER LAMDA
.. |mu| unicode:: U+003BC .. GREEK SMALL LETTER MU
.. |nu| unicode:: U+003BD .. GREEK SMALL LETTER NU
.. |Omega| unicode:: U+003A9 .. GREEK CAPITAL LETTER OMEGA
.. |omega| unicode:: U+003C9 .. GREEK SMALL LETTER OMEGA
.. |Phi| unicode:: U+003A6 .. GREEK CAPITAL LETTER PHI
.. |phi| unicode:: U+003D5 .. GREEK PHI SYMBOL
.. |phis| unicode:: U+003D5 .. GREEK PHI SYMBOL
.. |phiv| unicode:: U+003C6 .. GREEK SMALL LETTER PHI
.. |Pi| unicode:: U+003A0 .. GREEK CAPITAL LETTER PI
.. |pi| unicode:: U+003C0 .. GREEK SMALL LETTER PI
.. |piv| unicode:: U+003D6 .. GREEK PI SYMBOL
.. |Psi| unicode:: U+003A8 .. GREEK CAPITAL LETTER PSI
.. |psi| unicode:: U+003C8 .. GREEK SMALL LETTER PSI
.. |rho| unicode:: U+003C1 .. GREEK SMALL LETTER RHO
.. |rhov| unicode:: U+003F1 .. GREEK RHO SYMBOL
.. |Sigma| unicode:: U+003A3 .. GREEK CAPITAL LETTER SIGMA
.. |sigma| unicode:: U+003C3 .. GREEK SMALL LETTER SIGMA
.. |sigmav| unicode:: U+003C2 .. GREEK SMALL LETTER FINAL SIGMA
.. |tau| unicode:: U+003C4 .. GREEK SMALL LETTER TAU
.. |Theta| unicode:: U+00398 .. GREEK CAPITAL LETTER THETA
.. |theta| unicode:: U+003B8 .. GREEK SMALL LETTER THETA
.. |thetas| unicode:: U+003B8 .. GREEK SMALL LETTER THETA
.. |thetav| unicode:: U+003D1 .. GREEK THETA SYMBOL
.. |Upsi| unicode:: U+003D2 .. GREEK UPSILON WITH HOOK SYMBOL
.. |upsi| unicode:: U+003C5 .. GREEK SMALL LETTER UPSILON
.. |Xi| unicode:: U+0039E .. GREEK CAPITAL LETTER XI
.. |xi| unicode:: U+003BE .. GREEK SMALL LETTER XI
.. |zeta| unicode:: U+003B6 .. GREEK SMALL LETTER ZETA
@@ -0,0 +1,49 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |b.alpha| unicode:: U+1D6C2 .. MATHEMATICAL BOLD SMALL ALPHA
.. |b.beta| unicode:: U+1D6C3 .. MATHEMATICAL BOLD SMALL BETA
.. |b.chi| unicode:: U+1D6D8 .. MATHEMATICAL BOLD SMALL CHI
.. |b.Delta| unicode:: U+1D6AB .. MATHEMATICAL BOLD CAPITAL DELTA
.. |b.delta| unicode:: U+1D6C5 .. MATHEMATICAL BOLD SMALL DELTA
.. |b.epsi| unicode:: U+1D6C6 .. MATHEMATICAL BOLD SMALL EPSILON
.. |b.epsiv| unicode:: U+1D6DC .. MATHEMATICAL BOLD EPSILON SYMBOL
.. |b.eta| unicode:: U+1D6C8 .. MATHEMATICAL BOLD SMALL ETA
.. |b.Gamma| unicode:: U+1D6AA .. MATHEMATICAL BOLD CAPITAL GAMMA
.. |b.gamma| unicode:: U+1D6C4 .. MATHEMATICAL BOLD SMALL GAMMA
.. |b.Gammad| unicode:: U+003DC .. GREEK LETTER DIGAMMA
.. |b.gammad| unicode:: U+003DD .. GREEK SMALL LETTER DIGAMMA
.. |b.iota| unicode:: U+1D6CA .. MATHEMATICAL BOLD SMALL IOTA
.. |b.kappa| unicode:: U+1D6CB .. MATHEMATICAL BOLD SMALL KAPPA
.. |b.kappav| unicode:: U+1D6DE .. MATHEMATICAL BOLD KAPPA SYMBOL
.. |b.Lambda| unicode:: U+1D6B2 .. MATHEMATICAL BOLD CAPITAL LAMDA
.. |b.lambda| unicode:: U+1D6CC .. MATHEMATICAL BOLD SMALL LAMDA
.. |b.mu| unicode:: U+1D6CD .. MATHEMATICAL BOLD SMALL MU
.. |b.nu| unicode:: U+1D6CE .. MATHEMATICAL BOLD SMALL NU
.. |b.Omega| unicode:: U+1D6C0 .. MATHEMATICAL BOLD CAPITAL OMEGA
.. |b.omega| unicode:: U+1D6DA .. MATHEMATICAL BOLD SMALL OMEGA
.. |b.Phi| unicode:: U+1D6BD .. MATHEMATICAL BOLD CAPITAL PHI
.. |b.phi| unicode:: U+1D6D7 .. MATHEMATICAL BOLD SMALL PHI
.. |b.phiv| unicode:: U+1D6DF .. MATHEMATICAL BOLD PHI SYMBOL
.. |b.Pi| unicode:: U+1D6B7 .. MATHEMATICAL BOLD CAPITAL PI
.. |b.pi| unicode:: U+1D6D1 .. MATHEMATICAL BOLD SMALL PI
.. |b.piv| unicode:: U+1D6E1 .. MATHEMATICAL BOLD PI SYMBOL
.. |b.Psi| unicode:: U+1D6BF .. MATHEMATICAL BOLD CAPITAL PSI
.. |b.psi| unicode:: U+1D6D9 .. MATHEMATICAL BOLD SMALL PSI
.. |b.rho| unicode:: U+1D6D2 .. MATHEMATICAL BOLD SMALL RHO
.. |b.rhov| unicode:: U+1D6E0 .. MATHEMATICAL BOLD RHO SYMBOL
.. |b.Sigma| unicode:: U+1D6BA .. MATHEMATICAL BOLD CAPITAL SIGMA
.. |b.sigma| unicode:: U+1D6D4 .. MATHEMATICAL BOLD SMALL SIGMA
.. |b.sigmav| unicode:: U+1D6D3 .. MATHEMATICAL BOLD SMALL FINAL SIGMA
.. |b.tau| unicode:: U+1D6D5 .. MATHEMATICAL BOLD SMALL TAU
.. |b.Theta| unicode:: U+1D6AF .. MATHEMATICAL BOLD CAPITAL THETA
.. |b.thetas| unicode:: U+1D6C9 .. MATHEMATICAL BOLD SMALL THETA
.. |b.thetav| unicode:: U+1D6DD .. MATHEMATICAL BOLD THETA SYMBOL
.. |b.Upsi| unicode:: U+1D6BC .. MATHEMATICAL BOLD CAPITAL UPSILON
.. |b.upsi| unicode:: U+1D6D6 .. MATHEMATICAL BOLD SMALL UPSILON
.. |b.Xi| unicode:: U+1D6B5 .. MATHEMATICAL BOLD CAPITAL XI
.. |b.xi| unicode:: U+1D6CF .. MATHEMATICAL BOLD SMALL XI
.. |b.zeta| unicode:: U+1D6C7 .. MATHEMATICAL BOLD SMALL ZETA
@@ -0,0 +1,8 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |b.Gammad| unicode:: U+003DC .. GREEK LETTER DIGAMMA
.. |b.gammad| unicode:: U+003DD .. GREEK SMALL LETTER DIGAMMA
@@ -0,0 +1,68 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |Aacute| unicode:: U+000C1 .. LATIN CAPITAL LETTER A WITH ACUTE
.. |aacute| unicode:: U+000E1 .. LATIN SMALL LETTER A WITH ACUTE
.. |Acirc| unicode:: U+000C2 .. LATIN CAPITAL LETTER A WITH CIRCUMFLEX
.. |acirc| unicode:: U+000E2 .. LATIN SMALL LETTER A WITH CIRCUMFLEX
.. |AElig| unicode:: U+000C6 .. LATIN CAPITAL LETTER AE
.. |aelig| unicode:: U+000E6 .. LATIN SMALL LETTER AE
.. |Agrave| unicode:: U+000C0 .. LATIN CAPITAL LETTER A WITH GRAVE
.. |agrave| unicode:: U+000E0 .. LATIN SMALL LETTER A WITH GRAVE
.. |Aring| unicode:: U+000C5 .. LATIN CAPITAL LETTER A WITH RING ABOVE
.. |aring| unicode:: U+000E5 .. LATIN SMALL LETTER A WITH RING ABOVE
.. |Atilde| unicode:: U+000C3 .. LATIN CAPITAL LETTER A WITH TILDE
.. |atilde| unicode:: U+000E3 .. LATIN SMALL LETTER A WITH TILDE
.. |Auml| unicode:: U+000C4 .. LATIN CAPITAL LETTER A WITH DIAERESIS
.. |auml| unicode:: U+000E4 .. LATIN SMALL LETTER A WITH DIAERESIS
.. |Ccedil| unicode:: U+000C7 .. LATIN CAPITAL LETTER C WITH CEDILLA
.. |ccedil| unicode:: U+000E7 .. LATIN SMALL LETTER C WITH CEDILLA
.. |Eacute| unicode:: U+000C9 .. LATIN CAPITAL LETTER E WITH ACUTE
.. |eacute| unicode:: U+000E9 .. LATIN SMALL LETTER E WITH ACUTE
.. |Ecirc| unicode:: U+000CA .. LATIN CAPITAL LETTER E WITH CIRCUMFLEX
.. |ecirc| unicode:: U+000EA .. LATIN SMALL LETTER E WITH CIRCUMFLEX
.. |Egrave| unicode:: U+000C8 .. LATIN CAPITAL LETTER E WITH GRAVE
.. |egrave| unicode:: U+000E8 .. LATIN SMALL LETTER E WITH GRAVE
.. |ETH| unicode:: U+000D0 .. LATIN CAPITAL LETTER ETH
.. |eth| unicode:: U+000F0 .. LATIN SMALL LETTER ETH
.. |Euml| unicode:: U+000CB .. LATIN CAPITAL LETTER E WITH DIAERESIS
.. |euml| unicode:: U+000EB .. LATIN SMALL LETTER E WITH DIAERESIS
.. |Iacute| unicode:: U+000CD .. LATIN CAPITAL LETTER I WITH ACUTE
.. |iacute| unicode:: U+000ED .. LATIN SMALL LETTER I WITH ACUTE
.. |Icirc| unicode:: U+000CE .. LATIN CAPITAL LETTER I WITH CIRCUMFLEX
.. |icirc| unicode:: U+000EE .. LATIN SMALL LETTER I WITH CIRCUMFLEX
.. |Igrave| unicode:: U+000CC .. LATIN CAPITAL LETTER I WITH GRAVE
.. |igrave| unicode:: U+000EC .. LATIN SMALL LETTER I WITH GRAVE
.. |Iuml| unicode:: U+000CF .. LATIN CAPITAL LETTER I WITH DIAERESIS
.. |iuml| unicode:: U+000EF .. LATIN SMALL LETTER I WITH DIAERESIS
.. |Ntilde| unicode:: U+000D1 .. LATIN CAPITAL LETTER N WITH TILDE
.. |ntilde| unicode:: U+000F1 .. LATIN SMALL LETTER N WITH TILDE
.. |Oacute| unicode:: U+000D3 .. LATIN CAPITAL LETTER O WITH ACUTE
.. |oacute| unicode:: U+000F3 .. LATIN SMALL LETTER O WITH ACUTE
.. |Ocirc| unicode:: U+000D4 .. LATIN CAPITAL LETTER O WITH CIRCUMFLEX
.. |ocirc| unicode:: U+000F4 .. LATIN SMALL LETTER O WITH CIRCUMFLEX
.. |Ograve| unicode:: U+000D2 .. LATIN CAPITAL LETTER O WITH GRAVE
.. |ograve| unicode:: U+000F2 .. LATIN SMALL LETTER O WITH GRAVE
.. |Oslash| unicode:: U+000D8 .. LATIN CAPITAL LETTER O WITH STROKE
.. |oslash| unicode:: U+000F8 .. LATIN SMALL LETTER O WITH STROKE
.. |Otilde| unicode:: U+000D5 .. LATIN CAPITAL LETTER O WITH TILDE
.. |otilde| unicode:: U+000F5 .. LATIN SMALL LETTER O WITH TILDE
.. |Ouml| unicode:: U+000D6 .. LATIN CAPITAL LETTER O WITH DIAERESIS
.. |ouml| unicode:: U+000F6 .. LATIN SMALL LETTER O WITH DIAERESIS
.. |szlig| unicode:: U+000DF .. LATIN SMALL LETTER SHARP S
.. |THORN| unicode:: U+000DE .. LATIN CAPITAL LETTER THORN
.. |thorn| unicode:: U+000FE .. LATIN SMALL LETTER THORN
.. |Uacute| unicode:: U+000DA .. LATIN CAPITAL LETTER U WITH ACUTE
.. |uacute| unicode:: U+000FA .. LATIN SMALL LETTER U WITH ACUTE
.. |Ucirc| unicode:: U+000DB .. LATIN CAPITAL LETTER U WITH CIRCUMFLEX
.. |ucirc| unicode:: U+000FB .. LATIN SMALL LETTER U WITH CIRCUMFLEX
.. |Ugrave| unicode:: U+000D9 .. LATIN CAPITAL LETTER U WITH GRAVE
.. |ugrave| unicode:: U+000F9 .. LATIN SMALL LETTER U WITH GRAVE
.. |Uuml| unicode:: U+000DC .. LATIN CAPITAL LETTER U WITH DIAERESIS
.. |uuml| unicode:: U+000FC .. LATIN SMALL LETTER U WITH DIAERESIS
.. |Yacute| unicode:: U+000DD .. LATIN CAPITAL LETTER Y WITH ACUTE
.. |yacute| unicode:: U+000FD .. LATIN SMALL LETTER Y WITH ACUTE
.. |yuml| unicode:: U+000FF .. LATIN SMALL LETTER Y WITH DIAERESIS
@@ -0,0 +1,128 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |Abreve| unicode:: U+00102 .. LATIN CAPITAL LETTER A WITH BREVE
.. |abreve| unicode:: U+00103 .. LATIN SMALL LETTER A WITH BREVE
.. |Amacr| unicode:: U+00100 .. LATIN CAPITAL LETTER A WITH MACRON
.. |amacr| unicode:: U+00101 .. LATIN SMALL LETTER A WITH MACRON
.. |Aogon| unicode:: U+00104 .. LATIN CAPITAL LETTER A WITH OGONEK
.. |aogon| unicode:: U+00105 .. LATIN SMALL LETTER A WITH OGONEK
.. |Cacute| unicode:: U+00106 .. LATIN CAPITAL LETTER C WITH ACUTE
.. |cacute| unicode:: U+00107 .. LATIN SMALL LETTER C WITH ACUTE
.. |Ccaron| unicode:: U+0010C .. LATIN CAPITAL LETTER C WITH CARON
.. |ccaron| unicode:: U+0010D .. LATIN SMALL LETTER C WITH CARON
.. |Ccirc| unicode:: U+00108 .. LATIN CAPITAL LETTER C WITH CIRCUMFLEX
.. |ccirc| unicode:: U+00109 .. LATIN SMALL LETTER C WITH CIRCUMFLEX
.. |Cdot| unicode:: U+0010A .. LATIN CAPITAL LETTER C WITH DOT ABOVE
.. |cdot| unicode:: U+0010B .. LATIN SMALL LETTER C WITH DOT ABOVE
.. |Dcaron| unicode:: U+0010E .. LATIN CAPITAL LETTER D WITH CARON
.. |dcaron| unicode:: U+0010F .. LATIN SMALL LETTER D WITH CARON
.. |Dstrok| unicode:: U+00110 .. LATIN CAPITAL LETTER D WITH STROKE
.. |dstrok| unicode:: U+00111 .. LATIN SMALL LETTER D WITH STROKE
.. |Ecaron| unicode:: U+0011A .. LATIN CAPITAL LETTER E WITH CARON
.. |ecaron| unicode:: U+0011B .. LATIN SMALL LETTER E WITH CARON
.. |Edot| unicode:: U+00116 .. LATIN CAPITAL LETTER E WITH DOT ABOVE
.. |edot| unicode:: U+00117 .. LATIN SMALL LETTER E WITH DOT ABOVE
.. |Emacr| unicode:: U+00112 .. LATIN CAPITAL LETTER E WITH MACRON
.. |emacr| unicode:: U+00113 .. LATIN SMALL LETTER E WITH MACRON
.. |ENG| unicode:: U+0014A .. LATIN CAPITAL LETTER ENG
.. |eng| unicode:: U+0014B .. LATIN SMALL LETTER ENG
.. |Eogon| unicode:: U+00118 .. LATIN CAPITAL LETTER E WITH OGONEK
.. |eogon| unicode:: U+00119 .. LATIN SMALL LETTER E WITH OGONEK
.. |gacute| unicode:: U+001F5 .. LATIN SMALL LETTER G WITH ACUTE
.. |Gbreve| unicode:: U+0011E .. LATIN CAPITAL LETTER G WITH BREVE
.. |gbreve| unicode:: U+0011F .. LATIN SMALL LETTER G WITH BREVE
.. |Gcedil| unicode:: U+00122 .. LATIN CAPITAL LETTER G WITH CEDILLA
.. |gcedil| unicode:: U+00123 .. LATIN SMALL LETTER G WITH CEDILLA
.. |Gcirc| unicode:: U+0011C .. LATIN CAPITAL LETTER G WITH CIRCUMFLEX
.. |gcirc| unicode:: U+0011D .. LATIN SMALL LETTER G WITH CIRCUMFLEX
.. |Gdot| unicode:: U+00120 .. LATIN CAPITAL LETTER G WITH DOT ABOVE
.. |gdot| unicode:: U+00121 .. LATIN SMALL LETTER G WITH DOT ABOVE
.. |Hcirc| unicode:: U+00124 .. LATIN CAPITAL LETTER H WITH CIRCUMFLEX
.. |hcirc| unicode:: U+00125 .. LATIN SMALL LETTER H WITH CIRCUMFLEX
.. |Hstrok| unicode:: U+00126 .. LATIN CAPITAL LETTER H WITH STROKE
.. |hstrok| unicode:: U+00127 .. LATIN SMALL LETTER H WITH STROKE
.. |Idot| unicode:: U+00130 .. LATIN CAPITAL LETTER I WITH DOT ABOVE
.. |IJlig| unicode:: U+00132 .. LATIN CAPITAL LIGATURE IJ
.. |ijlig| unicode:: U+00133 .. LATIN SMALL LIGATURE IJ
.. |Imacr| unicode:: U+0012A .. LATIN CAPITAL LETTER I WITH MACRON
.. |imacr| unicode:: U+0012B .. LATIN SMALL LETTER I WITH MACRON
.. |inodot| unicode:: U+00131 .. LATIN SMALL LETTER DOTLESS I
.. |Iogon| unicode:: U+0012E .. LATIN CAPITAL LETTER I WITH OGONEK
.. |iogon| unicode:: U+0012F .. LATIN SMALL LETTER I WITH OGONEK
.. |Itilde| unicode:: U+00128 .. LATIN CAPITAL LETTER I WITH TILDE
.. |itilde| unicode:: U+00129 .. LATIN SMALL LETTER I WITH TILDE
.. |Jcirc| unicode:: U+00134 .. LATIN CAPITAL LETTER J WITH CIRCUMFLEX
.. |jcirc| unicode:: U+00135 .. LATIN SMALL LETTER J WITH CIRCUMFLEX
.. |Kcedil| unicode:: U+00136 .. LATIN CAPITAL LETTER K WITH CEDILLA
.. |kcedil| unicode:: U+00137 .. LATIN SMALL LETTER K WITH CEDILLA
.. |kgreen| unicode:: U+00138 .. LATIN SMALL LETTER KRA
.. |Lacute| unicode:: U+00139 .. LATIN CAPITAL LETTER L WITH ACUTE
.. |lacute| unicode:: U+0013A .. LATIN SMALL LETTER L WITH ACUTE
.. |Lcaron| unicode:: U+0013D .. LATIN CAPITAL LETTER L WITH CARON
.. |lcaron| unicode:: U+0013E .. LATIN SMALL LETTER L WITH CARON
.. |Lcedil| unicode:: U+0013B .. LATIN CAPITAL LETTER L WITH CEDILLA
.. |lcedil| unicode:: U+0013C .. LATIN SMALL LETTER L WITH CEDILLA
.. |Lmidot| unicode:: U+0013F .. LATIN CAPITAL LETTER L WITH MIDDLE DOT
.. |lmidot| unicode:: U+00140 .. LATIN SMALL LETTER L WITH MIDDLE DOT
.. |Lstrok| unicode:: U+00141 .. LATIN CAPITAL LETTER L WITH STROKE
.. |lstrok| unicode:: U+00142 .. LATIN SMALL LETTER L WITH STROKE
.. |Nacute| unicode:: U+00143 .. LATIN CAPITAL LETTER N WITH ACUTE
.. |nacute| unicode:: U+00144 .. LATIN SMALL LETTER N WITH ACUTE
.. |napos| unicode:: U+00149 .. LATIN SMALL LETTER N PRECEDED BY APOSTROPHE
.. |Ncaron| unicode:: U+00147 .. LATIN CAPITAL LETTER N WITH CARON
.. |ncaron| unicode:: U+00148 .. LATIN SMALL LETTER N WITH CARON
.. |Ncedil| unicode:: U+00145 .. LATIN CAPITAL LETTER N WITH CEDILLA
.. |ncedil| unicode:: U+00146 .. LATIN SMALL LETTER N WITH CEDILLA
.. |Odblac| unicode:: U+00150 .. LATIN CAPITAL LETTER O WITH DOUBLE ACUTE
.. |odblac| unicode:: U+00151 .. LATIN SMALL LETTER O WITH DOUBLE ACUTE
.. |OElig| unicode:: U+00152 .. LATIN CAPITAL LIGATURE OE
.. |oelig| unicode:: U+00153 .. LATIN SMALL LIGATURE OE
.. |Omacr| unicode:: U+0014C .. LATIN CAPITAL LETTER O WITH MACRON
.. |omacr| unicode:: U+0014D .. LATIN SMALL LETTER O WITH MACRON
.. |Racute| unicode:: U+00154 .. LATIN CAPITAL LETTER R WITH ACUTE
.. |racute| unicode:: U+00155 .. LATIN SMALL LETTER R WITH ACUTE
.. |Rcaron| unicode:: U+00158 .. LATIN CAPITAL LETTER R WITH CARON
.. |rcaron| unicode:: U+00159 .. LATIN SMALL LETTER R WITH CARON
.. |Rcedil| unicode:: U+00156 .. LATIN CAPITAL LETTER R WITH CEDILLA
.. |rcedil| unicode:: U+00157 .. LATIN SMALL LETTER R WITH CEDILLA
.. |Sacute| unicode:: U+0015A .. LATIN CAPITAL LETTER S WITH ACUTE
.. |sacute| unicode:: U+0015B .. LATIN SMALL LETTER S WITH ACUTE
.. |Scaron| unicode:: U+00160 .. LATIN CAPITAL LETTER S WITH CARON
.. |scaron| unicode:: U+00161 .. LATIN SMALL LETTER S WITH CARON
.. |Scedil| unicode:: U+0015E .. LATIN CAPITAL LETTER S WITH CEDILLA
.. |scedil| unicode:: U+0015F .. LATIN SMALL LETTER S WITH CEDILLA
.. |Scirc| unicode:: U+0015C .. LATIN CAPITAL LETTER S WITH CIRCUMFLEX
.. |scirc| unicode:: U+0015D .. LATIN SMALL LETTER S WITH CIRCUMFLEX
.. |Tcaron| unicode:: U+00164 .. LATIN CAPITAL LETTER T WITH CARON
.. |tcaron| unicode:: U+00165 .. LATIN SMALL LETTER T WITH CARON
.. |Tcedil| unicode:: U+00162 .. LATIN CAPITAL LETTER T WITH CEDILLA
.. |tcedil| unicode:: U+00163 .. LATIN SMALL LETTER T WITH CEDILLA
.. |Tstrok| unicode:: U+00166 .. LATIN CAPITAL LETTER T WITH STROKE
.. |tstrok| unicode:: U+00167 .. LATIN SMALL LETTER T WITH STROKE
.. |Ubreve| unicode:: U+0016C .. LATIN CAPITAL LETTER U WITH BREVE
.. |ubreve| unicode:: U+0016D .. LATIN SMALL LETTER U WITH BREVE
.. |Udblac| unicode:: U+00170 .. LATIN CAPITAL LETTER U WITH DOUBLE ACUTE
.. |udblac| unicode:: U+00171 .. LATIN SMALL LETTER U WITH DOUBLE ACUTE
.. |Umacr| unicode:: U+0016A .. LATIN CAPITAL LETTER U WITH MACRON
.. |umacr| unicode:: U+0016B .. LATIN SMALL LETTER U WITH MACRON
.. |Uogon| unicode:: U+00172 .. LATIN CAPITAL LETTER U WITH OGONEK
.. |uogon| unicode:: U+00173 .. LATIN SMALL LETTER U WITH OGONEK
.. |Uring| unicode:: U+0016E .. LATIN CAPITAL LETTER U WITH RING ABOVE
.. |uring| unicode:: U+0016F .. LATIN SMALL LETTER U WITH RING ABOVE
.. |Utilde| unicode:: U+00168 .. LATIN CAPITAL LETTER U WITH TILDE
.. |utilde| unicode:: U+00169 .. LATIN SMALL LETTER U WITH TILDE
.. |Wcirc| unicode:: U+00174 .. LATIN CAPITAL LETTER W WITH CIRCUMFLEX
.. |wcirc| unicode:: U+00175 .. LATIN SMALL LETTER W WITH CIRCUMFLEX
.. |Ycirc| unicode:: U+00176 .. LATIN CAPITAL LETTER Y WITH CIRCUMFLEX
.. |ycirc| unicode:: U+00177 .. LATIN SMALL LETTER Y WITH CIRCUMFLEX
.. |Yuml| unicode:: U+00178 .. LATIN CAPITAL LETTER Y WITH DIAERESIS
.. |Zacute| unicode:: U+00179 .. LATIN CAPITAL LETTER Z WITH ACUTE
.. |zacute| unicode:: U+0017A .. LATIN SMALL LETTER Z WITH ACUTE
.. |Zcaron| unicode:: U+0017D .. LATIN CAPITAL LETTER Z WITH CARON
.. |zcaron| unicode:: U+0017E .. LATIN SMALL LETTER Z WITH CARON
.. |Zdot| unicode:: U+0017B .. LATIN CAPITAL LETTER Z WITH DOT ABOVE
.. |zdot| unicode:: U+0017C .. LATIN SMALL LETTER Z WITH DOT ABOVE
@@ -0,0 +1,58 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |Afr| unicode:: U+1D504 .. MATHEMATICAL FRAKTUR CAPITAL A
.. |afr| unicode:: U+1D51E .. MATHEMATICAL FRAKTUR SMALL A
.. |Bfr| unicode:: U+1D505 .. MATHEMATICAL FRAKTUR CAPITAL B
.. |bfr| unicode:: U+1D51F .. MATHEMATICAL FRAKTUR SMALL B
.. |Cfr| unicode:: U+0212D .. BLACK-LETTER CAPITAL C
.. |cfr| unicode:: U+1D520 .. MATHEMATICAL FRAKTUR SMALL C
.. |Dfr| unicode:: U+1D507 .. MATHEMATICAL FRAKTUR CAPITAL D
.. |dfr| unicode:: U+1D521 .. MATHEMATICAL FRAKTUR SMALL D
.. |Efr| unicode:: U+1D508 .. MATHEMATICAL FRAKTUR CAPITAL E
.. |efr| unicode:: U+1D522 .. MATHEMATICAL FRAKTUR SMALL E
.. |Ffr| unicode:: U+1D509 .. MATHEMATICAL FRAKTUR CAPITAL F
.. |ffr| unicode:: U+1D523 .. MATHEMATICAL FRAKTUR SMALL F
.. |Gfr| unicode:: U+1D50A .. MATHEMATICAL FRAKTUR CAPITAL G
.. |gfr| unicode:: U+1D524 .. MATHEMATICAL FRAKTUR SMALL G
.. |Hfr| unicode:: U+0210C .. BLACK-LETTER CAPITAL H
.. |hfr| unicode:: U+1D525 .. MATHEMATICAL FRAKTUR SMALL H
.. |Ifr| unicode:: U+02111 .. BLACK-LETTER CAPITAL I
.. |ifr| unicode:: U+1D526 .. MATHEMATICAL FRAKTUR SMALL I
.. |Jfr| unicode:: U+1D50D .. MATHEMATICAL FRAKTUR CAPITAL J
.. |jfr| unicode:: U+1D527 .. MATHEMATICAL FRAKTUR SMALL J
.. |Kfr| unicode:: U+1D50E .. MATHEMATICAL FRAKTUR CAPITAL K
.. |kfr| unicode:: U+1D528 .. MATHEMATICAL FRAKTUR SMALL K
.. |Lfr| unicode:: U+1D50F .. MATHEMATICAL FRAKTUR CAPITAL L
.. |lfr| unicode:: U+1D529 .. MATHEMATICAL FRAKTUR SMALL L
.. |Mfr| unicode:: U+1D510 .. MATHEMATICAL FRAKTUR CAPITAL M
.. |mfr| unicode:: U+1D52A .. MATHEMATICAL FRAKTUR SMALL M
.. |Nfr| unicode:: U+1D511 .. MATHEMATICAL FRAKTUR CAPITAL N
.. |nfr| unicode:: U+1D52B .. MATHEMATICAL FRAKTUR SMALL N
.. |Ofr| unicode:: U+1D512 .. MATHEMATICAL FRAKTUR CAPITAL O
.. |ofr| unicode:: U+1D52C .. MATHEMATICAL FRAKTUR SMALL O
.. |Pfr| unicode:: U+1D513 .. MATHEMATICAL FRAKTUR CAPITAL P
.. |pfr| unicode:: U+1D52D .. MATHEMATICAL FRAKTUR SMALL P
.. |Qfr| unicode:: U+1D514 .. MATHEMATICAL FRAKTUR CAPITAL Q
.. |qfr| unicode:: U+1D52E .. MATHEMATICAL FRAKTUR SMALL Q
.. |Rfr| unicode:: U+0211C .. BLACK-LETTER CAPITAL R
.. |rfr| unicode:: U+1D52F .. MATHEMATICAL FRAKTUR SMALL R
.. |Sfr| unicode:: U+1D516 .. MATHEMATICAL FRAKTUR CAPITAL S
.. |sfr| unicode:: U+1D530 .. MATHEMATICAL FRAKTUR SMALL S
.. |Tfr| unicode:: U+1D517 .. MATHEMATICAL FRAKTUR CAPITAL T
.. |tfr| unicode:: U+1D531 .. MATHEMATICAL FRAKTUR SMALL T
.. |Ufr| unicode:: U+1D518 .. MATHEMATICAL FRAKTUR CAPITAL U
.. |ufr| unicode:: U+1D532 .. MATHEMATICAL FRAKTUR SMALL U
.. |Vfr| unicode:: U+1D519 .. MATHEMATICAL FRAKTUR CAPITAL V
.. |vfr| unicode:: U+1D533 .. MATHEMATICAL FRAKTUR SMALL V
.. |Wfr| unicode:: U+1D51A .. MATHEMATICAL FRAKTUR CAPITAL W
.. |wfr| unicode:: U+1D534 .. MATHEMATICAL FRAKTUR SMALL W
.. |Xfr| unicode:: U+1D51B .. MATHEMATICAL FRAKTUR CAPITAL X
.. |xfr| unicode:: U+1D535 .. MATHEMATICAL FRAKTUR SMALL X
.. |Yfr| unicode:: U+1D51C .. MATHEMATICAL FRAKTUR CAPITAL Y
.. |yfr| unicode:: U+1D536 .. MATHEMATICAL FRAKTUR SMALL Y
.. |Zfr| unicode:: U+02128 .. BLACK-LETTER CAPITAL Z
.. |zfr| unicode:: U+1D537 .. MATHEMATICAL FRAKTUR SMALL Z
@@ -0,0 +1,11 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |Cfr| unicode:: U+0212D .. BLACK-LETTER CAPITAL C
.. |Hfr| unicode:: U+0210C .. BLACK-LETTER CAPITAL H
.. |Ifr| unicode:: U+02111 .. BLACK-LETTER CAPITAL I
.. |Rfr| unicode:: U+0211C .. BLACK-LETTER CAPITAL R
.. |Zfr| unicode:: U+02128 .. BLACK-LETTER CAPITAL Z
@@ -0,0 +1,32 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |Aopf| unicode:: U+1D538 .. MATHEMATICAL DOUBLE-STRUCK CAPITAL A
.. |Bopf| unicode:: U+1D539 .. MATHEMATICAL DOUBLE-STRUCK CAPITAL B
.. |Copf| unicode:: U+02102 .. DOUBLE-STRUCK CAPITAL C
.. |Dopf| unicode:: U+1D53B .. MATHEMATICAL DOUBLE-STRUCK CAPITAL D
.. |Eopf| unicode:: U+1D53C .. MATHEMATICAL DOUBLE-STRUCK CAPITAL E
.. |Fopf| unicode:: U+1D53D .. MATHEMATICAL DOUBLE-STRUCK CAPITAL F
.. |Gopf| unicode:: U+1D53E .. MATHEMATICAL DOUBLE-STRUCK CAPITAL G
.. |Hopf| unicode:: U+0210D .. DOUBLE-STRUCK CAPITAL H
.. |Iopf| unicode:: U+1D540 .. MATHEMATICAL DOUBLE-STRUCK CAPITAL I
.. |Jopf| unicode:: U+1D541 .. MATHEMATICAL DOUBLE-STRUCK CAPITAL J
.. |Kopf| unicode:: U+1D542 .. MATHEMATICAL DOUBLE-STRUCK CAPITAL K
.. |Lopf| unicode:: U+1D543 .. MATHEMATICAL DOUBLE-STRUCK CAPITAL L
.. |Mopf| unicode:: U+1D544 .. MATHEMATICAL DOUBLE-STRUCK CAPITAL M
.. |Nopf| unicode:: U+02115 .. DOUBLE-STRUCK CAPITAL N
.. |Oopf| unicode:: U+1D546 .. MATHEMATICAL DOUBLE-STRUCK CAPITAL O
.. |Popf| unicode:: U+02119 .. DOUBLE-STRUCK CAPITAL P
.. |Qopf| unicode:: U+0211A .. DOUBLE-STRUCK CAPITAL Q
.. |Ropf| unicode:: U+0211D .. DOUBLE-STRUCK CAPITAL R
.. |Sopf| unicode:: U+1D54A .. MATHEMATICAL DOUBLE-STRUCK CAPITAL S
.. |Topf| unicode:: U+1D54B .. MATHEMATICAL DOUBLE-STRUCK CAPITAL T
.. |Uopf| unicode:: U+1D54C .. MATHEMATICAL DOUBLE-STRUCK CAPITAL U
.. |Vopf| unicode:: U+1D54D .. MATHEMATICAL DOUBLE-STRUCK CAPITAL V
.. |Wopf| unicode:: U+1D54E .. MATHEMATICAL DOUBLE-STRUCK CAPITAL W
.. |Xopf| unicode:: U+1D54F .. MATHEMATICAL DOUBLE-STRUCK CAPITAL X
.. |Yopf| unicode:: U+1D550 .. MATHEMATICAL DOUBLE-STRUCK CAPITAL Y
.. |Zopf| unicode:: U+02124 .. DOUBLE-STRUCK CAPITAL Z
@@ -0,0 +1,13 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |Copf| unicode:: U+02102 .. DOUBLE-STRUCK CAPITAL C
.. |Hopf| unicode:: U+0210D .. DOUBLE-STRUCK CAPITAL H
.. |Nopf| unicode:: U+02115 .. DOUBLE-STRUCK CAPITAL N
.. |Popf| unicode:: U+02119 .. DOUBLE-STRUCK CAPITAL P
.. |Qopf| unicode:: U+0211A .. DOUBLE-STRUCK CAPITAL Q
.. |Ropf| unicode:: U+0211D .. DOUBLE-STRUCK CAPITAL R
.. |Zopf| unicode:: U+02124 .. DOUBLE-STRUCK CAPITAL Z
@@ -0,0 +1,58 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |Ascr| unicode:: U+1D49C .. MATHEMATICAL SCRIPT CAPITAL A
.. |ascr| unicode:: U+1D4B6 .. MATHEMATICAL SCRIPT SMALL A
.. |Bscr| unicode:: U+0212C .. SCRIPT CAPITAL B
.. |bscr| unicode:: U+1D4B7 .. MATHEMATICAL SCRIPT SMALL B
.. |Cscr| unicode:: U+1D49E .. MATHEMATICAL SCRIPT CAPITAL C
.. |cscr| unicode:: U+1D4B8 .. MATHEMATICAL SCRIPT SMALL C
.. |Dscr| unicode:: U+1D49F .. MATHEMATICAL SCRIPT CAPITAL D
.. |dscr| unicode:: U+1D4B9 .. MATHEMATICAL SCRIPT SMALL D
.. |Escr| unicode:: U+02130 .. SCRIPT CAPITAL E
.. |escr| unicode:: U+0212F .. SCRIPT SMALL E
.. |Fscr| unicode:: U+02131 .. SCRIPT CAPITAL F
.. |fscr| unicode:: U+1D4BB .. MATHEMATICAL SCRIPT SMALL F
.. |Gscr| unicode:: U+1D4A2 .. MATHEMATICAL SCRIPT CAPITAL G
.. |gscr| unicode:: U+0210A .. SCRIPT SMALL G
.. |Hscr| unicode:: U+0210B .. SCRIPT CAPITAL H
.. |hscr| unicode:: U+1D4BD .. MATHEMATICAL SCRIPT SMALL H
.. |Iscr| unicode:: U+02110 .. SCRIPT CAPITAL I
.. |iscr| unicode:: U+1D4BE .. MATHEMATICAL SCRIPT SMALL I
.. |Jscr| unicode:: U+1D4A5 .. MATHEMATICAL SCRIPT CAPITAL J
.. |jscr| unicode:: U+1D4BF .. MATHEMATICAL SCRIPT SMALL J
.. |Kscr| unicode:: U+1D4A6 .. MATHEMATICAL SCRIPT CAPITAL K
.. |kscr| unicode:: U+1D4C0 .. MATHEMATICAL SCRIPT SMALL K
.. |Lscr| unicode:: U+02112 .. SCRIPT CAPITAL L
.. |lscr| unicode:: U+1D4C1 .. MATHEMATICAL SCRIPT SMALL L
.. |Mscr| unicode:: U+02133 .. SCRIPT CAPITAL M
.. |mscr| unicode:: U+1D4C2 .. MATHEMATICAL SCRIPT SMALL M
.. |Nscr| unicode:: U+1D4A9 .. MATHEMATICAL SCRIPT CAPITAL N
.. |nscr| unicode:: U+1D4C3 .. MATHEMATICAL SCRIPT SMALL N
.. |Oscr| unicode:: U+1D4AA .. MATHEMATICAL SCRIPT CAPITAL O
.. |oscr| unicode:: U+02134 .. SCRIPT SMALL O
.. |Pscr| unicode:: U+1D4AB .. MATHEMATICAL SCRIPT CAPITAL P
.. |pscr| unicode:: U+1D4C5 .. MATHEMATICAL SCRIPT SMALL P
.. |Qscr| unicode:: U+1D4AC .. MATHEMATICAL SCRIPT CAPITAL Q
.. |qscr| unicode:: U+1D4C6 .. MATHEMATICAL SCRIPT SMALL Q
.. |Rscr| unicode:: U+0211B .. SCRIPT CAPITAL R
.. |rscr| unicode:: U+1D4C7 .. MATHEMATICAL SCRIPT SMALL R
.. |Sscr| unicode:: U+1D4AE .. MATHEMATICAL SCRIPT CAPITAL S
.. |sscr| unicode:: U+1D4C8 .. MATHEMATICAL SCRIPT SMALL S
.. |Tscr| unicode:: U+1D4AF .. MATHEMATICAL SCRIPT CAPITAL T
.. |tscr| unicode:: U+1D4C9 .. MATHEMATICAL SCRIPT SMALL T
.. |Uscr| unicode:: U+1D4B0 .. MATHEMATICAL SCRIPT CAPITAL U
.. |uscr| unicode:: U+1D4CA .. MATHEMATICAL SCRIPT SMALL U
.. |Vscr| unicode:: U+1D4B1 .. MATHEMATICAL SCRIPT CAPITAL V
.. |vscr| unicode:: U+1D4CB .. MATHEMATICAL SCRIPT SMALL V
.. |Wscr| unicode:: U+1D4B2 .. MATHEMATICAL SCRIPT CAPITAL W
.. |wscr| unicode:: U+1D4CC .. MATHEMATICAL SCRIPT SMALL W
.. |Xscr| unicode:: U+1D4B3 .. MATHEMATICAL SCRIPT CAPITAL X
.. |xscr| unicode:: U+1D4CD .. MATHEMATICAL SCRIPT SMALL X
.. |Yscr| unicode:: U+1D4B4 .. MATHEMATICAL SCRIPT CAPITAL Y
.. |yscr| unicode:: U+1D4CE .. MATHEMATICAL SCRIPT SMALL Y
.. |Zscr| unicode:: U+1D4B5 .. MATHEMATICAL SCRIPT CAPITAL Z
.. |zscr| unicode:: U+1D4CF .. MATHEMATICAL SCRIPT SMALL Z
@@ -0,0 +1,17 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |Bscr| unicode:: U+0212C .. SCRIPT CAPITAL B
.. |Escr| unicode:: U+02130 .. SCRIPT CAPITAL E
.. |escr| unicode:: U+0212F .. SCRIPT SMALL E
.. |Fscr| unicode:: U+02131 .. SCRIPT CAPITAL F
.. |gscr| unicode:: U+0210A .. SCRIPT SMALL G
.. |Hscr| unicode:: U+0210B .. SCRIPT CAPITAL H
.. |Iscr| unicode:: U+02110 .. SCRIPT CAPITAL I
.. |Lscr| unicode:: U+02112 .. SCRIPT CAPITAL L
.. |Mscr| unicode:: U+02133 .. SCRIPT CAPITAL M
.. |oscr| unicode:: U+02134 .. SCRIPT SMALL O
.. |Rscr| unicode:: U+0211B .. SCRIPT CAPITAL R
@@ -0,0 +1,82 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |amp| unicode:: U+00026 .. AMPERSAND
.. |apos| unicode:: U+00027 .. APOSTROPHE
.. |ast| unicode:: U+0002A .. ASTERISK
.. |brvbar| unicode:: U+000A6 .. BROKEN BAR
.. |bsol| unicode:: U+0005C .. REVERSE SOLIDUS
.. |cent| unicode:: U+000A2 .. CENT SIGN
.. |colon| unicode:: U+0003A .. COLON
.. |comma| unicode:: U+0002C .. COMMA
.. |commat| unicode:: U+00040 .. COMMERCIAL AT
.. |copy| unicode:: U+000A9 .. COPYRIGHT SIGN
.. |curren| unicode:: U+000A4 .. CURRENCY SIGN
.. |darr| unicode:: U+02193 .. DOWNWARDS ARROW
.. |deg| unicode:: U+000B0 .. DEGREE SIGN
.. |divide| unicode:: U+000F7 .. DIVISION SIGN
.. |dollar| unicode:: U+00024 .. DOLLAR SIGN
.. |equals| unicode:: U+0003D .. EQUALS SIGN
.. |excl| unicode:: U+00021 .. EXCLAMATION MARK
.. |frac12| unicode:: U+000BD .. VULGAR FRACTION ONE HALF
.. |frac14| unicode:: U+000BC .. VULGAR FRACTION ONE QUARTER
.. |frac18| unicode:: U+0215B .. VULGAR FRACTION ONE EIGHTH
.. |frac34| unicode:: U+000BE .. VULGAR FRACTION THREE QUARTERS
.. |frac38| unicode:: U+0215C .. VULGAR FRACTION THREE EIGHTHS
.. |frac58| unicode:: U+0215D .. VULGAR FRACTION FIVE EIGHTHS
.. |frac78| unicode:: U+0215E .. VULGAR FRACTION SEVEN EIGHTHS
.. |gt| unicode:: U+0003E .. GREATER-THAN SIGN
.. |half| unicode:: U+000BD .. VULGAR FRACTION ONE HALF
.. |horbar| unicode:: U+02015 .. HORIZONTAL BAR
.. |hyphen| unicode:: U+02010 .. HYPHEN
.. |iexcl| unicode:: U+000A1 .. INVERTED EXCLAMATION MARK
.. |iquest| unicode:: U+000BF .. INVERTED QUESTION MARK
.. |laquo| unicode:: U+000AB .. LEFT-POINTING DOUBLE ANGLE QUOTATION MARK
.. |larr| unicode:: U+02190 .. LEFTWARDS ARROW
.. |lcub| unicode:: U+0007B .. LEFT CURLY BRACKET
.. |ldquo| unicode:: U+0201C .. LEFT DOUBLE QUOTATION MARK
.. |lowbar| unicode:: U+0005F .. LOW LINE
.. |lpar| unicode:: U+00028 .. LEFT PARENTHESIS
.. |lsqb| unicode:: U+0005B .. LEFT SQUARE BRACKET
.. |lsquo| unicode:: U+02018 .. LEFT SINGLE QUOTATION MARK
.. |lt| unicode:: U+0003C .. LESS-THAN SIGN
.. |micro| unicode:: U+000B5 .. MICRO SIGN
.. |middot| unicode:: U+000B7 .. MIDDLE DOT
.. |nbsp| unicode:: U+000A0 .. NO-BREAK SPACE
.. |not| unicode:: U+000AC .. NOT SIGN
.. |num| unicode:: U+00023 .. NUMBER SIGN
.. |ohm| unicode:: U+02126 .. OHM SIGN
.. |ordf| unicode:: U+000AA .. FEMININE ORDINAL INDICATOR
.. |ordm| unicode:: U+000BA .. MASCULINE ORDINAL INDICATOR
.. |para| unicode:: U+000B6 .. PILCROW SIGN
.. |percnt| unicode:: U+00025 .. PERCENT SIGN
.. |period| unicode:: U+0002E .. FULL STOP
.. |plus| unicode:: U+0002B .. PLUS SIGN
.. |plusmn| unicode:: U+000B1 .. PLUS-MINUS SIGN
.. |pound| unicode:: U+000A3 .. POUND SIGN
.. |quest| unicode:: U+0003F .. QUESTION MARK
.. |quot| unicode:: U+00022 .. QUOTATION MARK
.. |raquo| unicode:: U+000BB .. RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK
.. |rarr| unicode:: U+02192 .. RIGHTWARDS ARROW
.. |rcub| unicode:: U+0007D .. RIGHT CURLY BRACKET
.. |rdquo| unicode:: U+0201D .. RIGHT DOUBLE QUOTATION MARK
.. |reg| unicode:: U+000AE .. REGISTERED SIGN
.. |rpar| unicode:: U+00029 .. RIGHT PARENTHESIS
.. |rsqb| unicode:: U+0005D .. RIGHT SQUARE BRACKET
.. |rsquo| unicode:: U+02019 .. RIGHT SINGLE QUOTATION MARK
.. |sect| unicode:: U+000A7 .. SECTION SIGN
.. |semi| unicode:: U+0003B .. SEMICOLON
.. |shy| unicode:: U+000AD .. SOFT HYPHEN
.. |sol| unicode:: U+0002F .. SOLIDUS
.. |sung| unicode:: U+0266A .. EIGHTH NOTE
.. |sup1| unicode:: U+000B9 .. SUPERSCRIPT ONE
.. |sup2| unicode:: U+000B2 .. SUPERSCRIPT TWO
.. |sup3| unicode:: U+000B3 .. SUPERSCRIPT THREE
.. |times| unicode:: U+000D7 .. MULTIPLICATION SIGN
.. |trade| unicode:: U+02122 .. TRADE MARK SIGN
.. |uarr| unicode:: U+02191 .. UPWARDS ARROW
.. |verbar| unicode:: U+0007C .. VERTICAL LINE
.. |yen| unicode:: U+000A5 .. YEN SIGN
@@ -0,0 +1,90 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |blank| unicode:: U+02423 .. OPEN BOX
.. |blk12| unicode:: U+02592 .. MEDIUM SHADE
.. |blk14| unicode:: U+02591 .. LIGHT SHADE
.. |blk34| unicode:: U+02593 .. DARK SHADE
.. |block| unicode:: U+02588 .. FULL BLOCK
.. |bull| unicode:: U+02022 .. BULLET
.. |caret| unicode:: U+02041 .. CARET INSERTION POINT
.. |check| unicode:: U+02713 .. CHECK MARK
.. |cir| unicode:: U+025CB .. WHITE CIRCLE
.. |clubs| unicode:: U+02663 .. BLACK CLUB SUIT
.. |copysr| unicode:: U+02117 .. SOUND RECORDING COPYRIGHT
.. |cross| unicode:: U+02717 .. BALLOT X
.. |Dagger| unicode:: U+02021 .. DOUBLE DAGGER
.. |dagger| unicode:: U+02020 .. DAGGER
.. |dash| unicode:: U+02010 .. HYPHEN
.. |diams| unicode:: U+02666 .. BLACK DIAMOND SUIT
.. |dlcrop| unicode:: U+0230D .. BOTTOM LEFT CROP
.. |drcrop| unicode:: U+0230C .. BOTTOM RIGHT CROP
.. |dtri| unicode:: U+025BF .. WHITE DOWN-POINTING SMALL TRIANGLE
.. |dtrif| unicode:: U+025BE .. BLACK DOWN-POINTING SMALL TRIANGLE
.. |emsp| unicode:: U+02003 .. EM SPACE
.. |emsp13| unicode:: U+02004 .. THREE-PER-EM SPACE
.. |emsp14| unicode:: U+02005 .. FOUR-PER-EM SPACE
.. |ensp| unicode:: U+02002 .. EN SPACE
.. |female| unicode:: U+02640 .. FEMALE SIGN
.. |ffilig| unicode:: U+0FB03 .. LATIN SMALL LIGATURE FFI
.. |fflig| unicode:: U+0FB00 .. LATIN SMALL LIGATURE FF
.. |ffllig| unicode:: U+0FB04 .. LATIN SMALL LIGATURE FFL
.. |filig| unicode:: U+0FB01 .. LATIN SMALL LIGATURE FI
.. |flat| unicode:: U+0266D .. MUSIC FLAT SIGN
.. |fllig| unicode:: U+0FB02 .. LATIN SMALL LIGATURE FL
.. |frac13| unicode:: U+02153 .. VULGAR FRACTION ONE THIRD
.. |frac15| unicode:: U+02155 .. VULGAR FRACTION ONE FIFTH
.. |frac16| unicode:: U+02159 .. VULGAR FRACTION ONE SIXTH
.. |frac23| unicode:: U+02154 .. VULGAR FRACTION TWO THIRDS
.. |frac25| unicode:: U+02156 .. VULGAR FRACTION TWO FIFTHS
.. |frac35| unicode:: U+02157 .. VULGAR FRACTION THREE FIFTHS
.. |frac45| unicode:: U+02158 .. VULGAR FRACTION FOUR FIFTHS
.. |frac56| unicode:: U+0215A .. VULGAR FRACTION FIVE SIXTHS
.. |hairsp| unicode:: U+0200A .. HAIR SPACE
.. |hearts| unicode:: U+02665 .. BLACK HEART SUIT
.. |hellip| unicode:: U+02026 .. HORIZONTAL ELLIPSIS
.. |hybull| unicode:: U+02043 .. HYPHEN BULLET
.. |incare| unicode:: U+02105 .. CARE OF
.. |ldquor| unicode:: U+0201E .. DOUBLE LOW-9 QUOTATION MARK
.. |lhblk| unicode:: U+02584 .. LOWER HALF BLOCK
.. |loz| unicode:: U+025CA .. LOZENGE
.. |lozf| unicode:: U+029EB .. BLACK LOZENGE
.. |lsquor| unicode:: U+0201A .. SINGLE LOW-9 QUOTATION MARK
.. |ltri| unicode:: U+025C3 .. WHITE LEFT-POINTING SMALL TRIANGLE
.. |ltrif| unicode:: U+025C2 .. BLACK LEFT-POINTING SMALL TRIANGLE
.. |male| unicode:: U+02642 .. MALE SIGN
.. |malt| unicode:: U+02720 .. MALTESE CROSS
.. |marker| unicode:: U+025AE .. BLACK VERTICAL RECTANGLE
.. |mdash| unicode:: U+02014 .. EM DASH
.. |mldr| unicode:: U+02026 .. HORIZONTAL ELLIPSIS
.. |natur| unicode:: U+0266E .. MUSIC NATURAL SIGN
.. |ndash| unicode:: U+02013 .. EN DASH
.. |nldr| unicode:: U+02025 .. TWO DOT LEADER
.. |numsp| unicode:: U+02007 .. FIGURE SPACE
.. |phone| unicode:: U+0260E .. BLACK TELEPHONE
.. |puncsp| unicode:: U+02008 .. PUNCTUATION SPACE
.. |rdquor| unicode:: U+0201D .. RIGHT DOUBLE QUOTATION MARK
.. |rect| unicode:: U+025AD .. WHITE RECTANGLE
.. |rsquor| unicode:: U+02019 .. RIGHT SINGLE QUOTATION MARK
.. |rtri| unicode:: U+025B9 .. WHITE RIGHT-POINTING SMALL TRIANGLE
.. |rtrif| unicode:: U+025B8 .. BLACK RIGHT-POINTING SMALL TRIANGLE
.. |rx| unicode:: U+0211E .. PRESCRIPTION TAKE
.. |sext| unicode:: U+02736 .. SIX POINTED BLACK STAR
.. |sharp| unicode:: U+0266F .. MUSIC SHARP SIGN
.. |spades| unicode:: U+02660 .. BLACK SPADE SUIT
.. |squ| unicode:: U+025A1 .. WHITE SQUARE
.. |squf| unicode:: U+025AA .. BLACK SMALL SQUARE
.. |star| unicode:: U+02606 .. WHITE STAR
.. |starf| unicode:: U+02605 .. BLACK STAR
.. |target| unicode:: U+02316 .. POSITION INDICATOR
.. |telrec| unicode:: U+02315 .. TELEPHONE RECORDER
.. |thinsp| unicode:: U+02009 .. THIN SPACE
.. |uhblk| unicode:: U+02580 .. UPPER HALF BLOCK
.. |ulcrop| unicode:: U+0230F .. TOP LEFT CROP
.. |urcrop| unicode:: U+0230E .. TOP RIGHT CROP
.. |utri| unicode:: U+025B5 .. WHITE UP-POINTING SMALL TRIANGLE
.. |utrif| unicode:: U+025B4 .. BLACK UP-POINTING SMALL TRIANGLE
.. |vellip| unicode:: U+022EE .. VERTICAL ELLIPSIS
@@ -0,0 +1,168 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |acd| unicode:: U+0223F .. SINE WAVE
.. |aleph| unicode:: U+02135 .. ALEF SYMBOL
.. |And| unicode:: U+02A53 .. DOUBLE LOGICAL AND
.. |and| unicode:: U+02227 .. LOGICAL AND
.. |andand| unicode:: U+02A55 .. TWO INTERSECTING LOGICAL AND
.. |andd| unicode:: U+02A5C .. LOGICAL AND WITH HORIZONTAL DASH
.. |andslope| unicode:: U+02A58 .. SLOPING LARGE AND
.. |andv| unicode:: U+02A5A .. LOGICAL AND WITH MIDDLE STEM
.. |ang90| unicode:: U+0221F .. RIGHT ANGLE
.. |angrt| unicode:: U+0221F .. RIGHT ANGLE
.. |angsph| unicode:: U+02222 .. SPHERICAL ANGLE
.. |angst| unicode:: U+0212B .. ANGSTROM SIGN
.. |ap| unicode:: U+02248 .. ALMOST EQUAL TO
.. |apacir| unicode:: U+02A6F .. ALMOST EQUAL TO WITH CIRCUMFLEX ACCENT
.. |awconint| unicode:: U+02233 .. ANTICLOCKWISE CONTOUR INTEGRAL
.. |awint| unicode:: U+02A11 .. ANTICLOCKWISE INTEGRATION
.. |becaus| unicode:: U+02235 .. BECAUSE
.. |bernou| unicode:: U+0212C .. SCRIPT CAPITAL B
.. |bne| unicode:: U+0003D U+020E5 .. EQUALS SIGN with reverse slash
.. |bnequiv| unicode:: U+02261 U+020E5 .. IDENTICAL TO with reverse slash
.. |bNot| unicode:: U+02AED .. REVERSED DOUBLE STROKE NOT SIGN
.. |bnot| unicode:: U+02310 .. REVERSED NOT SIGN
.. |bottom| unicode:: U+022A5 .. UP TACK
.. |cap| unicode:: U+02229 .. INTERSECTION
.. |Cconint| unicode:: U+02230 .. VOLUME INTEGRAL
.. |cirfnint| unicode:: U+02A10 .. CIRCULATION FUNCTION
.. |compfn| unicode:: U+02218 .. RING OPERATOR
.. |cong| unicode:: U+02245 .. APPROXIMATELY EQUAL TO
.. |Conint| unicode:: U+0222F .. SURFACE INTEGRAL
.. |conint| unicode:: U+0222E .. CONTOUR INTEGRAL
.. |ctdot| unicode:: U+022EF .. MIDLINE HORIZONTAL ELLIPSIS
.. |cup| unicode:: U+0222A .. UNION
.. |cwconint| unicode:: U+02232 .. CLOCKWISE CONTOUR INTEGRAL
.. |cwint| unicode:: U+02231 .. CLOCKWISE INTEGRAL
.. |cylcty| unicode:: U+0232D .. CYLINDRICITY
.. |disin| unicode:: U+022F2 .. ELEMENT OF WITH LONG HORIZONTAL STROKE
.. |Dot| unicode:: U+000A8 .. DIAERESIS
.. |DotDot| unicode:: U+020DC .. COMBINING FOUR DOTS ABOVE
.. |dsol| unicode:: U+029F6 .. SOLIDUS WITH OVERBAR
.. |dtdot| unicode:: U+022F1 .. DOWN RIGHT DIAGONAL ELLIPSIS
.. |dwangle| unicode:: U+029A6 .. OBLIQUE ANGLE OPENING UP
.. |elinters| unicode:: U+0FFFD .. REPLACEMENT CHARACTER
.. |epar| unicode:: U+022D5 .. EQUAL AND PARALLEL TO
.. |eparsl| unicode:: U+029E3 .. EQUALS SIGN AND SLANTED PARALLEL
.. |equiv| unicode:: U+02261 .. IDENTICAL TO
.. |eqvparsl| unicode:: U+029E5 .. IDENTICAL TO AND SLANTED PARALLEL
.. |exist| unicode:: U+02203 .. THERE EXISTS
.. |fltns| unicode:: U+025B1 .. WHITE PARALLELOGRAM
.. |fnof| unicode:: U+00192 .. LATIN SMALL LETTER F WITH HOOK
.. |forall| unicode:: U+02200 .. FOR ALL
.. |fpartint| unicode:: U+02A0D .. FINITE PART INTEGRAL
.. |ge| unicode:: U+02265 .. GREATER-THAN OR EQUAL TO
.. |hamilt| unicode:: U+0210B .. SCRIPT CAPITAL H
.. |iff| unicode:: U+021D4 .. LEFT RIGHT DOUBLE ARROW
.. |iinfin| unicode:: U+029DC .. INCOMPLETE INFINITY
.. |imped| unicode:: U+001B5 .. LATIN CAPITAL LETTER Z WITH STROKE
.. |infin| unicode:: U+0221E .. INFINITY
.. |infintie| unicode:: U+029DD .. TIE OVER INFINITY
.. |Int| unicode:: U+0222C .. DOUBLE INTEGRAL
.. |int| unicode:: U+0222B .. INTEGRAL
.. |intlarhk| unicode:: U+02A17 .. INTEGRAL WITH LEFTWARDS ARROW WITH HOOK
.. |isin| unicode:: U+02208 .. ELEMENT OF
.. |isindot| unicode:: U+022F5 .. ELEMENT OF WITH DOT ABOVE
.. |isinE| unicode:: U+022F9 .. ELEMENT OF WITH TWO HORIZONTAL STROKES
.. |isins| unicode:: U+022F4 .. SMALL ELEMENT OF WITH VERTICAL BAR AT END OF HORIZONTAL STROKE
.. |isinsv| unicode:: U+022F3 .. ELEMENT OF WITH VERTICAL BAR AT END OF HORIZONTAL STROKE
.. |isinv| unicode:: U+02208 .. ELEMENT OF
.. |lagran| unicode:: U+02112 .. SCRIPT CAPITAL L
.. |Lang| unicode:: U+0300A .. LEFT DOUBLE ANGLE BRACKET
.. |lang| unicode:: U+02329 .. LEFT-POINTING ANGLE BRACKET
.. |lArr| unicode:: U+021D0 .. LEFTWARDS DOUBLE ARROW
.. |lbbrk| unicode:: U+03014 .. LEFT TORTOISE SHELL BRACKET
.. |le| unicode:: U+02264 .. LESS-THAN OR EQUAL TO
.. |loang| unicode:: U+03018 .. LEFT WHITE TORTOISE SHELL BRACKET
.. |lobrk| unicode:: U+0301A .. LEFT WHITE SQUARE BRACKET
.. |lopar| unicode:: U+02985 .. LEFT WHITE PARENTHESIS
.. |lowast| unicode:: U+02217 .. ASTERISK OPERATOR
.. |minus| unicode:: U+02212 .. MINUS SIGN
.. |mnplus| unicode:: U+02213 .. MINUS-OR-PLUS SIGN
.. |nabla| unicode:: U+02207 .. NABLA
.. |ne| unicode:: U+02260 .. NOT EQUAL TO
.. |nedot| unicode:: U+02250 U+00338 .. APPROACHES THE LIMIT with slash
.. |nhpar| unicode:: U+02AF2 .. PARALLEL WITH HORIZONTAL STROKE
.. |ni| unicode:: U+0220B .. CONTAINS AS MEMBER
.. |nis| unicode:: U+022FC .. SMALL CONTAINS WITH VERTICAL BAR AT END OF HORIZONTAL STROKE
.. |nisd| unicode:: U+022FA .. CONTAINS WITH LONG HORIZONTAL STROKE
.. |niv| unicode:: U+0220B .. CONTAINS AS MEMBER
.. |Not| unicode:: U+02AEC .. DOUBLE STROKE NOT SIGN
.. |notin| unicode:: U+02209 .. NOT AN ELEMENT OF
.. |notindot| unicode:: U+022F5 U+00338 .. ELEMENT OF WITH DOT ABOVE with slash
.. |notinE| unicode:: U+022F9 U+00338 .. ELEMENT OF WITH TWO HORIZONTAL STROKES with slash
.. |notinva| unicode:: U+02209 .. NOT AN ELEMENT OF
.. |notinvb| unicode:: U+022F7 .. SMALL ELEMENT OF WITH OVERBAR
.. |notinvc| unicode:: U+022F6 .. ELEMENT OF WITH OVERBAR
.. |notni| unicode:: U+0220C .. DOES NOT CONTAIN AS MEMBER
.. |notniva| unicode:: U+0220C .. DOES NOT CONTAIN AS MEMBER
.. |notnivb| unicode:: U+022FE .. SMALL CONTAINS WITH OVERBAR
.. |notnivc| unicode:: U+022FD .. CONTAINS WITH OVERBAR
.. |nparsl| unicode:: U+02AFD U+020E5 .. DOUBLE SOLIDUS OPERATOR with reverse slash
.. |npart| unicode:: U+02202 U+00338 .. PARTIAL DIFFERENTIAL with slash
.. |npolint| unicode:: U+02A14 .. LINE INTEGRATION NOT INCLUDING THE POLE
.. |nvinfin| unicode:: U+029DE .. INFINITY NEGATED WITH VERTICAL BAR
.. |olcross| unicode:: U+029BB .. CIRCLE WITH SUPERIMPOSED X
.. |Or| unicode:: U+02A54 .. DOUBLE LOGICAL OR
.. |or| unicode:: U+02228 .. LOGICAL OR
.. |ord| unicode:: U+02A5D .. LOGICAL OR WITH HORIZONTAL DASH
.. |order| unicode:: U+02134 .. SCRIPT SMALL O
.. |oror| unicode:: U+02A56 .. TWO INTERSECTING LOGICAL OR
.. |orslope| unicode:: U+02A57 .. SLOPING LARGE OR
.. |orv| unicode:: U+02A5B .. LOGICAL OR WITH MIDDLE STEM
.. |par| unicode:: U+02225 .. PARALLEL TO
.. |parsl| unicode:: U+02AFD .. DOUBLE SOLIDUS OPERATOR
.. |part| unicode:: U+02202 .. PARTIAL DIFFERENTIAL
.. |permil| unicode:: U+02030 .. PER MILLE SIGN
.. |perp| unicode:: U+022A5 .. UP TACK
.. |pertenk| unicode:: U+02031 .. PER TEN THOUSAND SIGN
.. |phmmat| unicode:: U+02133 .. SCRIPT CAPITAL M
.. |pointint| unicode:: U+02A15 .. INTEGRAL AROUND A POINT OPERATOR
.. |Prime| unicode:: U+02033 .. DOUBLE PRIME
.. |prime| unicode:: U+02032 .. PRIME
.. |profalar| unicode:: U+0232E .. ALL AROUND-PROFILE
.. |profline| unicode:: U+02312 .. ARC
.. |profsurf| unicode:: U+02313 .. SEGMENT
.. |prop| unicode:: U+0221D .. PROPORTIONAL TO
.. |qint| unicode:: U+02A0C .. QUADRUPLE INTEGRAL OPERATOR
.. |qprime| unicode:: U+02057 .. QUADRUPLE PRIME
.. |quatint| unicode:: U+02A16 .. QUATERNION INTEGRAL OPERATOR
.. |radic| unicode:: U+0221A .. SQUARE ROOT
.. |Rang| unicode:: U+0300B .. RIGHT DOUBLE ANGLE BRACKET
.. |rang| unicode:: U+0232A .. RIGHT-POINTING ANGLE BRACKET
.. |rArr| unicode:: U+021D2 .. RIGHTWARDS DOUBLE ARROW
.. |rbbrk| unicode:: U+03015 .. RIGHT TORTOISE SHELL BRACKET
.. |roang| unicode:: U+03019 .. RIGHT WHITE TORTOISE SHELL BRACKET
.. |robrk| unicode:: U+0301B .. RIGHT WHITE SQUARE BRACKET
.. |ropar| unicode:: U+02986 .. RIGHT WHITE PARENTHESIS
.. |rppolint| unicode:: U+02A12 .. LINE INTEGRATION WITH RECTANGULAR PATH AROUND POLE
.. |scpolint| unicode:: U+02A13 .. LINE INTEGRATION WITH SEMICIRCULAR PATH AROUND POLE
.. |sim| unicode:: U+0223C .. TILDE OPERATOR
.. |simdot| unicode:: U+02A6A .. TILDE OPERATOR WITH DOT ABOVE
.. |sime| unicode:: U+02243 .. ASYMPTOTICALLY EQUAL TO
.. |smeparsl| unicode:: U+029E4 .. EQUALS SIGN AND SLANTED PARALLEL WITH TILDE ABOVE
.. |square| unicode:: U+025A1 .. WHITE SQUARE
.. |squarf| unicode:: U+025AA .. BLACK SMALL SQUARE
.. |strns| unicode:: U+000AF .. MACRON
.. |sub| unicode:: U+02282 .. SUBSET OF
.. |sube| unicode:: U+02286 .. SUBSET OF OR EQUAL TO
.. |sup| unicode:: U+02283 .. SUPERSET OF
.. |supe| unicode:: U+02287 .. SUPERSET OF OR EQUAL TO
.. |tdot| unicode:: U+020DB .. COMBINING THREE DOTS ABOVE
.. |there4| unicode:: U+02234 .. THEREFORE
.. |tint| unicode:: U+0222D .. TRIPLE INTEGRAL
.. |top| unicode:: U+022A4 .. DOWN TACK
.. |topbot| unicode:: U+02336 .. APL FUNCTIONAL SYMBOL I-BEAM
.. |topcir| unicode:: U+02AF1 .. DOWN TACK WITH CIRCLE BELOW
.. |tprime| unicode:: U+02034 .. TRIPLE PRIME
.. |utdot| unicode:: U+022F0 .. UP RIGHT DIAGONAL ELLIPSIS
.. |uwangle| unicode:: U+029A7 .. OBLIQUE ANGLE OPENING DOWN
.. |vangrt| unicode:: U+0299C .. RIGHT ANGLE VARIANT WITH SQUARE
.. |veeeq| unicode:: U+0225A .. EQUIANGULAR TO
.. |Verbar| unicode:: U+02016 .. DOUBLE VERTICAL LINE
.. |wedgeq| unicode:: U+02259 .. ESTIMATES
.. |xnis| unicode:: U+022FB .. CONTAINS WITH VERTICAL BAR AT END OF HORIZONTAL STROKE
@@ -0,0 +1,554 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |angle| unicode:: U+02220 .. ANGLE
.. |ApplyFunction| unicode:: U+02061 .. FUNCTION APPLICATION
.. |approx| unicode:: U+02248 .. ALMOST EQUAL TO
.. |approxeq| unicode:: U+0224A .. ALMOST EQUAL OR EQUAL TO
.. |Assign| unicode:: U+02254 .. COLON EQUALS
.. |backcong| unicode:: U+0224C .. ALL EQUAL TO
.. |backepsilon| unicode:: U+003F6 .. GREEK REVERSED LUNATE EPSILON SYMBOL
.. |backprime| unicode:: U+02035 .. REVERSED PRIME
.. |backsim| unicode:: U+0223D .. REVERSED TILDE
.. |backsimeq| unicode:: U+022CD .. REVERSED TILDE EQUALS
.. |Backslash| unicode:: U+02216 .. SET MINUS
.. |barwedge| unicode:: U+02305 .. PROJECTIVE
.. |Because| unicode:: U+02235 .. BECAUSE
.. |because| unicode:: U+02235 .. BECAUSE
.. |Bernoullis| unicode:: U+0212C .. SCRIPT CAPITAL B
.. |between| unicode:: U+0226C .. BETWEEN
.. |bigcap| unicode:: U+022C2 .. N-ARY INTERSECTION
.. |bigcirc| unicode:: U+025EF .. LARGE CIRCLE
.. |bigcup| unicode:: U+022C3 .. N-ARY UNION
.. |bigodot| unicode:: U+02A00 .. N-ARY CIRCLED DOT OPERATOR
.. |bigoplus| unicode:: U+02A01 .. N-ARY CIRCLED PLUS OPERATOR
.. |bigotimes| unicode:: U+02A02 .. N-ARY CIRCLED TIMES OPERATOR
.. |bigsqcup| unicode:: U+02A06 .. N-ARY SQUARE UNION OPERATOR
.. |bigstar| unicode:: U+02605 .. BLACK STAR
.. |bigtriangledown| unicode:: U+025BD .. WHITE DOWN-POINTING TRIANGLE
.. |bigtriangleup| unicode:: U+025B3 .. WHITE UP-POINTING TRIANGLE
.. |biguplus| unicode:: U+02A04 .. N-ARY UNION OPERATOR WITH PLUS
.. |bigvee| unicode:: U+022C1 .. N-ARY LOGICAL OR
.. |bigwedge| unicode:: U+022C0 .. N-ARY LOGICAL AND
.. |bkarow| unicode:: U+0290D .. RIGHTWARDS DOUBLE DASH ARROW
.. |blacklozenge| unicode:: U+029EB .. BLACK LOZENGE
.. |blacksquare| unicode:: U+025AA .. BLACK SMALL SQUARE
.. |blacktriangle| unicode:: U+025B4 .. BLACK UP-POINTING SMALL TRIANGLE
.. |blacktriangledown| unicode:: U+025BE .. BLACK DOWN-POINTING SMALL TRIANGLE
.. |blacktriangleleft| unicode:: U+025C2 .. BLACK LEFT-POINTING SMALL TRIANGLE
.. |blacktriangleright| unicode:: U+025B8 .. BLACK RIGHT-POINTING SMALL TRIANGLE
.. |bot| unicode:: U+022A5 .. UP TACK
.. |boxminus| unicode:: U+0229F .. SQUARED MINUS
.. |boxplus| unicode:: U+0229E .. SQUARED PLUS
.. |boxtimes| unicode:: U+022A0 .. SQUARED TIMES
.. |Breve| unicode:: U+002D8 .. BREVE
.. |bullet| unicode:: U+02022 .. BULLET
.. |Bumpeq| unicode:: U+0224E .. GEOMETRICALLY EQUIVALENT TO
.. |bumpeq| unicode:: U+0224F .. DIFFERENCE BETWEEN
.. |CapitalDifferentialD| unicode:: U+02145 .. DOUBLE-STRUCK ITALIC CAPITAL D
.. |Cayleys| unicode:: U+0212D .. BLACK-LETTER CAPITAL C
.. |Cedilla| unicode:: U+000B8 .. CEDILLA
.. |CenterDot| unicode:: U+000B7 .. MIDDLE DOT
.. |centerdot| unicode:: U+000B7 .. MIDDLE DOT
.. |checkmark| unicode:: U+02713 .. CHECK MARK
.. |circeq| unicode:: U+02257 .. RING EQUAL TO
.. |circlearrowleft| unicode:: U+021BA .. ANTICLOCKWISE OPEN CIRCLE ARROW
.. |circlearrowright| unicode:: U+021BB .. CLOCKWISE OPEN CIRCLE ARROW
.. |circledast| unicode:: U+0229B .. CIRCLED ASTERISK OPERATOR
.. |circledcirc| unicode:: U+0229A .. CIRCLED RING OPERATOR
.. |circleddash| unicode:: U+0229D .. CIRCLED DASH
.. |CircleDot| unicode:: U+02299 .. CIRCLED DOT OPERATOR
.. |circledR| unicode:: U+000AE .. REGISTERED SIGN
.. |circledS| unicode:: U+024C8 .. CIRCLED LATIN CAPITAL LETTER S
.. |CircleMinus| unicode:: U+02296 .. CIRCLED MINUS
.. |CirclePlus| unicode:: U+02295 .. CIRCLED PLUS
.. |CircleTimes| unicode:: U+02297 .. CIRCLED TIMES
.. |ClockwiseContourIntegral| unicode:: U+02232 .. CLOCKWISE CONTOUR INTEGRAL
.. |CloseCurlyDoubleQuote| unicode:: U+0201D .. RIGHT DOUBLE QUOTATION MARK
.. |CloseCurlyQuote| unicode:: U+02019 .. RIGHT SINGLE QUOTATION MARK
.. |clubsuit| unicode:: U+02663 .. BLACK CLUB SUIT
.. |coloneq| unicode:: U+02254 .. COLON EQUALS
.. |complement| unicode:: U+02201 .. COMPLEMENT
.. |complexes| unicode:: U+02102 .. DOUBLE-STRUCK CAPITAL C
.. |Congruent| unicode:: U+02261 .. IDENTICAL TO
.. |ContourIntegral| unicode:: U+0222E .. CONTOUR INTEGRAL
.. |Coproduct| unicode:: U+02210 .. N-ARY COPRODUCT
.. |CounterClockwiseContourIntegral| unicode:: U+02233 .. ANTICLOCKWISE CONTOUR INTEGRAL
.. |CupCap| unicode:: U+0224D .. EQUIVALENT TO
.. |curlyeqprec| unicode:: U+022DE .. EQUAL TO OR PRECEDES
.. |curlyeqsucc| unicode:: U+022DF .. EQUAL TO OR SUCCEEDS
.. |curlyvee| unicode:: U+022CE .. CURLY LOGICAL OR
.. |curlywedge| unicode:: U+022CF .. CURLY LOGICAL AND
.. |curvearrowleft| unicode:: U+021B6 .. ANTICLOCKWISE TOP SEMICIRCLE ARROW
.. |curvearrowright| unicode:: U+021B7 .. CLOCKWISE TOP SEMICIRCLE ARROW
.. |dbkarow| unicode:: U+0290F .. RIGHTWARDS TRIPLE DASH ARROW
.. |ddagger| unicode:: U+02021 .. DOUBLE DAGGER
.. |ddotseq| unicode:: U+02A77 .. EQUALS SIGN WITH TWO DOTS ABOVE AND TWO DOTS BELOW
.. |Del| unicode:: U+02207 .. NABLA
.. |DiacriticalAcute| unicode:: U+000B4 .. ACUTE ACCENT
.. |DiacriticalDot| unicode:: U+002D9 .. DOT ABOVE
.. |DiacriticalDoubleAcute| unicode:: U+002DD .. DOUBLE ACUTE ACCENT
.. |DiacriticalGrave| unicode:: U+00060 .. GRAVE ACCENT
.. |DiacriticalTilde| unicode:: U+002DC .. SMALL TILDE
.. |Diamond| unicode:: U+022C4 .. DIAMOND OPERATOR
.. |diamond| unicode:: U+022C4 .. DIAMOND OPERATOR
.. |diamondsuit| unicode:: U+02666 .. BLACK DIAMOND SUIT
.. |DifferentialD| unicode:: U+02146 .. DOUBLE-STRUCK ITALIC SMALL D
.. |digamma| unicode:: U+003DD .. GREEK SMALL LETTER DIGAMMA
.. |div| unicode:: U+000F7 .. DIVISION SIGN
.. |divideontimes| unicode:: U+022C7 .. DIVISION TIMES
.. |doteq| unicode:: U+02250 .. APPROACHES THE LIMIT
.. |doteqdot| unicode:: U+02251 .. GEOMETRICALLY EQUAL TO
.. |DotEqual| unicode:: U+02250 .. APPROACHES THE LIMIT
.. |dotminus| unicode:: U+02238 .. DOT MINUS
.. |dotplus| unicode:: U+02214 .. DOT PLUS
.. |dotsquare| unicode:: U+022A1 .. SQUARED DOT OPERATOR
.. |doublebarwedge| unicode:: U+02306 .. PERSPECTIVE
.. |DoubleContourIntegral| unicode:: U+0222F .. SURFACE INTEGRAL
.. |DoubleDot| unicode:: U+000A8 .. DIAERESIS
.. |DoubleDownArrow| unicode:: U+021D3 .. DOWNWARDS DOUBLE ARROW
.. |DoubleLeftArrow| unicode:: U+021D0 .. LEFTWARDS DOUBLE ARROW
.. |DoubleLeftRightArrow| unicode:: U+021D4 .. LEFT RIGHT DOUBLE ARROW
.. |DoubleLeftTee| unicode:: U+02AE4 .. VERTICAL BAR DOUBLE LEFT TURNSTILE
.. |DoubleLongLeftArrow| unicode:: U+027F8 .. LONG LEFTWARDS DOUBLE ARROW
.. |DoubleLongLeftRightArrow| unicode:: U+027FA .. LONG LEFT RIGHT DOUBLE ARROW
.. |DoubleLongRightArrow| unicode:: U+027F9 .. LONG RIGHTWARDS DOUBLE ARROW
.. |DoubleRightArrow| unicode:: U+021D2 .. RIGHTWARDS DOUBLE ARROW
.. |DoubleRightTee| unicode:: U+022A8 .. TRUE
.. |DoubleUpArrow| unicode:: U+021D1 .. UPWARDS DOUBLE ARROW
.. |DoubleUpDownArrow| unicode:: U+021D5 .. UP DOWN DOUBLE ARROW
.. |DoubleVerticalBar| unicode:: U+02225 .. PARALLEL TO
.. |DownArrow| unicode:: U+02193 .. DOWNWARDS ARROW
.. |Downarrow| unicode:: U+021D3 .. DOWNWARDS DOUBLE ARROW
.. |downarrow| unicode:: U+02193 .. DOWNWARDS ARROW
.. |DownArrowUpArrow| unicode:: U+021F5 .. DOWNWARDS ARROW LEFTWARDS OF UPWARDS ARROW
.. |downdownarrows| unicode:: U+021CA .. DOWNWARDS PAIRED ARROWS
.. |downharpoonleft| unicode:: U+021C3 .. DOWNWARDS HARPOON WITH BARB LEFTWARDS
.. |downharpoonright| unicode:: U+021C2 .. DOWNWARDS HARPOON WITH BARB RIGHTWARDS
.. |DownLeftVector| unicode:: U+021BD .. LEFTWARDS HARPOON WITH BARB DOWNWARDS
.. |DownRightVector| unicode:: U+021C1 .. RIGHTWARDS HARPOON WITH BARB DOWNWARDS
.. |DownTee| unicode:: U+022A4 .. DOWN TACK
.. |DownTeeArrow| unicode:: U+021A7 .. DOWNWARDS ARROW FROM BAR
.. |drbkarow| unicode:: U+02910 .. RIGHTWARDS TWO-HEADED TRIPLE DASH ARROW
.. |Element| unicode:: U+02208 .. ELEMENT OF
.. |emptyset| unicode:: U+02205 .. EMPTY SET
.. |eqcirc| unicode:: U+02256 .. RING IN EQUAL TO
.. |eqcolon| unicode:: U+02255 .. EQUALS COLON
.. |eqsim| unicode:: U+02242 .. MINUS TILDE
.. |eqslantgtr| unicode:: U+02A96 .. SLANTED EQUAL TO OR GREATER-THAN
.. |eqslantless| unicode:: U+02A95 .. SLANTED EQUAL TO OR LESS-THAN
.. |EqualTilde| unicode:: U+02242 .. MINUS TILDE
.. |Equilibrium| unicode:: U+021CC .. RIGHTWARDS HARPOON OVER LEFTWARDS HARPOON
.. |Exists| unicode:: U+02203 .. THERE EXISTS
.. |expectation| unicode:: U+02130 .. SCRIPT CAPITAL E
.. |ExponentialE| unicode:: U+02147 .. DOUBLE-STRUCK ITALIC SMALL E
.. |exponentiale| unicode:: U+02147 .. DOUBLE-STRUCK ITALIC SMALL E
.. |fallingdotseq| unicode:: U+02252 .. APPROXIMATELY EQUAL TO OR THE IMAGE OF
.. |ForAll| unicode:: U+02200 .. FOR ALL
.. |Fouriertrf| unicode:: U+02131 .. SCRIPT CAPITAL F
.. |geq| unicode:: U+02265 .. GREATER-THAN OR EQUAL TO
.. |geqq| unicode:: U+02267 .. GREATER-THAN OVER EQUAL TO
.. |geqslant| unicode:: U+02A7E .. GREATER-THAN OR SLANTED EQUAL TO
.. |gg| unicode:: U+0226B .. MUCH GREATER-THAN
.. |ggg| unicode:: U+022D9 .. VERY MUCH GREATER-THAN
.. |gnapprox| unicode:: U+02A8A .. GREATER-THAN AND NOT APPROXIMATE
.. |gneq| unicode:: U+02A88 .. GREATER-THAN AND SINGLE-LINE NOT EQUAL TO
.. |gneqq| unicode:: U+02269 .. GREATER-THAN BUT NOT EQUAL TO
.. |GreaterEqual| unicode:: U+02265 .. GREATER-THAN OR EQUAL TO
.. |GreaterEqualLess| unicode:: U+022DB .. GREATER-THAN EQUAL TO OR LESS-THAN
.. |GreaterFullEqual| unicode:: U+02267 .. GREATER-THAN OVER EQUAL TO
.. |GreaterLess| unicode:: U+02277 .. GREATER-THAN OR LESS-THAN
.. |GreaterSlantEqual| unicode:: U+02A7E .. GREATER-THAN OR SLANTED EQUAL TO
.. |GreaterTilde| unicode:: U+02273 .. GREATER-THAN OR EQUIVALENT TO
.. |gtrapprox| unicode:: U+02A86 .. GREATER-THAN OR APPROXIMATE
.. |gtrdot| unicode:: U+022D7 .. GREATER-THAN WITH DOT
.. |gtreqless| unicode:: U+022DB .. GREATER-THAN EQUAL TO OR LESS-THAN
.. |gtreqqless| unicode:: U+02A8C .. GREATER-THAN ABOVE DOUBLE-LINE EQUAL ABOVE LESS-THAN
.. |gtrless| unicode:: U+02277 .. GREATER-THAN OR LESS-THAN
.. |gtrsim| unicode:: U+02273 .. GREATER-THAN OR EQUIVALENT TO
.. |gvertneqq| unicode:: U+02269 U+0FE00 .. GREATER-THAN BUT NOT EQUAL TO - with vertical stroke
.. |Hacek| unicode:: U+002C7 .. CARON
.. |hbar| unicode:: U+0210F .. PLANCK CONSTANT OVER TWO PI
.. |heartsuit| unicode:: U+02665 .. BLACK HEART SUIT
.. |HilbertSpace| unicode:: U+0210B .. SCRIPT CAPITAL H
.. |hksearow| unicode:: U+02925 .. SOUTH EAST ARROW WITH HOOK
.. |hkswarow| unicode:: U+02926 .. SOUTH WEST ARROW WITH HOOK
.. |hookleftarrow| unicode:: U+021A9 .. LEFTWARDS ARROW WITH HOOK
.. |hookrightarrow| unicode:: U+021AA .. RIGHTWARDS ARROW WITH HOOK
.. |hslash| unicode:: U+0210F .. PLANCK CONSTANT OVER TWO PI
.. |HumpDownHump| unicode:: U+0224E .. GEOMETRICALLY EQUIVALENT TO
.. |HumpEqual| unicode:: U+0224F .. DIFFERENCE BETWEEN
.. |iiiint| unicode:: U+02A0C .. QUADRUPLE INTEGRAL OPERATOR
.. |iiint| unicode:: U+0222D .. TRIPLE INTEGRAL
.. |Im| unicode:: U+02111 .. BLACK-LETTER CAPITAL I
.. |ImaginaryI| unicode:: U+02148 .. DOUBLE-STRUCK ITALIC SMALL I
.. |imagline| unicode:: U+02110 .. SCRIPT CAPITAL I
.. |imagpart| unicode:: U+02111 .. BLACK-LETTER CAPITAL I
.. |Implies| unicode:: U+021D2 .. RIGHTWARDS DOUBLE ARROW
.. |in| unicode:: U+02208 .. ELEMENT OF
.. |integers| unicode:: U+02124 .. DOUBLE-STRUCK CAPITAL Z
.. |Integral| unicode:: U+0222B .. INTEGRAL
.. |intercal| unicode:: U+022BA .. INTERCALATE
.. |Intersection| unicode:: U+022C2 .. N-ARY INTERSECTION
.. |intprod| unicode:: U+02A3C .. INTERIOR PRODUCT
.. |InvisibleComma| unicode:: U+02063 .. INVISIBLE SEPARATOR
.. |InvisibleTimes| unicode:: U+02062 .. INVISIBLE TIMES
.. |langle| unicode:: U+02329 .. LEFT-POINTING ANGLE BRACKET
.. |Laplacetrf| unicode:: U+02112 .. SCRIPT CAPITAL L
.. |lbrace| unicode:: U+0007B .. LEFT CURLY BRACKET
.. |lbrack| unicode:: U+0005B .. LEFT SQUARE BRACKET
.. |LeftAngleBracket| unicode:: U+02329 .. LEFT-POINTING ANGLE BRACKET
.. |LeftArrow| unicode:: U+02190 .. LEFTWARDS ARROW
.. |Leftarrow| unicode:: U+021D0 .. LEFTWARDS DOUBLE ARROW
.. |leftarrow| unicode:: U+02190 .. LEFTWARDS ARROW
.. |LeftArrowBar| unicode:: U+021E4 .. LEFTWARDS ARROW TO BAR
.. |LeftArrowRightArrow| unicode:: U+021C6 .. LEFTWARDS ARROW OVER RIGHTWARDS ARROW
.. |leftarrowtail| unicode:: U+021A2 .. LEFTWARDS ARROW WITH TAIL
.. |LeftCeiling| unicode:: U+02308 .. LEFT CEILING
.. |LeftDoubleBracket| unicode:: U+0301A .. LEFT WHITE SQUARE BRACKET
.. |LeftDownVector| unicode:: U+021C3 .. DOWNWARDS HARPOON WITH BARB LEFTWARDS
.. |LeftFloor| unicode:: U+0230A .. LEFT FLOOR
.. |leftharpoondown| unicode:: U+021BD .. LEFTWARDS HARPOON WITH BARB DOWNWARDS
.. |leftharpoonup| unicode:: U+021BC .. LEFTWARDS HARPOON WITH BARB UPWARDS
.. |leftleftarrows| unicode:: U+021C7 .. LEFTWARDS PAIRED ARROWS
.. |LeftRightArrow| unicode:: U+02194 .. LEFT RIGHT ARROW
.. |Leftrightarrow| unicode:: U+021D4 .. LEFT RIGHT DOUBLE ARROW
.. |leftrightarrow| unicode:: U+02194 .. LEFT RIGHT ARROW
.. |leftrightarrows| unicode:: U+021C6 .. LEFTWARDS ARROW OVER RIGHTWARDS ARROW
.. |leftrightharpoons| unicode:: U+021CB .. LEFTWARDS HARPOON OVER RIGHTWARDS HARPOON
.. |leftrightsquigarrow| unicode:: U+021AD .. LEFT RIGHT WAVE ARROW
.. |LeftTee| unicode:: U+022A3 .. LEFT TACK
.. |LeftTeeArrow| unicode:: U+021A4 .. LEFTWARDS ARROW FROM BAR
.. |leftthreetimes| unicode:: U+022CB .. LEFT SEMIDIRECT PRODUCT
.. |LeftTriangle| unicode:: U+022B2 .. NORMAL SUBGROUP OF
.. |LeftTriangleEqual| unicode:: U+022B4 .. NORMAL SUBGROUP OF OR EQUAL TO
.. |LeftUpVector| unicode:: U+021BF .. UPWARDS HARPOON WITH BARB LEFTWARDS
.. |LeftVector| unicode:: U+021BC .. LEFTWARDS HARPOON WITH BARB UPWARDS
.. |leq| unicode:: U+02264 .. LESS-THAN OR EQUAL TO
.. |leqq| unicode:: U+02266 .. LESS-THAN OVER EQUAL TO
.. |leqslant| unicode:: U+02A7D .. LESS-THAN OR SLANTED EQUAL TO
.. |lessapprox| unicode:: U+02A85 .. LESS-THAN OR APPROXIMATE
.. |lessdot| unicode:: U+022D6 .. LESS-THAN WITH DOT
.. |lesseqgtr| unicode:: U+022DA .. LESS-THAN EQUAL TO OR GREATER-THAN
.. |lesseqqgtr| unicode:: U+02A8B .. LESS-THAN ABOVE DOUBLE-LINE EQUAL ABOVE GREATER-THAN
.. |LessEqualGreater| unicode:: U+022DA .. LESS-THAN EQUAL TO OR GREATER-THAN
.. |LessFullEqual| unicode:: U+02266 .. LESS-THAN OVER EQUAL TO
.. |LessGreater| unicode:: U+02276 .. LESS-THAN OR GREATER-THAN
.. |lessgtr| unicode:: U+02276 .. LESS-THAN OR GREATER-THAN
.. |lesssim| unicode:: U+02272 .. LESS-THAN OR EQUIVALENT TO
.. |LessSlantEqual| unicode:: U+02A7D .. LESS-THAN OR SLANTED EQUAL TO
.. |LessTilde| unicode:: U+02272 .. LESS-THAN OR EQUIVALENT TO
.. |ll| unicode:: U+0226A .. MUCH LESS-THAN
.. |llcorner| unicode:: U+0231E .. BOTTOM LEFT CORNER
.. |Lleftarrow| unicode:: U+021DA .. LEFTWARDS TRIPLE ARROW
.. |lmoustache| unicode:: U+023B0 .. UPPER LEFT OR LOWER RIGHT CURLY BRACKET SECTION
.. |lnapprox| unicode:: U+02A89 .. LESS-THAN AND NOT APPROXIMATE
.. |lneq| unicode:: U+02A87 .. LESS-THAN AND SINGLE-LINE NOT EQUAL TO
.. |lneqq| unicode:: U+02268 .. LESS-THAN BUT NOT EQUAL TO
.. |LongLeftArrow| unicode:: U+027F5 .. LONG LEFTWARDS ARROW
.. |Longleftarrow| unicode:: U+027F8 .. LONG LEFTWARDS DOUBLE ARROW
.. |longleftarrow| unicode:: U+027F5 .. LONG LEFTWARDS ARROW
.. |LongLeftRightArrow| unicode:: U+027F7 .. LONG LEFT RIGHT ARROW
.. |Longleftrightarrow| unicode:: U+027FA .. LONG LEFT RIGHT DOUBLE ARROW
.. |longleftrightarrow| unicode:: U+027F7 .. LONG LEFT RIGHT ARROW
.. |longmapsto| unicode:: U+027FC .. LONG RIGHTWARDS ARROW FROM BAR
.. |LongRightArrow| unicode:: U+027F6 .. LONG RIGHTWARDS ARROW
.. |Longrightarrow| unicode:: U+027F9 .. LONG RIGHTWARDS DOUBLE ARROW
.. |longrightarrow| unicode:: U+027F6 .. LONG RIGHTWARDS ARROW
.. |looparrowleft| unicode:: U+021AB .. LEFTWARDS ARROW WITH LOOP
.. |looparrowright| unicode:: U+021AC .. RIGHTWARDS ARROW WITH LOOP
.. |LowerLeftArrow| unicode:: U+02199 .. SOUTH WEST ARROW
.. |LowerRightArrow| unicode:: U+02198 .. SOUTH EAST ARROW
.. |lozenge| unicode:: U+025CA .. LOZENGE
.. |lrcorner| unicode:: U+0231F .. BOTTOM RIGHT CORNER
.. |Lsh| unicode:: U+021B0 .. UPWARDS ARROW WITH TIP LEFTWARDS
.. |lvertneqq| unicode:: U+02268 U+0FE00 .. LESS-THAN BUT NOT EQUAL TO - with vertical stroke
.. |maltese| unicode:: U+02720 .. MALTESE CROSS
.. |mapsto| unicode:: U+021A6 .. RIGHTWARDS ARROW FROM BAR
.. |measuredangle| unicode:: U+02221 .. MEASURED ANGLE
.. |Mellintrf| unicode:: U+02133 .. SCRIPT CAPITAL M
.. |MinusPlus| unicode:: U+02213 .. MINUS-OR-PLUS SIGN
.. |mp| unicode:: U+02213 .. MINUS-OR-PLUS SIGN
.. |multimap| unicode:: U+022B8 .. MULTIMAP
.. |napprox| unicode:: U+02249 .. NOT ALMOST EQUAL TO
.. |natural| unicode:: U+0266E .. MUSIC NATURAL SIGN
.. |naturals| unicode:: U+02115 .. DOUBLE-STRUCK CAPITAL N
.. |nearrow| unicode:: U+02197 .. NORTH EAST ARROW
.. |NegativeMediumSpace| unicode:: U+0200B .. ZERO WIDTH SPACE
.. |NegativeThickSpace| unicode:: U+0200B .. ZERO WIDTH SPACE
.. |NegativeThinSpace| unicode:: U+0200B .. ZERO WIDTH SPACE
.. |NegativeVeryThinSpace| unicode:: U+0200B .. ZERO WIDTH SPACE
.. |NestedGreaterGreater| unicode:: U+0226B .. MUCH GREATER-THAN
.. |NestedLessLess| unicode:: U+0226A .. MUCH LESS-THAN
.. |nexists| unicode:: U+02204 .. THERE DOES NOT EXIST
.. |ngeq| unicode:: U+02271 .. NEITHER GREATER-THAN NOR EQUAL TO
.. |ngeqq| unicode:: U+02267 U+00338 .. GREATER-THAN OVER EQUAL TO with slash
.. |ngeqslant| unicode:: U+02A7E U+00338 .. GREATER-THAN OR SLANTED EQUAL TO with slash
.. |ngtr| unicode:: U+0226F .. NOT GREATER-THAN
.. |nLeftarrow| unicode:: U+021CD .. LEFTWARDS DOUBLE ARROW WITH STROKE
.. |nleftarrow| unicode:: U+0219A .. LEFTWARDS ARROW WITH STROKE
.. |nLeftrightarrow| unicode:: U+021CE .. LEFT RIGHT DOUBLE ARROW WITH STROKE
.. |nleftrightarrow| unicode:: U+021AE .. LEFT RIGHT ARROW WITH STROKE
.. |nleq| unicode:: U+02270 .. NEITHER LESS-THAN NOR EQUAL TO
.. |nleqq| unicode:: U+02266 U+00338 .. LESS-THAN OVER EQUAL TO with slash
.. |nleqslant| unicode:: U+02A7D U+00338 .. LESS-THAN OR SLANTED EQUAL TO with slash
.. |nless| unicode:: U+0226E .. NOT LESS-THAN
.. |NonBreakingSpace| unicode:: U+000A0 .. NO-BREAK SPACE
.. |NotCongruent| unicode:: U+02262 .. NOT IDENTICAL TO
.. |NotDoubleVerticalBar| unicode:: U+02226 .. NOT PARALLEL TO
.. |NotElement| unicode:: U+02209 .. NOT AN ELEMENT OF
.. |NotEqual| unicode:: U+02260 .. NOT EQUAL TO
.. |NotEqualTilde| unicode:: U+02242 U+00338 .. MINUS TILDE with slash
.. |NotExists| unicode:: U+02204 .. THERE DOES NOT EXIST
.. |NotGreater| unicode:: U+0226F .. NOT GREATER-THAN
.. |NotGreaterEqual| unicode:: U+02271 .. NEITHER GREATER-THAN NOR EQUAL TO
.. |NotGreaterFullEqual| unicode:: U+02266 U+00338 .. LESS-THAN OVER EQUAL TO with slash
.. |NotGreaterGreater| unicode:: U+0226B U+00338 .. MUCH GREATER THAN with slash
.. |NotGreaterLess| unicode:: U+02279 .. NEITHER GREATER-THAN NOR LESS-THAN
.. |NotGreaterSlantEqual| unicode:: U+02A7E U+00338 .. GREATER-THAN OR SLANTED EQUAL TO with slash
.. |NotGreaterTilde| unicode:: U+02275 .. NEITHER GREATER-THAN NOR EQUIVALENT TO
.. |NotHumpDownHump| unicode:: U+0224E U+00338 .. GEOMETRICALLY EQUIVALENT TO with slash
.. |NotLeftTriangle| unicode:: U+022EA .. NOT NORMAL SUBGROUP OF
.. |NotLeftTriangleEqual| unicode:: U+022EC .. NOT NORMAL SUBGROUP OF OR EQUAL TO
.. |NotLess| unicode:: U+0226E .. NOT LESS-THAN
.. |NotLessEqual| unicode:: U+02270 .. NEITHER LESS-THAN NOR EQUAL TO
.. |NotLessGreater| unicode:: U+02278 .. NEITHER LESS-THAN NOR GREATER-THAN
.. |NotLessLess| unicode:: U+0226A U+00338 .. MUCH LESS THAN with slash
.. |NotLessSlantEqual| unicode:: U+02A7D U+00338 .. LESS-THAN OR SLANTED EQUAL TO with slash
.. |NotLessTilde| unicode:: U+02274 .. NEITHER LESS-THAN NOR EQUIVALENT TO
.. |NotPrecedes| unicode:: U+02280 .. DOES NOT PRECEDE
.. |NotPrecedesEqual| unicode:: U+02AAF U+00338 .. PRECEDES ABOVE SINGLE-LINE EQUALS SIGN with slash
.. |NotPrecedesSlantEqual| unicode:: U+022E0 .. DOES NOT PRECEDE OR EQUAL
.. |NotReverseElement| unicode:: U+0220C .. DOES NOT CONTAIN AS MEMBER
.. |NotRightTriangle| unicode:: U+022EB .. DOES NOT CONTAIN AS NORMAL SUBGROUP
.. |NotRightTriangleEqual| unicode:: U+022ED .. DOES NOT CONTAIN AS NORMAL SUBGROUP OR EQUAL
.. |NotSquareSubsetEqual| unicode:: U+022E2 .. NOT SQUARE IMAGE OF OR EQUAL TO
.. |NotSquareSupersetEqual| unicode:: U+022E3 .. NOT SQUARE ORIGINAL OF OR EQUAL TO
.. |NotSubset| unicode:: U+02282 U+020D2 .. SUBSET OF with vertical line
.. |NotSubsetEqual| unicode:: U+02288 .. NEITHER A SUBSET OF NOR EQUAL TO
.. |NotSucceeds| unicode:: U+02281 .. DOES NOT SUCCEED
.. |NotSucceedsEqual| unicode:: U+02AB0 U+00338 .. SUCCEEDS ABOVE SINGLE-LINE EQUALS SIGN with slash
.. |NotSucceedsSlantEqual| unicode:: U+022E1 .. DOES NOT SUCCEED OR EQUAL
.. |NotSuperset| unicode:: U+02283 U+020D2 .. SUPERSET OF with vertical line
.. |NotSupersetEqual| unicode:: U+02289 .. NEITHER A SUPERSET OF NOR EQUAL TO
.. |NotTilde| unicode:: U+02241 .. NOT TILDE
.. |NotTildeEqual| unicode:: U+02244 .. NOT ASYMPTOTICALLY EQUAL TO
.. |NotTildeFullEqual| unicode:: U+02247 .. NEITHER APPROXIMATELY NOR ACTUALLY EQUAL TO
.. |NotTildeTilde| unicode:: U+02249 .. NOT ALMOST EQUAL TO
.. |NotVerticalBar| unicode:: U+02224 .. DOES NOT DIVIDE
.. |nparallel| unicode:: U+02226 .. NOT PARALLEL TO
.. |nprec| unicode:: U+02280 .. DOES NOT PRECEDE
.. |npreceq| unicode:: U+02AAF U+00338 .. PRECEDES ABOVE SINGLE-LINE EQUALS SIGN with slash
.. |nRightarrow| unicode:: U+021CF .. RIGHTWARDS DOUBLE ARROW WITH STROKE
.. |nrightarrow| unicode:: U+0219B .. RIGHTWARDS ARROW WITH STROKE
.. |nshortmid| unicode:: U+02224 .. DOES NOT DIVIDE
.. |nshortparallel| unicode:: U+02226 .. NOT PARALLEL TO
.. |nsimeq| unicode:: U+02244 .. NOT ASYMPTOTICALLY EQUAL TO
.. |nsubset| unicode:: U+02282 U+020D2 .. SUBSET OF with vertical line
.. |nsubseteq| unicode:: U+02288 .. NEITHER A SUBSET OF NOR EQUAL TO
.. |nsubseteqq| unicode:: U+02AC5 U+00338 .. SUBSET OF ABOVE EQUALS SIGN with slash
.. |nsucc| unicode:: U+02281 .. DOES NOT SUCCEED
.. |nsucceq| unicode:: U+02AB0 U+00338 .. SUCCEEDS ABOVE SINGLE-LINE EQUALS SIGN with slash
.. |nsupset| unicode:: U+02283 U+020D2 .. SUPERSET OF with vertical line
.. |nsupseteq| unicode:: U+02289 .. NEITHER A SUPERSET OF NOR EQUAL TO
.. |nsupseteqq| unicode:: U+02AC6 U+00338 .. SUPERSET OF ABOVE EQUALS SIGN with slash
.. |ntriangleleft| unicode:: U+022EA .. NOT NORMAL SUBGROUP OF
.. |ntrianglelefteq| unicode:: U+022EC .. NOT NORMAL SUBGROUP OF OR EQUAL TO
.. |ntriangleright| unicode:: U+022EB .. DOES NOT CONTAIN AS NORMAL SUBGROUP
.. |ntrianglerighteq| unicode:: U+022ED .. DOES NOT CONTAIN AS NORMAL SUBGROUP OR EQUAL
.. |nwarrow| unicode:: U+02196 .. NORTH WEST ARROW
.. |oint| unicode:: U+0222E .. CONTOUR INTEGRAL
.. |OpenCurlyDoubleQuote| unicode:: U+0201C .. LEFT DOUBLE QUOTATION MARK
.. |OpenCurlyQuote| unicode:: U+02018 .. LEFT SINGLE QUOTATION MARK
.. |orderof| unicode:: U+02134 .. SCRIPT SMALL O
.. |parallel| unicode:: U+02225 .. PARALLEL TO
.. |PartialD| unicode:: U+02202 .. PARTIAL DIFFERENTIAL
.. |pitchfork| unicode:: U+022D4 .. PITCHFORK
.. |PlusMinus| unicode:: U+000B1 .. PLUS-MINUS SIGN
.. |pm| unicode:: U+000B1 .. PLUS-MINUS SIGN
.. |Poincareplane| unicode:: U+0210C .. BLACK-LETTER CAPITAL H
.. |prec| unicode:: U+0227A .. PRECEDES
.. |precapprox| unicode:: U+02AB7 .. PRECEDES ABOVE ALMOST EQUAL TO
.. |preccurlyeq| unicode:: U+0227C .. PRECEDES OR EQUAL TO
.. |Precedes| unicode:: U+0227A .. PRECEDES
.. |PrecedesEqual| unicode:: U+02AAF .. PRECEDES ABOVE SINGLE-LINE EQUALS SIGN
.. |PrecedesSlantEqual| unicode:: U+0227C .. PRECEDES OR EQUAL TO
.. |PrecedesTilde| unicode:: U+0227E .. PRECEDES OR EQUIVALENT TO
.. |preceq| unicode:: U+02AAF .. PRECEDES ABOVE SINGLE-LINE EQUALS SIGN
.. |precnapprox| unicode:: U+02AB9 .. PRECEDES ABOVE NOT ALMOST EQUAL TO
.. |precneqq| unicode:: U+02AB5 .. PRECEDES ABOVE NOT EQUAL TO
.. |precnsim| unicode:: U+022E8 .. PRECEDES BUT NOT EQUIVALENT TO
.. |precsim| unicode:: U+0227E .. PRECEDES OR EQUIVALENT TO
.. |primes| unicode:: U+02119 .. DOUBLE-STRUCK CAPITAL P
.. |Proportion| unicode:: U+02237 .. PROPORTION
.. |Proportional| unicode:: U+0221D .. PROPORTIONAL TO
.. |propto| unicode:: U+0221D .. PROPORTIONAL TO
.. |quaternions| unicode:: U+0210D .. DOUBLE-STRUCK CAPITAL H
.. |questeq| unicode:: U+0225F .. QUESTIONED EQUAL TO
.. |rangle| unicode:: U+0232A .. RIGHT-POINTING ANGLE BRACKET
.. |rationals| unicode:: U+0211A .. DOUBLE-STRUCK CAPITAL Q
.. |rbrace| unicode:: U+0007D .. RIGHT CURLY BRACKET
.. |rbrack| unicode:: U+0005D .. RIGHT SQUARE BRACKET
.. |Re| unicode:: U+0211C .. BLACK-LETTER CAPITAL R
.. |realine| unicode:: U+0211B .. SCRIPT CAPITAL R
.. |realpart| unicode:: U+0211C .. BLACK-LETTER CAPITAL R
.. |reals| unicode:: U+0211D .. DOUBLE-STRUCK CAPITAL R
.. |ReverseElement| unicode:: U+0220B .. CONTAINS AS MEMBER
.. |ReverseEquilibrium| unicode:: U+021CB .. LEFTWARDS HARPOON OVER RIGHTWARDS HARPOON
.. |ReverseUpEquilibrium| unicode:: U+0296F .. DOWNWARDS HARPOON WITH BARB LEFT BESIDE UPWARDS HARPOON WITH BARB RIGHT
.. |RightAngleBracket| unicode:: U+0232A .. RIGHT-POINTING ANGLE BRACKET
.. |RightArrow| unicode:: U+02192 .. RIGHTWARDS ARROW
.. |Rightarrow| unicode:: U+021D2 .. RIGHTWARDS DOUBLE ARROW
.. |rightarrow| unicode:: U+02192 .. RIGHTWARDS ARROW
.. |RightArrowBar| unicode:: U+021E5 .. RIGHTWARDS ARROW TO BAR
.. |RightArrowLeftArrow| unicode:: U+021C4 .. RIGHTWARDS ARROW OVER LEFTWARDS ARROW
.. |rightarrowtail| unicode:: U+021A3 .. RIGHTWARDS ARROW WITH TAIL
.. |RightCeiling| unicode:: U+02309 .. RIGHT CEILING
.. |RightDoubleBracket| unicode:: U+0301B .. RIGHT WHITE SQUARE BRACKET
.. |RightDownVector| unicode:: U+021C2 .. DOWNWARDS HARPOON WITH BARB RIGHTWARDS
.. |RightFloor| unicode:: U+0230B .. RIGHT FLOOR
.. |rightharpoondown| unicode:: U+021C1 .. RIGHTWARDS HARPOON WITH BARB DOWNWARDS
.. |rightharpoonup| unicode:: U+021C0 .. RIGHTWARDS HARPOON WITH BARB UPWARDS
.. |rightleftarrows| unicode:: U+021C4 .. RIGHTWARDS ARROW OVER LEFTWARDS ARROW
.. |rightleftharpoons| unicode:: U+021CC .. RIGHTWARDS HARPOON OVER LEFTWARDS HARPOON
.. |rightrightarrows| unicode:: U+021C9 .. RIGHTWARDS PAIRED ARROWS
.. |rightsquigarrow| unicode:: U+0219D .. RIGHTWARDS WAVE ARROW
.. |RightTee| unicode:: U+022A2 .. RIGHT TACK
.. |RightTeeArrow| unicode:: U+021A6 .. RIGHTWARDS ARROW FROM BAR
.. |rightthreetimes| unicode:: U+022CC .. RIGHT SEMIDIRECT PRODUCT
.. |RightTriangle| unicode:: U+022B3 .. CONTAINS AS NORMAL SUBGROUP
.. |RightTriangleEqual| unicode:: U+022B5 .. CONTAINS AS NORMAL SUBGROUP OR EQUAL TO
.. |RightUpVector| unicode:: U+021BE .. UPWARDS HARPOON WITH BARB RIGHTWARDS
.. |RightVector| unicode:: U+021C0 .. RIGHTWARDS HARPOON WITH BARB UPWARDS
.. |risingdotseq| unicode:: U+02253 .. IMAGE OF OR APPROXIMATELY EQUAL TO
.. |rmoustache| unicode:: U+023B1 .. UPPER RIGHT OR LOWER LEFT CURLY BRACKET SECTION
.. |Rrightarrow| unicode:: U+021DB .. RIGHTWARDS TRIPLE ARROW
.. |Rsh| unicode:: U+021B1 .. UPWARDS ARROW WITH TIP RIGHTWARDS
.. |searrow| unicode:: U+02198 .. SOUTH EAST ARROW
.. |setminus| unicode:: U+02216 .. SET MINUS
.. |ShortDownArrow| unicode:: U+02193 .. DOWNWARDS ARROW
.. |ShortLeftArrow| unicode:: U+02190 .. LEFTWARDS ARROW
.. |shortmid| unicode:: U+02223 .. DIVIDES
.. |shortparallel| unicode:: U+02225 .. PARALLEL TO
.. |ShortRightArrow| unicode:: U+02192 .. RIGHTWARDS ARROW
.. |ShortUpArrow| unicode:: U+02191 .. UPWARDS ARROW
.. |simeq| unicode:: U+02243 .. ASYMPTOTICALLY EQUAL TO
.. |SmallCircle| unicode:: U+02218 .. RING OPERATOR
.. |smallsetminus| unicode:: U+02216 .. SET MINUS
.. |spadesuit| unicode:: U+02660 .. BLACK SPADE SUIT
.. |Sqrt| unicode:: U+0221A .. SQUARE ROOT
.. |sqsubset| unicode:: U+0228F .. SQUARE IMAGE OF
.. |sqsubseteq| unicode:: U+02291 .. SQUARE IMAGE OF OR EQUAL TO
.. |sqsupset| unicode:: U+02290 .. SQUARE ORIGINAL OF
.. |sqsupseteq| unicode:: U+02292 .. SQUARE ORIGINAL OF OR EQUAL TO
.. |Square| unicode:: U+025A1 .. WHITE SQUARE
.. |SquareIntersection| unicode:: U+02293 .. SQUARE CAP
.. |SquareSubset| unicode:: U+0228F .. SQUARE IMAGE OF
.. |SquareSubsetEqual| unicode:: U+02291 .. SQUARE IMAGE OF OR EQUAL TO
.. |SquareSuperset| unicode:: U+02290 .. SQUARE ORIGINAL OF
.. |SquareSupersetEqual| unicode:: U+02292 .. SQUARE ORIGINAL OF OR EQUAL TO
.. |SquareUnion| unicode:: U+02294 .. SQUARE CUP
.. |Star| unicode:: U+022C6 .. STAR OPERATOR
.. |straightepsilon| unicode:: U+003F5 .. GREEK LUNATE EPSILON SYMBOL
.. |straightphi| unicode:: U+003D5 .. GREEK PHI SYMBOL
.. |Subset| unicode:: U+022D0 .. DOUBLE SUBSET
.. |subset| unicode:: U+02282 .. SUBSET OF
.. |subseteq| unicode:: U+02286 .. SUBSET OF OR EQUAL TO
.. |subseteqq| unicode:: U+02AC5 .. SUBSET OF ABOVE EQUALS SIGN
.. |SubsetEqual| unicode:: U+02286 .. SUBSET OF OR EQUAL TO
.. |subsetneq| unicode:: U+0228A .. SUBSET OF WITH NOT EQUAL TO
.. |subsetneqq| unicode:: U+02ACB .. SUBSET OF ABOVE NOT EQUAL TO
.. |succ| unicode:: U+0227B .. SUCCEEDS
.. |succapprox| unicode:: U+02AB8 .. SUCCEEDS ABOVE ALMOST EQUAL TO
.. |succcurlyeq| unicode:: U+0227D .. SUCCEEDS OR EQUAL TO
.. |Succeeds| unicode:: U+0227B .. SUCCEEDS
.. |SucceedsEqual| unicode:: U+02AB0 .. SUCCEEDS ABOVE SINGLE-LINE EQUALS SIGN
.. |SucceedsSlantEqual| unicode:: U+0227D .. SUCCEEDS OR EQUAL TO
.. |SucceedsTilde| unicode:: U+0227F .. SUCCEEDS OR EQUIVALENT TO
.. |succeq| unicode:: U+02AB0 .. SUCCEEDS ABOVE SINGLE-LINE EQUALS SIGN
.. |succnapprox| unicode:: U+02ABA .. SUCCEEDS ABOVE NOT ALMOST EQUAL TO
.. |succneqq| unicode:: U+02AB6 .. SUCCEEDS ABOVE NOT EQUAL TO
.. |succnsim| unicode:: U+022E9 .. SUCCEEDS BUT NOT EQUIVALENT TO
.. |succsim| unicode:: U+0227F .. SUCCEEDS OR EQUIVALENT TO
.. |SuchThat| unicode:: U+0220B .. CONTAINS AS MEMBER
.. |Sum| unicode:: U+02211 .. N-ARY SUMMATION
.. |Superset| unicode:: U+02283 .. SUPERSET OF
.. |SupersetEqual| unicode:: U+02287 .. SUPERSET OF OR EQUAL TO
.. |Supset| unicode:: U+022D1 .. DOUBLE SUPERSET
.. |supset| unicode:: U+02283 .. SUPERSET OF
.. |supseteq| unicode:: U+02287 .. SUPERSET OF OR EQUAL TO
.. |supseteqq| unicode:: U+02AC6 .. SUPERSET OF ABOVE EQUALS SIGN
.. |supsetneq| unicode:: U+0228B .. SUPERSET OF WITH NOT EQUAL TO
.. |supsetneqq| unicode:: U+02ACC .. SUPERSET OF ABOVE NOT EQUAL TO
.. |swarrow| unicode:: U+02199 .. SOUTH WEST ARROW
.. |Therefore| unicode:: U+02234 .. THEREFORE
.. |therefore| unicode:: U+02234 .. THEREFORE
.. |thickapprox| unicode:: U+02248 .. ALMOST EQUAL TO
.. |thicksim| unicode:: U+0223C .. TILDE OPERATOR
.. |ThinSpace| unicode:: U+02009 .. THIN SPACE
.. |Tilde| unicode:: U+0223C .. TILDE OPERATOR
.. |TildeEqual| unicode:: U+02243 .. ASYMPTOTICALLY EQUAL TO
.. |TildeFullEqual| unicode:: U+02245 .. APPROXIMATELY EQUAL TO
.. |TildeTilde| unicode:: U+02248 .. ALMOST EQUAL TO
.. |toea| unicode:: U+02928 .. NORTH EAST ARROW AND SOUTH EAST ARROW
.. |tosa| unicode:: U+02929 .. SOUTH EAST ARROW AND SOUTH WEST ARROW
.. |triangle| unicode:: U+025B5 .. WHITE UP-POINTING SMALL TRIANGLE
.. |triangledown| unicode:: U+025BF .. WHITE DOWN-POINTING SMALL TRIANGLE
.. |triangleleft| unicode:: U+025C3 .. WHITE LEFT-POINTING SMALL TRIANGLE
.. |trianglelefteq| unicode:: U+022B4 .. NORMAL SUBGROUP OF OR EQUAL TO
.. |triangleq| unicode:: U+0225C .. DELTA EQUAL TO
.. |triangleright| unicode:: U+025B9 .. WHITE RIGHT-POINTING SMALL TRIANGLE
.. |trianglerighteq| unicode:: U+022B5 .. CONTAINS AS NORMAL SUBGROUP OR EQUAL TO
.. |TripleDot| unicode:: U+020DB .. COMBINING THREE DOTS ABOVE
.. |twoheadleftarrow| unicode:: U+0219E .. LEFTWARDS TWO HEADED ARROW
.. |twoheadrightarrow| unicode:: U+021A0 .. RIGHTWARDS TWO HEADED ARROW
.. |ulcorner| unicode:: U+0231C .. TOP LEFT CORNER
.. |Union| unicode:: U+022C3 .. N-ARY UNION
.. |UnionPlus| unicode:: U+0228E .. MULTISET UNION
.. |UpArrow| unicode:: U+02191 .. UPWARDS ARROW
.. |Uparrow| unicode:: U+021D1 .. UPWARDS DOUBLE ARROW
.. |uparrow| unicode:: U+02191 .. UPWARDS ARROW
.. |UpArrowDownArrow| unicode:: U+021C5 .. UPWARDS ARROW LEFTWARDS OF DOWNWARDS ARROW
.. |UpDownArrow| unicode:: U+02195 .. UP DOWN ARROW
.. |Updownarrow| unicode:: U+021D5 .. UP DOWN DOUBLE ARROW
.. |updownarrow| unicode:: U+02195 .. UP DOWN ARROW
.. |UpEquilibrium| unicode:: U+0296E .. UPWARDS HARPOON WITH BARB LEFT BESIDE DOWNWARDS HARPOON WITH BARB RIGHT
.. |upharpoonleft| unicode:: U+021BF .. UPWARDS HARPOON WITH BARB LEFTWARDS
.. |upharpoonright| unicode:: U+021BE .. UPWARDS HARPOON WITH BARB RIGHTWARDS
.. |UpperLeftArrow| unicode:: U+02196 .. NORTH WEST ARROW
.. |UpperRightArrow| unicode:: U+02197 .. NORTH EAST ARROW
.. |upsilon| unicode:: U+003C5 .. GREEK SMALL LETTER UPSILON
.. |UpTee| unicode:: U+022A5 .. UP TACK
.. |UpTeeArrow| unicode:: U+021A5 .. UPWARDS ARROW FROM BAR
.. |upuparrows| unicode:: U+021C8 .. UPWARDS PAIRED ARROWS
.. |urcorner| unicode:: U+0231D .. TOP RIGHT CORNER
.. |varepsilon| unicode:: U+003B5 .. GREEK SMALL LETTER EPSILON
.. |varkappa| unicode:: U+003F0 .. GREEK KAPPA SYMBOL
.. |varnothing| unicode:: U+02205 .. EMPTY SET
.. |varphi| unicode:: U+003C6 .. GREEK SMALL LETTER PHI
.. |varpi| unicode:: U+003D6 .. GREEK PI SYMBOL
.. |varpropto| unicode:: U+0221D .. PROPORTIONAL TO
.. |varrho| unicode:: U+003F1 .. GREEK RHO SYMBOL
.. |varsigma| unicode:: U+003C2 .. GREEK SMALL LETTER FINAL SIGMA
.. |varsubsetneq| unicode:: U+0228A U+0FE00 .. SUBSET OF WITH NOT EQUAL TO - variant with stroke through bottom members
.. |varsubsetneqq| unicode:: U+02ACB U+0FE00 .. SUBSET OF ABOVE NOT EQUAL TO - variant with stroke through bottom members
.. |varsupsetneq| unicode:: U+0228B U+0FE00 .. SUPERSET OF WITH NOT EQUAL TO - variant with stroke through bottom members
.. |varsupsetneqq| unicode:: U+02ACC U+0FE00 .. SUPERSET OF ABOVE NOT EQUAL TO - variant with stroke through bottom members
.. |vartheta| unicode:: U+003D1 .. GREEK THETA SYMBOL
.. |vartriangleleft| unicode:: U+022B2 .. NORMAL SUBGROUP OF
.. |vartriangleright| unicode:: U+022B3 .. CONTAINS AS NORMAL SUBGROUP
.. |Vee| unicode:: U+022C1 .. N-ARY LOGICAL OR
.. |vee| unicode:: U+02228 .. LOGICAL OR
.. |Vert| unicode:: U+02016 .. DOUBLE VERTICAL LINE
.. |vert| unicode:: U+0007C .. VERTICAL LINE
.. |VerticalBar| unicode:: U+02223 .. DIVIDES
.. |VerticalTilde| unicode:: U+02240 .. WREATH PRODUCT
.. |VeryThinSpace| unicode:: U+0200A .. HAIR SPACE
.. |Wedge| unicode:: U+022C0 .. N-ARY LOGICAL AND
.. |wedge| unicode:: U+02227 .. LOGICAL AND
.. |wp| unicode:: U+02118 .. SCRIPT CAPITAL P
.. |wr| unicode:: U+02240 .. WREATH PRODUCT
.. |zeetrf| unicode:: U+02128 .. BLACK-LETTER CAPITAL Z
@@ -0,0 +1,113 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |af| unicode:: U+02061 .. FUNCTION APPLICATION
.. |aopf| unicode:: U+1D552 .. MATHEMATICAL DOUBLE-STRUCK SMALL A
.. |asympeq| unicode:: U+0224D .. EQUIVALENT TO
.. |bopf| unicode:: U+1D553 .. MATHEMATICAL DOUBLE-STRUCK SMALL B
.. |copf| unicode:: U+1D554 .. MATHEMATICAL DOUBLE-STRUCK SMALL C
.. |Cross| unicode:: U+02A2F .. VECTOR OR CROSS PRODUCT
.. |DD| unicode:: U+02145 .. DOUBLE-STRUCK ITALIC CAPITAL D
.. |dd| unicode:: U+02146 .. DOUBLE-STRUCK ITALIC SMALL D
.. |dopf| unicode:: U+1D555 .. MATHEMATICAL DOUBLE-STRUCK SMALL D
.. |DownArrowBar| unicode:: U+02913 .. DOWNWARDS ARROW TO BAR
.. |DownBreve| unicode:: U+00311 .. COMBINING INVERTED BREVE
.. |DownLeftRightVector| unicode:: U+02950 .. LEFT BARB DOWN RIGHT BARB DOWN HARPOON
.. |DownLeftTeeVector| unicode:: U+0295E .. LEFTWARDS HARPOON WITH BARB DOWN FROM BAR
.. |DownLeftVectorBar| unicode:: U+02956 .. LEFTWARDS HARPOON WITH BARB DOWN TO BAR
.. |DownRightTeeVector| unicode:: U+0295F .. RIGHTWARDS HARPOON WITH BARB DOWN FROM BAR
.. |DownRightVectorBar| unicode:: U+02957 .. RIGHTWARDS HARPOON WITH BARB DOWN TO BAR
.. |ee| unicode:: U+02147 .. DOUBLE-STRUCK ITALIC SMALL E
.. |EmptySmallSquare| unicode:: U+025FB .. WHITE MEDIUM SQUARE
.. |EmptyVerySmallSquare| unicode:: U+025AB .. WHITE SMALL SQUARE
.. |eopf| unicode:: U+1D556 .. MATHEMATICAL DOUBLE-STRUCK SMALL E
.. |Equal| unicode:: U+02A75 .. TWO CONSECUTIVE EQUALS SIGNS
.. |FilledSmallSquare| unicode:: U+025FC .. BLACK MEDIUM SQUARE
.. |FilledVerySmallSquare| unicode:: U+025AA .. BLACK SMALL SQUARE
.. |fopf| unicode:: U+1D557 .. MATHEMATICAL DOUBLE-STRUCK SMALL F
.. |gopf| unicode:: U+1D558 .. MATHEMATICAL DOUBLE-STRUCK SMALL G
.. |GreaterGreater| unicode:: U+02AA2 .. DOUBLE NESTED GREATER-THAN
.. |Hat| unicode:: U+0005E .. CIRCUMFLEX ACCENT
.. |hopf| unicode:: U+1D559 .. MATHEMATICAL DOUBLE-STRUCK SMALL H
.. |HorizontalLine| unicode:: U+02500 .. BOX DRAWINGS LIGHT HORIZONTAL
.. |ic| unicode:: U+02063 .. INVISIBLE SEPARATOR
.. |ii| unicode:: U+02148 .. DOUBLE-STRUCK ITALIC SMALL I
.. |iopf| unicode:: U+1D55A .. MATHEMATICAL DOUBLE-STRUCK SMALL I
.. |it| unicode:: U+02062 .. INVISIBLE TIMES
.. |jopf| unicode:: U+1D55B .. MATHEMATICAL DOUBLE-STRUCK SMALL J
.. |kopf| unicode:: U+1D55C .. MATHEMATICAL DOUBLE-STRUCK SMALL K
.. |larrb| unicode:: U+021E4 .. LEFTWARDS ARROW TO BAR
.. |LeftDownTeeVector| unicode:: U+02961 .. DOWNWARDS HARPOON WITH BARB LEFT FROM BAR
.. |LeftDownVectorBar| unicode:: U+02959 .. DOWNWARDS HARPOON WITH BARB LEFT TO BAR
.. |LeftRightVector| unicode:: U+0294E .. LEFT BARB UP RIGHT BARB UP HARPOON
.. |LeftTeeVector| unicode:: U+0295A .. LEFTWARDS HARPOON WITH BARB UP FROM BAR
.. |LeftTriangleBar| unicode:: U+029CF .. LEFT TRIANGLE BESIDE VERTICAL BAR
.. |LeftUpDownVector| unicode:: U+02951 .. UP BARB LEFT DOWN BARB LEFT HARPOON
.. |LeftUpTeeVector| unicode:: U+02960 .. UPWARDS HARPOON WITH BARB LEFT FROM BAR
.. |LeftUpVectorBar| unicode:: U+02958 .. UPWARDS HARPOON WITH BARB LEFT TO BAR
.. |LeftVectorBar| unicode:: U+02952 .. LEFTWARDS HARPOON WITH BARB UP TO BAR
.. |LessLess| unicode:: U+02AA1 .. DOUBLE NESTED LESS-THAN
.. |lopf| unicode:: U+1D55D .. MATHEMATICAL DOUBLE-STRUCK SMALL L
.. |mapstodown| unicode:: U+021A7 .. DOWNWARDS ARROW FROM BAR
.. |mapstoleft| unicode:: U+021A4 .. LEFTWARDS ARROW FROM BAR
.. |mapstoup| unicode:: U+021A5 .. UPWARDS ARROW FROM BAR
.. |MediumSpace| unicode:: U+0205F .. MEDIUM MATHEMATICAL SPACE
.. |mopf| unicode:: U+1D55E .. MATHEMATICAL DOUBLE-STRUCK SMALL M
.. |nbump| unicode:: U+0224E U+00338 .. GEOMETRICALLY EQUIVALENT TO with slash
.. |nbumpe| unicode:: U+0224F U+00338 .. DIFFERENCE BETWEEN with slash
.. |nesim| unicode:: U+02242 U+00338 .. MINUS TILDE with slash
.. |NewLine| unicode:: U+0000A .. LINE FEED (LF)
.. |NoBreak| unicode:: U+02060 .. WORD JOINER
.. |nopf| unicode:: U+1D55F .. MATHEMATICAL DOUBLE-STRUCK SMALL N
.. |NotCupCap| unicode:: U+0226D .. NOT EQUIVALENT TO
.. |NotHumpEqual| unicode:: U+0224F U+00338 .. DIFFERENCE BETWEEN with slash
.. |NotLeftTriangleBar| unicode:: U+029CF U+00338 .. LEFT TRIANGLE BESIDE VERTICAL BAR with slash
.. |NotNestedGreaterGreater| unicode:: U+02AA2 U+00338 .. DOUBLE NESTED GREATER-THAN with slash
.. |NotNestedLessLess| unicode:: U+02AA1 U+00338 .. DOUBLE NESTED LESS-THAN with slash
.. |NotRightTriangleBar| unicode:: U+029D0 U+00338 .. VERTICAL BAR BESIDE RIGHT TRIANGLE with slash
.. |NotSquareSubset| unicode:: U+0228F U+00338 .. SQUARE IMAGE OF with slash
.. |NotSquareSuperset| unicode:: U+02290 U+00338 .. SQUARE ORIGINAL OF with slash
.. |NotSucceedsTilde| unicode:: U+0227F U+00338 .. SUCCEEDS OR EQUIVALENT TO with slash
.. |oopf| unicode:: U+1D560 .. MATHEMATICAL DOUBLE-STRUCK SMALL O
.. |OverBar| unicode:: U+000AF .. MACRON
.. |OverBrace| unicode:: U+0FE37 .. PRESENTATION FORM FOR VERTICAL LEFT CURLY BRACKET
.. |OverBracket| unicode:: U+023B4 .. TOP SQUARE BRACKET
.. |OverParenthesis| unicode:: U+0FE35 .. PRESENTATION FORM FOR VERTICAL LEFT PARENTHESIS
.. |planckh| unicode:: U+0210E .. PLANCK CONSTANT
.. |popf| unicode:: U+1D561 .. MATHEMATICAL DOUBLE-STRUCK SMALL P
.. |Product| unicode:: U+0220F .. N-ARY PRODUCT
.. |qopf| unicode:: U+1D562 .. MATHEMATICAL DOUBLE-STRUCK SMALL Q
.. |rarrb| unicode:: U+021E5 .. RIGHTWARDS ARROW TO BAR
.. |RightDownTeeVector| unicode:: U+0295D .. DOWNWARDS HARPOON WITH BARB RIGHT FROM BAR
.. |RightDownVectorBar| unicode:: U+02955 .. DOWNWARDS HARPOON WITH BARB RIGHT TO BAR
.. |RightTeeVector| unicode:: U+0295B .. RIGHTWARDS HARPOON WITH BARB UP FROM BAR
.. |RightTriangleBar| unicode:: U+029D0 .. VERTICAL BAR BESIDE RIGHT TRIANGLE
.. |RightUpDownVector| unicode:: U+0294F .. UP BARB RIGHT DOWN BARB RIGHT HARPOON
.. |RightUpTeeVector| unicode:: U+0295C .. UPWARDS HARPOON WITH BARB RIGHT FROM BAR
.. |RightUpVectorBar| unicode:: U+02954 .. UPWARDS HARPOON WITH BARB RIGHT TO BAR
.. |RightVectorBar| unicode:: U+02953 .. RIGHTWARDS HARPOON WITH BARB UP TO BAR
.. |ropf| unicode:: U+1D563 .. MATHEMATICAL DOUBLE-STRUCK SMALL R
.. |RoundImplies| unicode:: U+02970 .. RIGHT DOUBLE ARROW WITH ROUNDED HEAD
.. |RuleDelayed| unicode:: U+029F4 .. RULE-DELAYED
.. |sopf| unicode:: U+1D564 .. MATHEMATICAL DOUBLE-STRUCK SMALL S
.. |Tab| unicode:: U+00009 .. CHARACTER TABULATION
.. |ThickSpace| unicode:: U+02009 U+0200A U+0200A .. space of width 5/18 em
.. |topf| unicode:: U+1D565 .. MATHEMATICAL DOUBLE-STRUCK SMALL T
.. |UnderBar| unicode:: U+00332 .. COMBINING LOW LINE
.. |UnderBrace| unicode:: U+0FE38 .. PRESENTATION FORM FOR VERTICAL RIGHT CURLY BRACKET
.. |UnderBracket| unicode:: U+023B5 .. BOTTOM SQUARE BRACKET
.. |UnderParenthesis| unicode:: U+0FE36 .. PRESENTATION FORM FOR VERTICAL RIGHT PARENTHESIS
.. |uopf| unicode:: U+1D566 .. MATHEMATICAL DOUBLE-STRUCK SMALL U
.. |UpArrowBar| unicode:: U+02912 .. UPWARDS ARROW TO BAR
.. |Upsilon| unicode:: U+003A5 .. GREEK CAPITAL LETTER UPSILON
.. |VerticalLine| unicode:: U+0007C .. VERTICAL LINE
.. |VerticalSeparator| unicode:: U+02758 .. LIGHT VERTICAL BAR
.. |vopf| unicode:: U+1D567 .. MATHEMATICAL DOUBLE-STRUCK SMALL V
.. |wopf| unicode:: U+1D568 .. MATHEMATICAL DOUBLE-STRUCK SMALL W
.. |xopf| unicode:: U+1D569 .. MATHEMATICAL DOUBLE-STRUCK SMALL X
.. |yopf| unicode:: U+1D56A .. MATHEMATICAL DOUBLE-STRUCK SMALL Y
.. |ZeroWidthSpace| unicode:: U+0200B .. ZERO WIDTH SPACE
.. |zopf| unicode:: U+1D56B .. MATHEMATICAL DOUBLE-STRUCK SMALL Z
@@ -0,0 +1,87 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |af| unicode:: U+02061 .. FUNCTION APPLICATION
.. |asympeq| unicode:: U+0224D .. EQUIVALENT TO
.. |Cross| unicode:: U+02A2F .. VECTOR OR CROSS PRODUCT
.. |DD| unicode:: U+02145 .. DOUBLE-STRUCK ITALIC CAPITAL D
.. |dd| unicode:: U+02146 .. DOUBLE-STRUCK ITALIC SMALL D
.. |DownArrowBar| unicode:: U+02913 .. DOWNWARDS ARROW TO BAR
.. |DownBreve| unicode:: U+00311 .. COMBINING INVERTED BREVE
.. |DownLeftRightVector| unicode:: U+02950 .. LEFT BARB DOWN RIGHT BARB DOWN HARPOON
.. |DownLeftTeeVector| unicode:: U+0295E .. LEFTWARDS HARPOON WITH BARB DOWN FROM BAR
.. |DownLeftVectorBar| unicode:: U+02956 .. LEFTWARDS HARPOON WITH BARB DOWN TO BAR
.. |DownRightTeeVector| unicode:: U+0295F .. RIGHTWARDS HARPOON WITH BARB DOWN FROM BAR
.. |DownRightVectorBar| unicode:: U+02957 .. RIGHTWARDS HARPOON WITH BARB DOWN TO BAR
.. |ee| unicode:: U+02147 .. DOUBLE-STRUCK ITALIC SMALL E
.. |EmptySmallSquare| unicode:: U+025FB .. WHITE MEDIUM SQUARE
.. |EmptyVerySmallSquare| unicode:: U+025AB .. WHITE SMALL SQUARE
.. |Equal| unicode:: U+02A75 .. TWO CONSECUTIVE EQUALS SIGNS
.. |FilledSmallSquare| unicode:: U+025FC .. BLACK MEDIUM SQUARE
.. |FilledVerySmallSquare| unicode:: U+025AA .. BLACK SMALL SQUARE
.. |GreaterGreater| unicode:: U+02AA2 .. DOUBLE NESTED GREATER-THAN
.. |Hat| unicode:: U+0005E .. CIRCUMFLEX ACCENT
.. |HorizontalLine| unicode:: U+02500 .. BOX DRAWINGS LIGHT HORIZONTAL
.. |ic| unicode:: U+02063 .. INVISIBLE SEPARATOR
.. |ii| unicode:: U+02148 .. DOUBLE-STRUCK ITALIC SMALL I
.. |it| unicode:: U+02062 .. INVISIBLE TIMES
.. |larrb| unicode:: U+021E4 .. LEFTWARDS ARROW TO BAR
.. |LeftDownTeeVector| unicode:: U+02961 .. DOWNWARDS HARPOON WITH BARB LEFT FROM BAR
.. |LeftDownVectorBar| unicode:: U+02959 .. DOWNWARDS HARPOON WITH BARB LEFT TO BAR
.. |LeftRightVector| unicode:: U+0294E .. LEFT BARB UP RIGHT BARB UP HARPOON
.. |LeftTeeVector| unicode:: U+0295A .. LEFTWARDS HARPOON WITH BARB UP FROM BAR
.. |LeftTriangleBar| unicode:: U+029CF .. LEFT TRIANGLE BESIDE VERTICAL BAR
.. |LeftUpDownVector| unicode:: U+02951 .. UP BARB LEFT DOWN BARB LEFT HARPOON
.. |LeftUpTeeVector| unicode:: U+02960 .. UPWARDS HARPOON WITH BARB LEFT FROM BAR
.. |LeftUpVectorBar| unicode:: U+02958 .. UPWARDS HARPOON WITH BARB LEFT TO BAR
.. |LeftVectorBar| unicode:: U+02952 .. LEFTWARDS HARPOON WITH BARB UP TO BAR
.. |LessLess| unicode:: U+02AA1 .. DOUBLE NESTED LESS-THAN
.. |mapstodown| unicode:: U+021A7 .. DOWNWARDS ARROW FROM BAR
.. |mapstoleft| unicode:: U+021A4 .. LEFTWARDS ARROW FROM BAR
.. |mapstoup| unicode:: U+021A5 .. UPWARDS ARROW FROM BAR
.. |MediumSpace| unicode:: U+0205F .. MEDIUM MATHEMATICAL SPACE
.. |nbump| unicode:: U+0224E U+00338 .. GEOMETRICALLY EQUIVALENT TO with slash
.. |nbumpe| unicode:: U+0224F U+00338 .. DIFFERENCE BETWEEN with slash
.. |nesim| unicode:: U+02242 U+00338 .. MINUS TILDE with slash
.. |NewLine| unicode:: U+0000A .. LINE FEED (LF)
.. |NoBreak| unicode:: U+02060 .. WORD JOINER
.. |NotCupCap| unicode:: U+0226D .. NOT EQUIVALENT TO
.. |NotHumpEqual| unicode:: U+0224F U+00338 .. DIFFERENCE BETWEEN with slash
.. |NotLeftTriangleBar| unicode:: U+029CF U+00338 .. LEFT TRIANGLE BESIDE VERTICAL BAR with slash
.. |NotNestedGreaterGreater| unicode:: U+02AA2 U+00338 .. DOUBLE NESTED GREATER-THAN with slash
.. |NotNestedLessLess| unicode:: U+02AA1 U+00338 .. DOUBLE NESTED LESS-THAN with slash
.. |NotRightTriangleBar| unicode:: U+029D0 U+00338 .. VERTICAL BAR BESIDE RIGHT TRIANGLE with slash
.. |NotSquareSubset| unicode:: U+0228F U+00338 .. SQUARE IMAGE OF with slash
.. |NotSquareSuperset| unicode:: U+02290 U+00338 .. SQUARE ORIGINAL OF with slash
.. |NotSucceedsTilde| unicode:: U+0227F U+00338 .. SUCCEEDS OR EQUIVALENT TO with slash
.. |OverBar| unicode:: U+000AF .. MACRON
.. |OverBrace| unicode:: U+0FE37 .. PRESENTATION FORM FOR VERTICAL LEFT CURLY BRACKET
.. |OverBracket| unicode:: U+023B4 .. TOP SQUARE BRACKET
.. |OverParenthesis| unicode:: U+0FE35 .. PRESENTATION FORM FOR VERTICAL LEFT PARENTHESIS
.. |planckh| unicode:: U+0210E .. PLANCK CONSTANT
.. |Product| unicode:: U+0220F .. N-ARY PRODUCT
.. |rarrb| unicode:: U+021E5 .. RIGHTWARDS ARROW TO BAR
.. |RightDownTeeVector| unicode:: U+0295D .. DOWNWARDS HARPOON WITH BARB RIGHT FROM BAR
.. |RightDownVectorBar| unicode:: U+02955 .. DOWNWARDS HARPOON WITH BARB RIGHT TO BAR
.. |RightTeeVector| unicode:: U+0295B .. RIGHTWARDS HARPOON WITH BARB UP FROM BAR
.. |RightTriangleBar| unicode:: U+029D0 .. VERTICAL BAR BESIDE RIGHT TRIANGLE
.. |RightUpDownVector| unicode:: U+0294F .. UP BARB RIGHT DOWN BARB RIGHT HARPOON
.. |RightUpTeeVector| unicode:: U+0295C .. UPWARDS HARPOON WITH BARB RIGHT FROM BAR
.. |RightUpVectorBar| unicode:: U+02954 .. UPWARDS HARPOON WITH BARB RIGHT TO BAR
.. |RightVectorBar| unicode:: U+02953 .. RIGHTWARDS HARPOON WITH BARB UP TO BAR
.. |RoundImplies| unicode:: U+02970 .. RIGHT DOUBLE ARROW WITH ROUNDED HEAD
.. |RuleDelayed| unicode:: U+029F4 .. RULE-DELAYED
.. |Tab| unicode:: U+00009 .. CHARACTER TABULATION
.. |ThickSpace| unicode:: U+02009 U+0200A U+0200A .. space of width 5/18 em
.. |UnderBar| unicode:: U+00332 .. COMBINING LOW LINE
.. |UnderBrace| unicode:: U+0FE38 .. PRESENTATION FORM FOR VERTICAL RIGHT CURLY BRACKET
.. |UnderBracket| unicode:: U+023B5 .. BOTTOM SQUARE BRACKET
.. |UnderParenthesis| unicode:: U+0FE36 .. PRESENTATION FORM FOR VERTICAL RIGHT PARENTHESIS
.. |UpArrowBar| unicode:: U+02912 .. UPWARDS ARROW TO BAR
.. |Upsilon| unicode:: U+003A5 .. GREEK CAPITAL LETTER UPSILON
.. |VerticalLine| unicode:: U+0007C .. VERTICAL LINE
.. |VerticalSeparator| unicode:: U+02758 .. LIGHT VERTICAL BAR
.. |ZeroWidthSpace| unicode:: U+0200B .. ZERO WIDTH SPACE
@@ -0,0 +1,68 @@
.. Definitions of interpreted text roles (classes) for S5/HTML data.
.. This data file has been placed in the public domain.
.. Colours
=======
.. role:: black
.. role:: gray
.. role:: silver
.. role:: white
.. role:: maroon
.. role:: red
.. role:: magenta
.. role:: fuchsia
.. role:: pink
.. role:: orange
.. role:: yellow
.. role:: lime
.. role:: green
.. role:: olive
.. role:: teal
.. role:: cyan
.. role:: aqua
.. role:: blue
.. role:: navy
.. role:: purple
.. Text Sizes
==========
.. role:: huge
.. role:: big
.. role:: small
.. role:: tiny
.. Display in Slides (Presentation Mode) Only
==========================================
.. role:: slide
:class: slide-display
.. Display in Outline Mode Only
============================
.. role:: outline
.. Display in Print Only
=====================
.. role:: print
.. Display in Handout Mode Only
============================
.. role:: handout
.. Incremental Display
===================
.. role:: incremental
.. default-role:: incremental
@@ -0,0 +1,102 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |Aacute| unicode:: U+000C1 .. LATIN CAPITAL LETTER A WITH ACUTE
.. |aacute| unicode:: U+000E1 .. LATIN SMALL LETTER A WITH ACUTE
.. |Acirc| unicode:: U+000C2 .. LATIN CAPITAL LETTER A WITH CIRCUMFLEX
.. |acirc| unicode:: U+000E2 .. LATIN SMALL LETTER A WITH CIRCUMFLEX
.. |acute| unicode:: U+000B4 .. ACUTE ACCENT
.. |AElig| unicode:: U+000C6 .. LATIN CAPITAL LETTER AE
.. |aelig| unicode:: U+000E6 .. LATIN SMALL LETTER AE
.. |Agrave| unicode:: U+000C0 .. LATIN CAPITAL LETTER A WITH GRAVE
.. |agrave| unicode:: U+000E0 .. LATIN SMALL LETTER A WITH GRAVE
.. |Aring| unicode:: U+000C5 .. LATIN CAPITAL LETTER A WITH RING ABOVE
.. |aring| unicode:: U+000E5 .. LATIN SMALL LETTER A WITH RING ABOVE
.. |Atilde| unicode:: U+000C3 .. LATIN CAPITAL LETTER A WITH TILDE
.. |atilde| unicode:: U+000E3 .. LATIN SMALL LETTER A WITH TILDE
.. |Auml| unicode:: U+000C4 .. LATIN CAPITAL LETTER A WITH DIAERESIS
.. |auml| unicode:: U+000E4 .. LATIN SMALL LETTER A WITH DIAERESIS
.. |brvbar| unicode:: U+000A6 .. BROKEN BAR
.. |Ccedil| unicode:: U+000C7 .. LATIN CAPITAL LETTER C WITH CEDILLA
.. |ccedil| unicode:: U+000E7 .. LATIN SMALL LETTER C WITH CEDILLA
.. |cedil| unicode:: U+000B8 .. CEDILLA
.. |cent| unicode:: U+000A2 .. CENT SIGN
.. |copy| unicode:: U+000A9 .. COPYRIGHT SIGN
.. |curren| unicode:: U+000A4 .. CURRENCY SIGN
.. |deg| unicode:: U+000B0 .. DEGREE SIGN
.. |divide| unicode:: U+000F7 .. DIVISION SIGN
.. |Eacute| unicode:: U+000C9 .. LATIN CAPITAL LETTER E WITH ACUTE
.. |eacute| unicode:: U+000E9 .. LATIN SMALL LETTER E WITH ACUTE
.. |Ecirc| unicode:: U+000CA .. LATIN CAPITAL LETTER E WITH CIRCUMFLEX
.. |ecirc| unicode:: U+000EA .. LATIN SMALL LETTER E WITH CIRCUMFLEX
.. |Egrave| unicode:: U+000C8 .. LATIN CAPITAL LETTER E WITH GRAVE
.. |egrave| unicode:: U+000E8 .. LATIN SMALL LETTER E WITH GRAVE
.. |ETH| unicode:: U+000D0 .. LATIN CAPITAL LETTER ETH
.. |eth| unicode:: U+000F0 .. LATIN SMALL LETTER ETH
.. |Euml| unicode:: U+000CB .. LATIN CAPITAL LETTER E WITH DIAERESIS
.. |euml| unicode:: U+000EB .. LATIN SMALL LETTER E WITH DIAERESIS
.. |frac12| unicode:: U+000BD .. VULGAR FRACTION ONE HALF
.. |frac14| unicode:: U+000BC .. VULGAR FRACTION ONE QUARTER
.. |frac34| unicode:: U+000BE .. VULGAR FRACTION THREE QUARTERS
.. |Iacute| unicode:: U+000CD .. LATIN CAPITAL LETTER I WITH ACUTE
.. |iacute| unicode:: U+000ED .. LATIN SMALL LETTER I WITH ACUTE
.. |Icirc| unicode:: U+000CE .. LATIN CAPITAL LETTER I WITH CIRCUMFLEX
.. |icirc| unicode:: U+000EE .. LATIN SMALL LETTER I WITH CIRCUMFLEX
.. |iexcl| unicode:: U+000A1 .. INVERTED EXCLAMATION MARK
.. |Igrave| unicode:: U+000CC .. LATIN CAPITAL LETTER I WITH GRAVE
.. |igrave| unicode:: U+000EC .. LATIN SMALL LETTER I WITH GRAVE
.. |iquest| unicode:: U+000BF .. INVERTED QUESTION MARK
.. |Iuml| unicode:: U+000CF .. LATIN CAPITAL LETTER I WITH DIAERESIS
.. |iuml| unicode:: U+000EF .. LATIN SMALL LETTER I WITH DIAERESIS
.. |laquo| unicode:: U+000AB .. LEFT-POINTING DOUBLE ANGLE QUOTATION MARK
.. |macr| unicode:: U+000AF .. MACRON
.. |micro| unicode:: U+000B5 .. MICRO SIGN
.. |middot| unicode:: U+000B7 .. MIDDLE DOT
.. |nbsp| unicode:: U+000A0 .. NO-BREAK SPACE
.. |not| unicode:: U+000AC .. NOT SIGN
.. |Ntilde| unicode:: U+000D1 .. LATIN CAPITAL LETTER N WITH TILDE
.. |ntilde| unicode:: U+000F1 .. LATIN SMALL LETTER N WITH TILDE
.. |Oacute| unicode:: U+000D3 .. LATIN CAPITAL LETTER O WITH ACUTE
.. |oacute| unicode:: U+000F3 .. LATIN SMALL LETTER O WITH ACUTE
.. |Ocirc| unicode:: U+000D4 .. LATIN CAPITAL LETTER O WITH CIRCUMFLEX
.. |ocirc| unicode:: U+000F4 .. LATIN SMALL LETTER O WITH CIRCUMFLEX
.. |Ograve| unicode:: U+000D2 .. LATIN CAPITAL LETTER O WITH GRAVE
.. |ograve| unicode:: U+000F2 .. LATIN SMALL LETTER O WITH GRAVE
.. |ordf| unicode:: U+000AA .. FEMININE ORDINAL INDICATOR
.. |ordm| unicode:: U+000BA .. MASCULINE ORDINAL INDICATOR
.. |Oslash| unicode:: U+000D8 .. LATIN CAPITAL LETTER O WITH STROKE
.. |oslash| unicode:: U+000F8 .. LATIN SMALL LETTER O WITH STROKE
.. |Otilde| unicode:: U+000D5 .. LATIN CAPITAL LETTER O WITH TILDE
.. |otilde| unicode:: U+000F5 .. LATIN SMALL LETTER O WITH TILDE
.. |Ouml| unicode:: U+000D6 .. LATIN CAPITAL LETTER O WITH DIAERESIS
.. |ouml| unicode:: U+000F6 .. LATIN SMALL LETTER O WITH DIAERESIS
.. |para| unicode:: U+000B6 .. PILCROW SIGN
.. |plusmn| unicode:: U+000B1 .. PLUS-MINUS SIGN
.. |pound| unicode:: U+000A3 .. POUND SIGN
.. |raquo| unicode:: U+000BB .. RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK
.. |reg| unicode:: U+000AE .. REGISTERED SIGN
.. |sect| unicode:: U+000A7 .. SECTION SIGN
.. |shy| unicode:: U+000AD .. SOFT HYPHEN
.. |sup1| unicode:: U+000B9 .. SUPERSCRIPT ONE
.. |sup2| unicode:: U+000B2 .. SUPERSCRIPT TWO
.. |sup3| unicode:: U+000B3 .. SUPERSCRIPT THREE
.. |szlig| unicode:: U+000DF .. LATIN SMALL LETTER SHARP S
.. |THORN| unicode:: U+000DE .. LATIN CAPITAL LETTER THORN
.. |thorn| unicode:: U+000FE .. LATIN SMALL LETTER THORN
.. |times| unicode:: U+000D7 .. MULTIPLICATION SIGN
.. |Uacute| unicode:: U+000DA .. LATIN CAPITAL LETTER U WITH ACUTE
.. |uacute| unicode:: U+000FA .. LATIN SMALL LETTER U WITH ACUTE
.. |Ucirc| unicode:: U+000DB .. LATIN CAPITAL LETTER U WITH CIRCUMFLEX
.. |ucirc| unicode:: U+000FB .. LATIN SMALL LETTER U WITH CIRCUMFLEX
.. |Ugrave| unicode:: U+000D9 .. LATIN CAPITAL LETTER U WITH GRAVE
.. |ugrave| unicode:: U+000F9 .. LATIN SMALL LETTER U WITH GRAVE
.. |uml| unicode:: U+000A8 .. DIAERESIS
.. |Uuml| unicode:: U+000DC .. LATIN CAPITAL LETTER U WITH DIAERESIS
.. |uuml| unicode:: U+000FC .. LATIN SMALL LETTER U WITH DIAERESIS
.. |Yacute| unicode:: U+000DD .. LATIN CAPITAL LETTER Y WITH ACUTE
.. |yacute| unicode:: U+000FD .. LATIN SMALL LETTER Y WITH ACUTE
.. |yen| unicode:: U+000A5 .. YEN SIGN
.. |yuml| unicode:: U+000FF .. LATIN SMALL LETTER Y WITH DIAERESIS
@@ -0,0 +1,37 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |bdquo| unicode:: U+0201E .. DOUBLE LOW-9 QUOTATION MARK
.. |circ| unicode:: U+002C6 .. MODIFIER LETTER CIRCUMFLEX ACCENT
.. |Dagger| unicode:: U+02021 .. DOUBLE DAGGER
.. |dagger| unicode:: U+02020 .. DAGGER
.. |emsp| unicode:: U+02003 .. EM SPACE
.. |ensp| unicode:: U+02002 .. EN SPACE
.. |euro| unicode:: U+020AC .. EURO SIGN
.. |gt| unicode:: U+0003E .. GREATER-THAN SIGN
.. |ldquo| unicode:: U+0201C .. LEFT DOUBLE QUOTATION MARK
.. |lrm| unicode:: U+0200E .. LEFT-TO-RIGHT MARK
.. |lsaquo| unicode:: U+02039 .. SINGLE LEFT-POINTING ANGLE QUOTATION MARK
.. |lsquo| unicode:: U+02018 .. LEFT SINGLE QUOTATION MARK
.. |lt| unicode:: U+0003C .. LESS-THAN SIGN
.. |mdash| unicode:: U+02014 .. EM DASH
.. |ndash| unicode:: U+02013 .. EN DASH
.. |OElig| unicode:: U+00152 .. LATIN CAPITAL LIGATURE OE
.. |oelig| unicode:: U+00153 .. LATIN SMALL LIGATURE OE
.. |permil| unicode:: U+02030 .. PER MILLE SIGN
.. |quot| unicode:: U+00022 .. QUOTATION MARK
.. |rdquo| unicode:: U+0201D .. RIGHT DOUBLE QUOTATION MARK
.. |rlm| unicode:: U+0200F .. RIGHT-TO-LEFT MARK
.. |rsaquo| unicode:: U+0203A .. SINGLE RIGHT-POINTING ANGLE QUOTATION MARK
.. |rsquo| unicode:: U+02019 .. RIGHT SINGLE QUOTATION MARK
.. |sbquo| unicode:: U+0201A .. SINGLE LOW-9 QUOTATION MARK
.. |Scaron| unicode:: U+00160 .. LATIN CAPITAL LETTER S WITH CARON
.. |scaron| unicode:: U+00161 .. LATIN SMALL LETTER S WITH CARON
.. |thinsp| unicode:: U+02009 .. THIN SPACE
.. |tilde| unicode:: U+002DC .. SMALL TILDE
.. |Yuml| unicode:: U+00178 .. LATIN CAPITAL LETTER Y WITH DIAERESIS
.. |zwj| unicode:: U+0200D .. ZERO WIDTH JOINER
.. |zwnj| unicode:: U+0200C .. ZERO WIDTH NON-JOINER
@@ -0,0 +1,130 @@
.. This data file has been placed in the public domain.
.. Derived from the Unicode character mappings available from
<http://www.w3.org/2003/entities/xml/>.
Processed by unicode2rstsubs.py, part of Docutils:
<http://docutils.sourceforge.net>.
.. |alefsym| unicode:: U+02135 .. ALEF SYMBOL
.. |Alpha| unicode:: U+00391 .. GREEK CAPITAL LETTER ALPHA
.. |alpha| unicode:: U+003B1 .. GREEK SMALL LETTER ALPHA
.. |and| unicode:: U+02227 .. LOGICAL AND
.. |ang| unicode:: U+02220 .. ANGLE
.. |asymp| unicode:: U+02248 .. ALMOST EQUAL TO
.. |Beta| unicode:: U+00392 .. GREEK CAPITAL LETTER BETA
.. |beta| unicode:: U+003B2 .. GREEK SMALL LETTER BETA
.. |bull| unicode:: U+02022 .. BULLET
.. |cap| unicode:: U+02229 .. INTERSECTION
.. |Chi| unicode:: U+003A7 .. GREEK CAPITAL LETTER CHI
.. |chi| unicode:: U+003C7 .. GREEK SMALL LETTER CHI
.. |clubs| unicode:: U+02663 .. BLACK CLUB SUIT
.. |cong| unicode:: U+02245 .. APPROXIMATELY EQUAL TO
.. |crarr| unicode:: U+021B5 .. DOWNWARDS ARROW WITH CORNER LEFTWARDS
.. |cup| unicode:: U+0222A .. UNION
.. |dArr| unicode:: U+021D3 .. DOWNWARDS DOUBLE ARROW
.. |darr| unicode:: U+02193 .. DOWNWARDS ARROW
.. |Delta| unicode:: U+00394 .. GREEK CAPITAL LETTER DELTA
.. |delta| unicode:: U+003B4 .. GREEK SMALL LETTER DELTA
.. |diams| unicode:: U+02666 .. BLACK DIAMOND SUIT
.. |empty| unicode:: U+02205 .. EMPTY SET
.. |Epsilon| unicode:: U+00395 .. GREEK CAPITAL LETTER EPSILON
.. |epsilon| unicode:: U+003B5 .. GREEK SMALL LETTER EPSILON
.. |equiv| unicode:: U+02261 .. IDENTICAL TO
.. |Eta| unicode:: U+00397 .. GREEK CAPITAL LETTER ETA
.. |eta| unicode:: U+003B7 .. GREEK SMALL LETTER ETA
.. |exist| unicode:: U+02203 .. THERE EXISTS
.. |fnof| unicode:: U+00192 .. LATIN SMALL LETTER F WITH HOOK
.. |forall| unicode:: U+02200 .. FOR ALL
.. |frasl| unicode:: U+02044 .. FRACTION SLASH
.. |Gamma| unicode:: U+00393 .. GREEK CAPITAL LETTER GAMMA
.. |gamma| unicode:: U+003B3 .. GREEK SMALL LETTER GAMMA
.. |ge| unicode:: U+02265 .. GREATER-THAN OR EQUAL TO
.. |hArr| unicode:: U+021D4 .. LEFT RIGHT DOUBLE ARROW
.. |harr| unicode:: U+02194 .. LEFT RIGHT ARROW
.. |hearts| unicode:: U+02665 .. BLACK HEART SUIT
.. |hellip| unicode:: U+02026 .. HORIZONTAL ELLIPSIS
.. |image| unicode:: U+02111 .. BLACK-LETTER CAPITAL I
.. |infin| unicode:: U+0221E .. INFINITY
.. |int| unicode:: U+0222B .. INTEGRAL
.. |Iota| unicode:: U+00399 .. GREEK CAPITAL LETTER IOTA
.. |iota| unicode:: U+003B9 .. GREEK SMALL LETTER IOTA
.. |isin| unicode:: U+02208 .. ELEMENT OF
.. |Kappa| unicode:: U+0039A .. GREEK CAPITAL LETTER KAPPA
.. |kappa| unicode:: U+003BA .. GREEK SMALL LETTER KAPPA
.. |Lambda| unicode:: U+0039B .. GREEK CAPITAL LETTER LAMDA
.. |lambda| unicode:: U+003BB .. GREEK SMALL LETTER LAMDA
.. |lang| unicode:: U+02329 .. LEFT-POINTING ANGLE BRACKET
.. |lArr| unicode:: U+021D0 .. LEFTWARDS DOUBLE ARROW
.. |larr| unicode:: U+02190 .. LEFTWARDS ARROW
.. |lceil| unicode:: U+02308 .. LEFT CEILING
.. |le| unicode:: U+02264 .. LESS-THAN OR EQUAL TO
.. |lfloor| unicode:: U+0230A .. LEFT FLOOR
.. |lowast| unicode:: U+02217 .. ASTERISK OPERATOR
.. |loz| unicode:: U+025CA .. LOZENGE
.. |minus| unicode:: U+02212 .. MINUS SIGN
.. |Mu| unicode:: U+0039C .. GREEK CAPITAL LETTER MU
.. |mu| unicode:: U+003BC .. GREEK SMALL LETTER MU
.. |nabla| unicode:: U+02207 .. NABLA
.. |ne| unicode:: U+02260 .. NOT EQUAL TO
.. |ni| unicode:: U+0220B .. CONTAINS AS MEMBER
.. |notin| unicode:: U+02209 .. NOT AN ELEMENT OF
.. |nsub| unicode:: U+02284 .. NOT A SUBSET OF
.. |Nu| unicode:: U+0039D .. GREEK CAPITAL LETTER NU
.. |nu| unicode:: U+003BD .. GREEK SMALL LETTER NU
.. |oline| unicode:: U+0203E .. OVERLINE
.. |Omega| unicode:: U+003A9 .. GREEK CAPITAL LETTER OMEGA
.. |omega| unicode:: U+003C9 .. GREEK SMALL LETTER OMEGA
.. |Omicron| unicode:: U+0039F .. GREEK CAPITAL LETTER OMICRON
.. |omicron| unicode:: U+003BF .. GREEK SMALL LETTER OMICRON
.. |oplus| unicode:: U+02295 .. CIRCLED PLUS
.. |or| unicode:: U+02228 .. LOGICAL OR
.. |otimes| unicode:: U+02297 .. CIRCLED TIMES
.. |part| unicode:: U+02202 .. PARTIAL DIFFERENTIAL
.. |perp| unicode:: U+022A5 .. UP TACK
.. |Phi| unicode:: U+003A6 .. GREEK CAPITAL LETTER PHI
.. |phi| unicode:: U+003D5 .. GREEK PHI SYMBOL
.. |Pi| unicode:: U+003A0 .. GREEK CAPITAL LETTER PI
.. |pi| unicode:: U+003C0 .. GREEK SMALL LETTER PI
.. |piv| unicode:: U+003D6 .. GREEK PI SYMBOL
.. |Prime| unicode:: U+02033 .. DOUBLE PRIME
.. |prime| unicode:: U+02032 .. PRIME
.. |prod| unicode:: U+0220F .. N-ARY PRODUCT
.. |prop| unicode:: U+0221D .. PROPORTIONAL TO
.. |Psi| unicode:: U+003A8 .. GREEK CAPITAL LETTER PSI
.. |psi| unicode:: U+003C8 .. GREEK SMALL LETTER PSI
.. |radic| unicode:: U+0221A .. SQUARE ROOT
.. |rang| unicode:: U+0232A .. RIGHT-POINTING ANGLE BRACKET
.. |rArr| unicode:: U+021D2 .. RIGHTWARDS DOUBLE ARROW
.. |rarr| unicode:: U+02192 .. RIGHTWARDS ARROW
.. |rceil| unicode:: U+02309 .. RIGHT CEILING
.. |real| unicode:: U+0211C .. BLACK-LETTER CAPITAL R
.. |rfloor| unicode:: U+0230B .. RIGHT FLOOR
.. |Rho| unicode:: U+003A1 .. GREEK CAPITAL LETTER RHO
.. |rho| unicode:: U+003C1 .. GREEK SMALL LETTER RHO
.. |sdot| unicode:: U+022C5 .. DOT OPERATOR
.. |Sigma| unicode:: U+003A3 .. GREEK CAPITAL LETTER SIGMA
.. |sigma| unicode:: U+003C3 .. GREEK SMALL LETTER SIGMA
.. |sigmaf| unicode:: U+003C2 .. GREEK SMALL LETTER FINAL SIGMA
.. |sim| unicode:: U+0223C .. TILDE OPERATOR
.. |spades| unicode:: U+02660 .. BLACK SPADE SUIT
.. |sub| unicode:: U+02282 .. SUBSET OF
.. |sube| unicode:: U+02286 .. SUBSET OF OR EQUAL TO
.. |sum| unicode:: U+02211 .. N-ARY SUMMATION
.. |sup| unicode:: U+02283 .. SUPERSET OF
.. |supe| unicode:: U+02287 .. SUPERSET OF OR EQUAL TO
.. |Tau| unicode:: U+003A4 .. GREEK CAPITAL LETTER TAU
.. |tau| unicode:: U+003C4 .. GREEK SMALL LETTER TAU
.. |there4| unicode:: U+02234 .. THEREFORE
.. |Theta| unicode:: U+00398 .. GREEK CAPITAL LETTER THETA
.. |theta| unicode:: U+003B8 .. GREEK SMALL LETTER THETA
.. |thetasym| unicode:: U+003D1 .. GREEK THETA SYMBOL
.. |trade| unicode:: U+02122 .. TRADE MARK SIGN
.. |uArr| unicode:: U+021D1 .. UPWARDS DOUBLE ARROW
.. |uarr| unicode:: U+02191 .. UPWARDS ARROW
.. |upsih| unicode:: U+003D2 .. GREEK UPSILON WITH HOOK SYMBOL
.. |Upsilon| unicode:: U+003A5 .. GREEK CAPITAL LETTER UPSILON
.. |upsilon| unicode:: U+003C5 .. GREEK SMALL LETTER UPSILON
.. |weierp| unicode:: U+02118 .. SCRIPT CAPITAL P
.. |Xi| unicode:: U+0039E .. GREEK CAPITAL LETTER XI
.. |xi| unicode:: U+003BE .. GREEK SMALL LETTER XI
.. |Zeta| unicode:: U+00396 .. GREEK CAPITAL LETTER ZETA
.. |zeta| unicode:: U+003B6 .. GREEK SMALL LETTER ZETA
@@ -0,0 +1,25 @@
# $Id: __init__.py 5618 2008-07-28 08:37:32Z strank $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
# Internationalization details are documented in
# <http://docutils.sf.net/docs/howto/i18n.html>.
"""
This package contains modules for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
_languages = {}
def get_language(language_code):
if language_code in _languages:
return _languages[language_code]
try:
module = __import__(language_code, globals(), locals())
except ImportError:
return None
_languages[language_code] = module
return module
@@ -0,0 +1,102 @@
# $Id: af.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: Jannie Hofmeyr <jhsh@sun.ac.za>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Afrikaans-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
'aandag': 'attention',
'versigtig': 'caution',
'gevaar': 'danger',
'fout': 'error',
'wenk': 'hint',
'belangrik': 'important',
'nota': 'note',
'tip': 'tip', # hint and tip both have the same translation: wenk
'waarskuwing': 'warning',
'vermaning': 'admonition',
'kantstreep': 'sidebar',
'onderwerp': 'topic',
'lynblok': 'line-block',
'parsed-literal (translation required)': 'parsed-literal',
'rubriek': 'rubric',
'epigraaf': 'epigraph',
'hoogtepunte': 'highlights',
'pull-quote (translation required)': 'pull-quote',
u'compound (translation required)': 'compound',
u'container (translation required)': 'container',
#'vrae': 'questions',
#'qa': 'questions',
#'faq': 'questions',
'table (translation required)': 'table',
'csv-table (translation required)': 'csv-table',
'list-table (translation required)': 'list-table',
'meta': 'meta',
#'beeldkaart': 'imagemap',
'beeld': 'image',
'figuur': 'figure',
'insluiting': 'include',
'rou': 'raw',
'vervang': 'replace',
'unicode': 'unicode', # should this be translated? unikode
'datum': 'date',
'klas': 'class',
'role (translation required)': 'role',
'default-role (translation required)': 'default-role',
'title (translation required)': 'title',
'inhoud': 'contents',
'sectnum': 'sectnum',
'section-numbering': 'sectnum',
u'header (translation required)': 'header',
u'footer (translation required)': 'footer',
#'voetnote': 'footnotes',
#'aanhalings': 'citations',
'teikennotas': 'target-notes',
'restructuredtext-test-directive': 'restructuredtext-test-directive'}
"""Afrikaans name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
'afkorting': 'abbreviation',
'ab': 'abbreviation',
'akroniem': 'acronym',
'ac': 'acronym',
'indeks': 'index',
'i': 'index',
'voetskrif': 'subscript',
'sub': 'subscript',
'boskrif': 'superscript',
'sup': 'superscript',
'titelverwysing': 'title-reference',
'titel': 'title-reference',
't': 'title-reference',
'pep-verwysing': 'pep-reference',
'pep': 'pep-reference',
'rfc-verwysing': 'rfc-reference',
'rfc': 'rfc-reference',
'nadruk': 'emphasis',
'sterk': 'strong',
'literal (translation required)': 'literal',
'benoemde verwysing': 'named-reference',
'anonieme verwysing': 'anonymous-reference',
'voetnootverwysing': 'footnote-reference',
'aanhalingverwysing': 'citation-reference',
'vervangingsverwysing': 'substitution-reference',
'teiken': 'target',
'uri-verwysing': 'uri-reference',
'uri': 'uri-reference',
'url': 'uri-reference',
'rou': 'raw',}
"""Mapping of Afrikaans role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,121 @@
# $Id: ca.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: Ivan Vilata i Balaguer <ivan@selidor.net>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Catalan-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
# language-dependent: fixed
u'atenci\u00F3': 'attention',
u'compte': 'caution',
u'perill': 'danger',
u'error': 'error',
u'suggeriment': 'hint',
u'important': 'important',
u'nota': 'note',
u'consell': 'tip',
u'av\u00EDs': 'warning',
u'advertiment': 'admonition',
u'nota-al-marge': 'sidebar',
u'nota-marge': 'sidebar',
u'tema': 'topic',
u'bloc-de-l\u00EDnies': 'line-block',
u'bloc-l\u00EDnies': 'line-block',
u'literal-analitzat': 'parsed-literal',
u'r\u00FAbrica': 'rubric',
u'ep\u00EDgraf': 'epigraph',
u'sumari': 'highlights',
u'cita-destacada': 'pull-quote',
u'compost': 'compound',
u'container (translation required)': 'container',
#'questions': 'questions',
u'taula': 'table',
u'taula-csv': 'csv-table',
u'taula-llista': 'list-table',
#'qa': 'questions',
#'faq': 'questions',
u'meta': 'meta',
#'imagemap': 'imagemap',
u'imatge': 'image',
u'figura': 'figure',
u'inclou': 'include',
u'incloure': 'include',
u'cru': 'raw',
u'reempla\u00E7a': 'replace',
u'reempla\u00E7ar': 'replace',
u'unicode': 'unicode',
u'data': 'date',
u'classe': 'class',
u'rol': 'role',
u'default-role (translation required)': 'default-role',
u'title (translation required)': 'title',
u'contingut': 'contents',
u'numsec': 'sectnum',
u'numeraci\u00F3-de-seccions': 'sectnum',
u'numeraci\u00F3-seccions': 'sectnum',
u'cap\u00E7alera': 'header',
u'peu-de-p\u00E0gina': 'footer',
u'peu-p\u00E0gina': 'footer',
#'footnotes': 'footnotes',
#'citations': 'citations',
u'notes-amb-destinacions': 'target-notes',
u'notes-destinacions': 'target-notes',
u'directiva-de-prova-de-restructuredtext': 'restructuredtext-test-directive'}
"""Catalan name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
# language-dependent: fixed
u'abreviatura': 'abbreviation',
u'abreviaci\u00F3': 'abbreviation',
u'abrev': 'abbreviation',
u'ab': 'abbreviation',
u'acr\u00F2nim': 'acronym',
u'ac': 'acronym',
u'\u00EDndex': 'index',
u'i': 'index',
u'sub\u00EDndex': 'subscript',
u'sub': 'subscript',
u'super\u00EDndex': 'superscript',
u'sup': 'superscript',
u'refer\u00E8ncia-a-t\u00EDtol': 'title-reference',
u'refer\u00E8ncia-t\u00EDtol': 'title-reference',
u't\u00EDtol': 'title-reference',
u't': 'title-reference',
u'refer\u00E8ncia-a-pep': 'pep-reference',
u'refer\u00E8ncia-pep': 'pep-reference',
u'pep': 'pep-reference',
u'refer\u00E8ncia-a-rfc': 'rfc-reference',
u'refer\u00E8ncia-rfc': 'rfc-reference',
u'rfc': 'rfc-reference',
u'\u00E8mfasi': 'emphasis',
u'destacat': 'strong',
u'literal': 'literal',
u'refer\u00E8ncia-amb-nom': 'named-reference',
u'refer\u00E8ncia-nom': 'named-reference',
u'refer\u00E8ncia-an\u00F2nima': 'anonymous-reference',
u'refer\u00E8ncia-a-nota-al-peu': 'footnote-reference',
u'refer\u00E8ncia-nota-al-peu': 'footnote-reference',
u'refer\u00E8ncia-a-cita': 'citation-reference',
u'refer\u00E8ncia-cita': 'citation-reference',
u'refer\u00E8ncia-a-substituci\u00F3': 'substitution-reference',
u'refer\u00E8ncia-substituci\u00F3': 'substitution-reference',
u'destinaci\u00F3': 'target',
u'refer\u00E8ncia-a-uri': 'uri-reference',
u'refer\u00E8ncia-uri': 'uri-reference',
u'uri': 'uri-reference',
u'url': 'uri-reference',
u'cru': 'raw',}
"""Mapping of Catalan role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,104 @@
# $Id: cs.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: Marek Blaha <mb@dat.cz>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Czech-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
# language-dependent: fixed
u'pozor': 'attention',
u'caution (translation required)': 'caution', # jak rozlisit caution a warning?
u'nebezpe\u010D\u00ED': 'danger',
u'chyba': 'error',
u'rada': 'hint',
u'd\u016Fle\u017Eit\u00E9': 'important',
u'pozn\u00E1mka': 'note',
u'tip (translation required)': 'tip',
u'varov\u00E1n\u00ED': 'warning',
u'admonition (translation required)': 'admonition',
u'sidebar (translation required)': 'sidebar',
u't\u00E9ma': 'topic',
u'line-block (translation required)': 'line-block',
u'parsed-literal (translation required)': 'parsed-literal',
u'odd\u00EDl': 'rubric',
u'moto': 'epigraph',
u'highlights (translation required)': 'highlights',
u'pull-quote (translation required)': 'pull-quote',
u'compound (translation required)': 'compound',
u'container (translation required)': 'container',
#'questions': 'questions',
#'qa': 'questions',
#'faq': 'questions',
u'table (translation required)': 'table',
u'csv-table (translation required)': 'csv-table',
u'list-table (translation required)': 'list-table',
u'meta (translation required)': 'meta',
#'imagemap': 'imagemap',
u'image (translation required)': 'image', # obrazek
u'figure (translation required)': 'figure', # a tady?
u'include (translation required)': 'include',
u'raw (translation required)': 'raw',
u'replace (translation required)': 'replace',
u'unicode (translation required)': 'unicode',
u'datum': 'date',
u't\u0159\u00EDda': 'class',
u'role (translation required)': 'role',
u'default-role (translation required)': 'default-role',
u'title (translation required)': 'title',
u'obsah': 'contents',
u'sectnum (translation required)': 'sectnum',
u'section-numbering (translation required)': 'sectnum',
u'header (translation required)': 'header',
u'footer (translation required)': 'footer',
#'footnotes': 'footnotes',
#'citations': 'citations',
u'target-notes (translation required)': 'target-notes',
u'restructuredtext-test-directive': 'restructuredtext-test-directive'}
"""Czech name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
# language-dependent: fixed
u'abbreviation (translation required)': 'abbreviation',
u'ab (translation required)': 'abbreviation',
u'acronym (translation required)': 'acronym',
u'ac (translation required)': 'acronym',
u'index (translation required)': 'index',
u'i (translation required)': 'index',
u'subscript (translation required)': 'subscript',
u'sub (translation required)': 'subscript',
u'superscript (translation required)': 'superscript',
u'sup (translation required)': 'superscript',
u'title-reference (translation required)': 'title-reference',
u'title (translation required)': 'title-reference',
u't (translation required)': 'title-reference',
u'pep-reference (translation required)': 'pep-reference',
u'pep (translation required)': 'pep-reference',
u'rfc-reference (translation required)': 'rfc-reference',
u'rfc (translation required)': 'rfc-reference',
u'emphasis (translation required)': 'emphasis',
u'strong (translation required)': 'strong',
u'literal (translation required)': 'literal',
u'named-reference (translation required)': 'named-reference',
u'anonymous-reference (translation required)': 'anonymous-reference',
u'footnote-reference (translation required)': 'footnote-reference',
u'citation-reference (translation required)': 'citation-reference',
u'substitution-reference (translation required)': 'substitution-reference',
u'target (translation required)': 'target',
u'uri-reference (translation required)': 'uri-reference',
u'uri (translation required)': 'uri-reference',
u'url (translation required)': 'uri-reference',
u'raw (translation required)': 'raw',}
"""Mapping of Czech role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,96 @@
# $Id: de.py 5174 2007-05-31 00:01:52Z wiemann $
# Authors: Engelbert Gruber <grubert@users.sourceforge.net>;
# Lea Wiemann <LeWiemann@gmail.com>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
German-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
'achtung': 'attention',
'vorsicht': 'caution',
'gefahr': 'danger',
'fehler': 'error',
'hinweis': 'hint',
'wichtig': 'important',
'notiz': 'note',
'tipp': 'tip',
'warnung': 'warning',
'ermahnung': 'admonition',
'kasten': 'sidebar',
'seitenkasten': 'sidebar',
'thema': 'topic',
'zeilen-block': 'line-block',
'parsed-literal (translation required)': 'parsed-literal',
'rubrik': 'rubric',
'epigraph': 'epigraph',
'highlights (translation required)': 'highlights',
'pull-quote (translation required)': 'pull-quote', # kasten too ?
'zusammengesetzt': 'compound',
'verbund': 'compound',
u'container (translation required)': 'container',
#'fragen': 'questions',
'tabelle': 'table',
'csv-tabelle': 'csv-table',
'list-table (translation required)': 'list-table',
'meta': 'meta',
#'imagemap': 'imagemap',
'bild': 'image',
'abbildung': 'figure',
u'unver\xe4ndert': 'raw',
u'roh': 'raw',
u'einf\xfcgen': 'include',
'ersetzung': 'replace',
'ersetzen': 'replace',
'ersetze': 'replace',
'unicode': 'unicode',
'datum': 'date',
'klasse': 'class',
'rolle': 'role',
u'default-role (translation required)': 'default-role',
u'title (translation required)': 'title',
'inhalt': 'contents',
'kapitel-nummerierung': 'sectnum',
'abschnitts-nummerierung': 'sectnum',
u'linkziel-fu\xdfnoten': 'target-notes',
u'header (translation required)': 'header',
u'footer (translation required)': 'footer',
#u'fu\xdfnoten': 'footnotes',
#'zitate': 'citations',
}
"""German name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
u'abk\xfcrzung': 'abbreviation',
'akronym': 'acronym',
'index': 'index',
'tiefgestellt': 'subscript',
'hochgestellt': 'superscript',
'titel-referenz': 'title-reference',
'pep-referenz': 'pep-reference',
'rfc-referenz': 'rfc-reference',
'betonung': 'emphasis',
'fett': 'strong',
u'w\xf6rtlich': 'literal',
'benannte-referenz': 'named-reference',
'unbenannte-referenz': 'anonymous-reference',
u'fu\xdfnoten-referenz': 'footnote-reference',
'zitat-referenz': 'citation-reference',
'ersetzungs-referenz': 'substitution-reference',
'ziel': 'target',
'uri-referenz': 'uri-reference',
u'unver\xe4ndert': 'raw',
u'roh': 'raw',}
"""Mapping of German role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,104 @@
# $Id: en.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
English-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
# language-dependent: fixed
'attention': 'attention',
'caution': 'caution',
'danger': 'danger',
'error': 'error',
'hint': 'hint',
'important': 'important',
'note': 'note',
'tip': 'tip',
'warning': 'warning',
'admonition': 'admonition',
'sidebar': 'sidebar',
'topic': 'topic',
'line-block': 'line-block',
'parsed-literal': 'parsed-literal',
'rubric': 'rubric',
'epigraph': 'epigraph',
'highlights': 'highlights',
'pull-quote': 'pull-quote',
'compound': 'compound',
'container': 'container',
#'questions': 'questions',
'table': 'table',
'csv-table': 'csv-table',
'list-table': 'list-table',
#'qa': 'questions',
#'faq': 'questions',
'meta': 'meta',
#'imagemap': 'imagemap',
'image': 'image',
'figure': 'figure',
'include': 'include',
'raw': 'raw',
'replace': 'replace',
'unicode': 'unicode',
'date': 'date',
'class': 'class',
'role': 'role',
'default-role': 'default-role',
'title': 'title',
'contents': 'contents',
'sectnum': 'sectnum',
'section-numbering': 'sectnum',
'header': 'header',
'footer': 'footer',
#'footnotes': 'footnotes',
#'citations': 'citations',
'target-notes': 'target-notes',
'restructuredtext-test-directive': 'restructuredtext-test-directive'}
"""English name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
# language-dependent: fixed
'abbreviation': 'abbreviation',
'ab': 'abbreviation',
'acronym': 'acronym',
'ac': 'acronym',
'index': 'index',
'i': 'index',
'subscript': 'subscript',
'sub': 'subscript',
'superscript': 'superscript',
'sup': 'superscript',
'title-reference': 'title-reference',
'title': 'title-reference',
't': 'title-reference',
'pep-reference': 'pep-reference',
'pep': 'pep-reference',
'rfc-reference': 'rfc-reference',
'rfc': 'rfc-reference',
'emphasis': 'emphasis',
'strong': 'strong',
'literal': 'literal',
'named-reference': 'named-reference',
'anonymous-reference': 'anonymous-reference',
'footnote-reference': 'footnote-reference',
'citation-reference': 'citation-reference',
'substitution-reference': 'substitution-reference',
'target': 'target',
'uri-reference': 'uri-reference',
'uri': 'uri-reference',
'url': 'uri-reference',
'raw': 'raw',}
"""Mapping of English role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,114 @@
# $Id: eo.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: Marcelo Huerta San Martin <richieadler@users.sourceforge.net>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Esperanto-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
# language-dependent: fixed
u'atentu': 'attention',
u'zorgu': 'caution',
u'dangxero': 'danger',
u'dan\u011dero': 'danger',
u'eraro': 'error',
u'spuro': 'hint',
u'grava': 'important',
u'noto': 'note',
u'helpeto': 'tip',
u'averto': 'warning',
u'admono': 'admonition',
u'flankteksto': 'sidebar',
u'temo': 'topic',
u'linea-bloko': 'line-block',
u'analizota-literalo': 'parsed-literal',
u'rubriko': 'rubric',
u'epigrafo': 'epigraph',
u'elstarajxoj': 'highlights',
u'elstara\u0135oj': 'highlights',
u'ekstera-citajxo': 'pull-quote',
u'ekstera-cita\u0135o': 'pull-quote',
u'kombinajxo': 'compound',
u'kombina\u0135o': 'compound',
u'tekstingo': 'container',
u'enhavilo': 'container',
#'questions': 'questions',
#'qa': 'questions',
#'faq': 'questions',
u'tabelo': 'table',
u'tabelo-vdk': 'csv-table', # "valoroj disigitaj per komoj"
u'tabelo-csv': 'csv-table',
u'tabelo-lista': 'list-table',
u'meta': 'meta',
#'imagemap': 'imagemap',
u'bildo': 'image',
u'figuro': 'figure',
u'inkludi': 'include',
u'senanaliza': 'raw',
u'anstatauxi': 'replace',
u'anstata\u016di': 'replace',
u'unicode': 'unicode',
u'dato': 'date',
u'klaso': 'class',
u'rolo': 'role',
u'preterlasita-rolo': 'default-role',
u'titolo': 'title',
u'enhavo': 'contents',
u'seknum': 'sectnum',
u'sekcia-numerado': 'sectnum',
u'kapsekcio': 'header',
u'piedsekcio': 'footer',
#'footnotes': 'footnotes',
#'citations': 'citations',
u'celaj-notoj': 'target-notes',
u'restructuredtext-test-directive': 'restructuredtext-test-directive'}
"""Esperanto name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
# language-dependent: fixed
u'mallongigo': 'abbreviation',
u'mall': 'abbreviation',
u'komenclitero': 'acronym',
u'kl': 'acronym',
u'indekso': 'index',
u'i': 'index',
u'subskribo': 'subscript',
u'sub': 'subscript',
u'supraskribo': 'superscript',
u'sup': 'superscript',
u'titola-referenco': 'title-reference',
u'titolo': 'title-reference',
u't': 'title-reference',
u'pep-referenco': 'pep-reference',
u'pep': 'pep-reference',
u'rfc-referenco': 'rfc-reference',
u'rfc': 'rfc-reference',
u'emfazo': 'emphasis',
u'forta': 'strong',
u'litera': 'literal',
u'nomita-referenco': 'named-reference',
u'nenomita-referenco': 'anonymous-reference',
u'piednota-referenco': 'footnote-reference',
u'citajxo-referenco': 'citation-reference',
u'cita\u0135o-referenco': 'citation-reference',
u'anstatauxa-referenco': 'substitution-reference',
u'anstata\u016da-referenco': 'substitution-reference',
u'celo': 'target',
u'uri-referenco': 'uri-reference',
u'uri': 'uri-reference',
u'url': 'uri-reference',
u'senanaliza': 'raw',
}
"""Mapping of Esperanto role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,121 @@
# -*- coding: utf-8 -*-
# $Id: es.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: Marcelo Huerta San Martín <richieadler@users.sourceforge.net>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Spanish-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
u'atenci\u00f3n': 'attention',
u'atencion': 'attention',
u'precauci\u00f3n': 'caution',
u'precaucion': 'caution',
u'peligro': 'danger',
u'error': 'error',
u'sugerencia': 'hint',
u'importante': 'important',
u'nota': 'note',
u'consejo': 'tip',
u'advertencia': 'warning',
u'exhortacion': 'admonition',
u'exhortaci\u00f3n': 'admonition',
u'nota-al-margen': 'sidebar',
u'tema': 'topic',
u'bloque-de-lineas': 'line-block',
u'bloque-de-l\u00edneas': 'line-block',
u'literal-evaluado': 'parsed-literal',
u'firma': 'rubric',
u'ep\u00edgrafe': 'epigraph',
u'epigrafe': 'epigraph',
u'destacado': 'highlights',
u'cita-destacada': 'pull-quote',
u'combinacion': 'compound',
u'combinaci\u00f3n': 'compound',
u'contenedor': 'container',
#'questions': 'questions',
#'qa': 'questions',
#'faq': 'questions',
u'tabla': 'table',
u'tabla-vsc': 'csv-table',
u'tabla-csv': 'csv-table',
u'tabla-lista': 'list-table',
u'meta': 'meta',
#'imagemap': 'imagemap',
u'imagen': 'image',
u'figura': 'figure',
u'incluir': 'include',
u'sin-analisis': 'raw',
u'sin-an\u00e1lisis': 'raw',
u'reemplazar': 'replace',
u'unicode': 'unicode',
u'fecha': 'date',
u'clase': 'class',
u'rol': 'role',
u'rol-por-omision': 'default-role',
u'rol-por-omisi\u00f3n': 'default-role',
u'titulo': 'title',
u't\u00edtulo': 'title',
u'contenido': 'contents',
u'numseccion': 'sectnum',
u'numsecci\u00f3n': 'sectnum',
u'numeracion-seccion': 'sectnum',
u'numeraci\u00f3n-secci\u00f3n': 'sectnum',
u'notas-destino': 'target-notes',
u'cabecera': 'header',
u'pie': 'footer',
#'footnotes': 'footnotes',
#'citations': 'citations',
u'restructuredtext-test-directive': 'restructuredtext-test-directive'}
"""Spanish name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
u'abreviatura': 'abbreviation',
u'ab': 'abbreviation',
u'acronimo': 'acronym',
u'acronimo': 'acronym',
u'ac': 'acronym',
u'indice': 'index',
u'i': 'index',
u'subindice': 'subscript',
u'sub\u00edndice': 'subscript',
u'superindice': 'superscript',
u'super\u00edndice': 'superscript',
u'referencia-titulo': 'title-reference',
u'titulo': 'title-reference',
u't': 'title-reference',
u'referencia-pep': 'pep-reference',
u'pep': 'pep-reference',
u'referencia-rfc': 'rfc-reference',
u'rfc': 'rfc-reference',
u'enfasis': 'emphasis',
u'\u00e9nfasis': 'emphasis',
u'destacado': 'strong',
u'literal': 'literal', # "literal" is also a word in Spanish :-)
u'referencia-con-nombre': 'named-reference',
u'referencia-anonima': 'anonymous-reference',
u'referencia-an\u00f3nima': 'anonymous-reference',
u'referencia-nota-al-pie': 'footnote-reference',
u'referencia-cita': 'citation-reference',
u'referencia-sustitucion': 'substitution-reference',
u'referencia-sustituci\u00f3n': 'substitution-reference',
u'destino': 'target',
u'referencia-uri': 'uri-reference',
u'uri': 'uri-reference',
u'url': 'uri-reference',
u'sin-analisis': 'raw',
u'sin-an\u00e1lisis': 'raw',
}
"""Mapping of Spanish role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,93 @@
# $Id: fi.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: Asko Soukka <asko.soukka@iki.fi>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Finnish-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
# language-dependent: fixed
u'huomio': u'attention',
u'varo': u'caution',
u'vaara': u'danger',
u'virhe': u'error',
u'vihje': u'hint',
u't\u00e4rke\u00e4\u00e4': u'important',
u'huomautus': u'note',
u'neuvo': u'tip',
u'varoitus': u'warning',
u'kehotus': u'admonition',
u'sivupalkki': u'sidebar',
u'aihe': u'topic',
u'rivi': u'line-block',
u'tasalevyinen': u'parsed-literal',
u'ohje': u'rubric',
u'epigraafi': u'epigraph',
u'kohokohdat': u'highlights',
u'lainaus': u'pull-quote',
u'taulukko': u'table',
u'csv-taulukko': u'csv-table',
u'list-table (translation required)': 'list-table',
u'compound (translation required)': 'compound',
u'container (translation required)': 'container',
#u'kysymykset': u'questions',
u'meta': u'meta',
#u'kuvakartta': u'imagemap',
u'kuva': u'image',
u'kaavio': u'figure',
u'sis\u00e4llyt\u00e4': u'include',
u'raaka': u'raw',
u'korvaa': u'replace',
u'unicode': u'unicode',
u'p\u00e4iv\u00e4ys': u'date',
u'luokka': u'class',
u'rooli': u'role',
u'default-role (translation required)': 'default-role',
u'title (translation required)': 'title',
u'sis\u00e4llys': u'contents',
u'kappale': u'sectnum',
u'header (translation required)': 'header',
u'footer (translation required)': 'footer',
#u'alaviitteet': u'footnotes',
#u'viitaukset': u'citations',
u'target-notes (translation required)': u'target-notes'}
"""Finnish name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
# language-dependent: fixed
u'lyhennys': u'abbreviation',
u'akronyymi': u'acronym',
u'kirjainsana': u'acronym',
u'hakemisto': u'index',
u'luettelo': u'index',
u'alaindeksi': u'subscript',
u'indeksi': u'subscript',
u'yl\u00e4indeksi': u'superscript',
u'title-reference (translation required)': u'title-reference',
u'title (translation required)': u'title-reference',
u'pep-reference (translation required)': u'pep-reference',
u'rfc-reference (translation required)': u'rfc-reference',
u'korostus': u'emphasis',
u'vahvistus': u'strong',
u'tasalevyinen': u'literal',
u'named-reference (translation required)': u'named-reference',
u'anonymous-reference (translation required)': u'anonymous-reference',
u'footnote-reference (translation required)': u'footnote-reference',
u'citation-reference (translation required)': u'citation-reference',
u'substitution-reference (translation required)': u'substitution-reference',
u'kohde': u'target',
u'uri-reference (translation required)': u'uri-reference',
u'raw (translation required)': 'raw',}
"""Mapping of Finnish role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,99 @@
# $Id: fr.py 4564 2006-05-21 20:44:42Z wiemann $
# Authors: David Goodger <goodger@python.org>; William Dode
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
French-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
u'attention': 'attention',
u'pr\u00E9caution': 'caution',
u'danger': 'danger',
u'erreur': 'error',
u'conseil': 'hint',
u'important': 'important',
u'note': 'note',
u'astuce': 'tip',
u'avertissement': 'warning',
u'admonition': 'admonition',
u'encadr\u00E9': 'sidebar',
u'sujet': 'topic',
u'bloc-textuel': 'line-block',
u'bloc-interpr\u00E9t\u00E9': 'parsed-literal',
u'code-interpr\u00E9t\u00E9': 'parsed-literal',
u'intertitre': 'rubric',
u'exergue': 'epigraph',
u'\u00E9pigraphe': 'epigraph',
u'chapeau': 'highlights',
u'accroche': 'pull-quote',
u'compound (translation required)': 'compound',
u'container (translation required)': 'container',
#u'questions': 'questions',
#u'qr': 'questions',
#u'faq': 'questions',
u'tableau': 'table',
u'csv-table (translation required)': 'csv-table',
u'list-table (translation required)': 'list-table',
u'm\u00E9ta': 'meta',
#u'imagemap (translation required)': 'imagemap',
u'image': 'image',
u'figure': 'figure',
u'inclure': 'include',
u'brut': 'raw',
u'remplacer': 'replace',
u'remplace': 'replace',
u'unicode': 'unicode',
u'date': 'date',
u'classe': 'class',
u'role (translation required)': 'role',
u'default-role (translation required)': 'default-role',
u'titre (translation required)': 'title',
u'sommaire': 'contents',
u'table-des-mati\u00E8res': 'contents',
u'sectnum': 'sectnum',
u'section-num\u00E9rot\u00E9e': 'sectnum',
u'liens': 'target-notes',
u'header (translation required)': 'header',
u'footer (translation required)': 'footer',
#u'footnotes (translation required)': 'footnotes',
#u'citations (translation required)': 'citations',
}
"""French name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
u'abr\u00E9viation': 'abbreviation',
u'acronyme': 'acronym',
u'sigle': 'acronym',
u'index': 'index',
u'indice': 'subscript',
u'ind': 'subscript',
u'exposant': 'superscript',
u'exp': 'superscript',
u'titre-r\u00E9f\u00E9rence': 'title-reference',
u'titre': 'title-reference',
u'pep-r\u00E9f\u00E9rence': 'pep-reference',
u'rfc-r\u00E9f\u00E9rence': 'rfc-reference',
u'emphase': 'emphasis',
u'fort': 'strong',
u'litt\u00E9ral': 'literal',
u'nomm\u00E9e-r\u00E9f\u00E9rence': 'named-reference',
u'anonyme-r\u00E9f\u00E9rence': 'anonymous-reference',
u'note-r\u00E9f\u00E9rence': 'footnote-reference',
u'citation-r\u00E9f\u00E9rence': 'citation-reference',
u'substitution-r\u00E9f\u00E9rence': 'substitution-reference',
u'lien': 'target',
u'uri-r\u00E9f\u00E9rence': 'uri-reference',
u'brut': 'raw',}
"""Mapping of French role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,107 @@
# -*- coding: utf-8 -*-
# Author: David Goodger
# Contact: goodger@users.sourceforge.net
# Revision: $Revision: 4229 $
# Date: $Date: 2005-12-23 00:46:16 +0100 (Fri, 23 Dec 2005) $
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Galician-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
# language-dependent: fixed
u'atenci\u00f3n': 'attention',
u'advertencia': 'caution',
u'perigo': 'danger',
u'erro': 'error',
u'pista': 'hint',
u'importante': 'important',
u'nota': 'note',
u'consello': 'tip',
u'aviso': 'warning',
u'admonici\u00f3n': 'admonition',
u'barra lateral': 'sidebar',
u't\u00f3pico': 'topic',
u'bloque-li\u00f1a': 'line-block',
u'literal-analizado': 'parsed-literal',
u'r\u00fabrica': 'rubric',
u'ep\u00edgrafe': 'epigraph',
u'realzados': 'highlights',
u'coller-citaci\u00f3n': 'pull-quote',
u'compor': 'compound',
u'recipiente': 'container',
#'questions': 'questions',
u't\u00e1boa': 'table',
u't\u00e1boa-csv': 'csv-table',
u't\u00e1boa-listaxe': 'list-table',
#'qa': 'questions',
#'faq': 'questions',
u'meta': 'meta',
#'imagemap': 'imagemap',
u'imaxe': 'image',
u'figura': 'figure',
u'inclu\u00edr': 'include',
u'cru': 'raw',
u'substitu\u00edr': 'replace',
u'unicode': 'unicode',
u'data': 'date',
u'clase': 'class',
u'regra': 'role',
u'regra-predeterminada': 'default-role',
u't\u00edtulo': 'title',
u'contido': 'contents',
u'seccnum': 'sectnum',
u'secci\u00f3n-numerar': 'sectnum',
u'cabeceira': 'header',
u'p\u00e9 de p\u00e1xina': 'footer',
#'footnotes': 'footnotes',
#'citations': 'citations',
u'notas-destino': 'target-notes',
u'texto restruturado-proba-directiva': 'restructuredtext-test-directive'}
"""Galician name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
# language-dependent: fixed
u'abreviatura': 'abbreviation',
u'ab': 'abbreviation',
u'acr\u00f3nimo': 'acronym',
u'ac': 'acronym',
u'\u00edndice': 'index',
u'i': 'index',
u'sub\u00edndice': 'subscript',
u'sub': 'subscript',
u'super\u00edndice': 'superscript',
u'sup': 'superscript',
u'referencia t\u00edtulo': 'title-reference',
u't\u00edtulo': 'title-reference',
u't': 'title-reference',
u'referencia-pep': 'pep-reference',
u'pep': 'pep-reference',
u'referencia-rfc': 'rfc-reference',
u'rfc': 'rfc-reference',
u'\u00e9nfase': 'emphasis',
u'forte': 'strong',
u'literal': 'literal',
u'referencia-nome': 'named-reference',
u'referencia-an\u00f3nimo': 'anonymous-reference',
u'referencia-nota ao p\u00e9': 'footnote-reference',
u'referencia-citaci\u00f3n': 'citation-reference',
u'referencia-substituci\u00f3n': 'substitution-reference',
u'destino': 'target',
u'referencia-uri': 'uri-reference',
u'uri': 'uri-reference',
u'url': 'uri-reference',
u'cru': 'raw',}
"""Mapping of Galician role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,104 @@
# Author: Meir Kriheli
# Id: $Id: he.py 4837 2006-12-26 09:59:41Z sfcben $
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
English-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
# language-dependent: fixed
u'\u05ea\u05e9\u05d5\u05de\u05ea \u05dc\u05d1': 'attention',
u'\u05d6\u05d4\u05d9\u05e8\u05d5\u05ea': 'caution',
u'\u05e1\u05db\u05e0\u05d4': 'danger',
u'\u05e9\u05d2\u05d9\u05d0\u05d4' : 'error',
u'\u05e8\u05de\u05d6': 'hint',
u'\u05d7\u05e9\u05d5\u05d1': 'important',
u'\u05d4\u05e2\u05e8\u05d4': 'note',
u'\u05d8\u05d9\u05e4': 'tip',
u'\u05d0\u05d6\u05d4\u05e8\u05d4': 'warning',
'admonition': 'admonition',
'sidebar': 'sidebar',
'topic': 'topic',
'line-block': 'line-block',
'parsed-literal': 'parsed-literal',
'rubric': 'rubric',
'epigraph': 'epigraph',
'highlights': 'highlights',
'pull-quote': 'pull-quote',
'compound': 'compound',
'container': 'container',
#'questions': 'questions',
'table': 'table',
'csv-table': 'csv-table',
'list-table': 'list-table',
#'qa': 'questions',
#'faq': 'questions',
'meta': 'meta',
#'imagemap': 'imagemap',
u'\u05ea\u05de\u05d5\u05e0\u05d4': 'image',
'figure': 'figure',
'include': 'include',
'raw': 'raw',
'replace': 'replace',
'unicode': 'unicode',
'date': 'date',
u'\u05e1\u05d2\u05e0\u05d5\u05df': 'class',
'role': 'role',
'default-role': 'default-role',
'title': 'title',
u'\u05ea\u05d5\u05db\u05df': 'contents',
'sectnum': 'sectnum',
'section-numbering': 'sectnum',
'header': 'header',
'footer': 'footer',
#'footnotes': 'footnotes',
#'citations': 'citations',
'target-notes': 'target-notes',
'restructuredtext-test-directive': 'restructuredtext-test-directive'}
"""English name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
# language-dependent: fixed
'abbreviation': 'abbreviation',
'ab': 'abbreviation',
'acronym': 'acronym',
'ac': 'acronym',
'index': 'index',
'i': 'index',
u'\u05ea\u05d7\u05ea\u05d9': 'subscript',
'sub': 'subscript',
u'\u05e2\u05d9\u05dc\u05d9': 'superscript',
'sup': 'superscript',
'title-reference': 'title-reference',
'title': 'title-reference',
't': 'title-reference',
'pep-reference': 'pep-reference',
'pep': 'pep-reference',
'rfc-reference': 'rfc-reference',
'rfc': 'rfc-reference',
'emphasis': 'emphasis',
'strong': 'strong',
'literal': 'literal',
'named-reference': 'named-reference',
'anonymous-reference': 'anonymous-reference',
'footnote-reference': 'footnote-reference',
'citation-reference': 'citation-reference',
'substitution-reference': 'substitution-reference',
'target': 'target',
'uri-reference': 'uri-reference',
'uri': 'uri-reference',
'url': 'uri-reference',
'raw': 'raw',}
"""Mapping of English role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,93 @@
# $Id: it.py 4564 2006-05-21 20:44:42Z wiemann $
# Authors: Nicola Larosa <docutils@tekNico.net>;
# Lele Gaifax <lele@seldati.it>
# Copyright: This module has been placed in the public domain.
# Beware: the italian translation of the reStructuredText documentation
# at http://docit.bice.dyndns.org/static/ReST, in particular
# http://docit.bice.dyndns.org/static/ReST/ref/rst/directives.html, needs
# to be synced with the content of this file.
"""
Italian-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
'attenzione': 'attention',
'cautela': 'caution',
'pericolo': 'danger',
'errore': 'error',
'suggerimento': 'hint',
'importante': 'important',
'nota': 'note',
'consiglio': 'tip',
'avvertenza': 'warning',
'ammonizione': 'admonition',
'riquadro': 'sidebar',
'argomento': 'topic',
'blocco-di-righe': 'line-block',
'blocco-interpretato': 'parsed-literal',
'rubrica': 'rubric',
'epigrafe': 'epigraph',
'punti-salienti': 'highlights',
'estratto-evidenziato': 'pull-quote',
'composito': 'compound',
u'container (translation required)': 'container',
#'questions': 'questions',
#'qa': 'questions',
#'faq': 'questions',
'tabella': 'table',
'tabella-csv': 'csv-table',
'tabella-elenco': 'list-table',
'meta': 'meta',
#'imagemap': 'imagemap',
'immagine': 'image',
'figura': 'figure',
'includi': 'include',
'grezzo': 'raw',
'sostituisci': 'replace',
'unicode': 'unicode',
'data': 'date',
'classe': 'class',
'ruolo': 'role',
'ruolo-predefinito': 'default-role',
'titolo': 'title',
'indice': 'contents',
'contenuti': 'contents',
'seznum': 'sectnum',
'sezioni-autonumerate': 'sectnum',
'annota-riferimenti-esterni': 'target-notes',
'intestazione': 'header',
'piede-pagina': 'footer',
#'footnotes': 'footnotes',
#'citations': 'citations',
'restructuredtext-test-directive': 'restructuredtext-test-directive'}
"""Italian name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
'abbreviazione': 'abbreviation',
'acronimo': 'acronym',
'indice': 'index',
'deponente': 'subscript',
'esponente': 'superscript',
'riferimento-titolo': 'title-reference',
'riferimento-pep': 'pep-reference',
'riferimento-rfc': 'rfc-reference',
'enfasi': 'emphasis',
'forte': 'strong',
'letterale': 'literal',
'riferimento-con-nome': 'named-reference',
'riferimento-anonimo': 'anonymous-reference',
'riferimento-nota': 'footnote-reference',
'riferimento-citazione': 'citation-reference',
'riferimento-sostituzione': 'substitution-reference',
'destinazione': 'target',
'riferimento-uri': 'uri-reference',
'grezzo': 'raw',}
"""Mapping of Italian role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,115 @@
# -*- coding: utf-8 -*-
# $Id: ja.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Japanese-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
# Corrections to these translations are welcome!
# 間違いがあれば、どうぞ正しい翻訳を教えて下さい。
directives = {
# language-dependent: fixed
u'注目': 'attention',
u'注意': 'caution',
u'危険': 'danger',
u'エラー': 'error',
u'ヒント': 'hint',
u'重要': 'important',
u'備考': 'note',
u'通報': 'tip',
u'警告': 'warning',
u'戒告': 'admonition',
u'サイドバー': 'sidebar',
u'トピック': 'topic',
u'ラインブロック': 'line-block',
u'パーズドリテラル': 'parsed-literal',
u'ルブリック': 'rubric',
u'エピグラフ': 'epigraph',
u'題言': 'epigraph',
u'ハイライト': 'highlights',
u'見所': 'highlights',
u'プルクオート': 'pull-quote',
u'合成': 'compound',
u'コンテナー': 'container',
u'容器': 'container',
u'表': 'table',
u'csv表': 'csv-table',
u'リスト表': 'list-table',
#u'質問': 'questions',
#u'問答': 'questions',
#u'faq': 'questions',
u'メタ': 'meta',
#u'イメージマプ': 'imagemap',
u'イメージ': 'image',
u'画像': 'image',
u'フィグア': 'figure',
u'図版': 'figure',
u'インクルード': 'include',
u'含む': 'include',
u'組み込み': 'include',
u'生': 'raw',
u'原': 'raw',
u'換える': 'replace',
u'取り換える': 'replace',
u'掛け替える': 'replace',
u'ユニコード': 'unicode',
u'日付': 'date',
u'クラス': 'class',
u'ロール': 'role',
u'役': 'role',
u'ディフォルトロール': 'default-role',
u'既定役': 'default-role',
u'タイトル': 'title',
u'題': 'title', # 題名 件名
u'目次': 'contents',
u'節数': 'sectnum',
u'ヘッダ': 'header',
u'フッタ': 'footer',
#u'脚注': 'footnotes', # 脚註?
#u'サイテーション': 'citations',   # 出典 引証 引用
u'ターゲットノート': 'target-notes', # 的注 的脚注
}
"""Japanese name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
# language-dependent: fixed
u'略': 'abbreviation',
u'頭字語': 'acronym',
u'インデックス': 'index',
u'索引': 'index',
u'添字': 'subscript',
u'下付': 'subscript',
u'下': 'subscript',
u'上付': 'superscript',
u'上': 'superscript',
u'題参照': 'title-reference',
u'pep参照': 'pep-reference',
u'rfc参照': 'rfc-reference',
u'強調': 'emphasis',
u'強い': 'strong',
u'リテラル': 'literal',
u'整形済み': 'literal',
u'名付参照': 'named-reference',
u'無名参照': 'anonymous-reference',
u'脚注参照': 'footnote-reference',
u'出典参照': 'citation-reference',
u'代入参照': 'substitution-reference',
u'的': 'target',
u'uri参照': 'uri-reference',
u'uri': 'uri-reference',
u'url': 'uri-reference',
u'生': 'raw',}
"""Mapping of Japanese role names to canonical role names for interpreted
text."""
@@ -0,0 +1,108 @@
# $Id: nl.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: Martijn Pieters <mjpieters@users.sourceforge.net>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Dutch-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
# language-dependent: fixed
'attentie': 'attention',
'let-op': 'caution',
'gevaar': 'danger',
'fout': 'error',
'hint': 'hint',
'belangrijk': 'important',
'opmerking': 'note',
'tip': 'tip',
'waarschuwing': 'warning',
'aanmaning': 'admonition',
'katern': 'sidebar',
'onderwerp': 'topic',
'lijn-blok': 'line-block',
'letterlijk-ontleed': 'parsed-literal',
'rubriek': 'rubric',
'opschrift': 'epigraph',
'hoogtepunten': 'highlights',
'pull-quote': 'pull-quote', # Dutch printers use the english term
'samenstelling': 'compound',
'verbinding': 'compound',
u'container (translation required)': 'container',
#'vragen': 'questions',
'tabel': 'table',
'csv-tabel': 'csv-table',
'lijst-tabel': 'list-table',
#'veelgestelde-vragen': 'questions',
'meta': 'meta',
#'imagemap': 'imagemap',
'beeld': 'image',
'figuur': 'figure',
'opnemen': 'include',
'onbewerkt': 'raw',
'vervang': 'replace',
'vervanging': 'replace',
'unicode': 'unicode',
'datum': 'date',
'klasse': 'class',
'rol': 'role',
u'default-role (translation required)': 'default-role',
'title (translation required)': 'title',
'inhoud': 'contents',
'sectnum': 'sectnum',
'sectie-nummering': 'sectnum',
'hoofdstuk-nummering': 'sectnum',
u'header (translation required)': 'header',
u'footer (translation required)': 'footer',
#'voetnoten': 'footnotes',
#'citaten': 'citations',
'verwijzing-voetnoten': 'target-notes',
'restructuredtext-test-instructie': 'restructuredtext-test-directive'}
"""Dutch name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
# language-dependent: fixed
'afkorting': 'abbreviation',
# 'ab': 'abbreviation',
'acroniem': 'acronym',
'ac': 'acronym',
'index': 'index',
'i': 'index',
'inferieur': 'subscript',
'inf': 'subscript',
'superieur': 'superscript',
'sup': 'superscript',
'titel-referentie': 'title-reference',
'titel': 'title-reference',
't': 'title-reference',
'pep-referentie': 'pep-reference',
'pep': 'pep-reference',
'rfc-referentie': 'rfc-reference',
'rfc': 'rfc-reference',
'nadruk': 'emphasis',
'extra': 'strong',
'extra-nadruk': 'strong',
'vet': 'strong',
'letterlijk': 'literal',
'benoemde-referentie': 'named-reference',
'anonieme-referentie': 'anonymous-reference',
'voetnoot-referentie': 'footnote-reference',
'citaat-referentie': 'citation-reference',
'substitie-reference': 'substitution-reference',
'verwijzing': 'target',
'uri-referentie': 'uri-reference',
'uri': 'uri-reference',
'url': 'uri-reference',
'onbewerkt': 'raw',}
"""Mapping of Dutch role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,98 @@
# $Id$
# Author: Robert Wojciechowicz <rw@smsnet.pl>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Polish-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
# language-dependent: fixed
u'uwaga': 'attention',
u'ostro\u017cnie': 'caution',
u'niebezpiecze\u0144stwo': 'danger',
u'b\u0142\u0105d': 'error',
u'wskaz\u00f3wka': 'hint',
u'wa\u017cne': 'important',
u'przypis': 'note',
u'rada': 'tip',
u'ostrze\u017cenie': 'warning',
u'upomnienie': 'admonition',
u'ramka': 'sidebar',
u'temat': 'topic',
u'blok-linii': 'line-block',
u'sparsowany-litera\u0142': 'parsed-literal',
u'rubryka': 'rubric',
u'epigraf': 'epigraph',
u'highlights': 'highlights', # FIXME no polish equivalent?
u'pull-quote': 'pull-quote', # FIXME no polish equivalent?
u'z\u0142o\u017cony': 'compound',
u'kontener': 'container',
#'questions': 'questions',
u'tabela': 'table',
u'tabela-csv': 'csv-table',
u'tabela-listowa': 'list-table',
#'qa': 'questions',
#'faq': 'questions',
u'meta': 'meta',
#'imagemap': 'imagemap',
u'obraz': 'image',
u'rycina': 'figure',
u'do\u0142\u0105cz': 'include',
u'surowe': 'raw',
u'zast\u0105p': 'replace',
u'unikod': 'unicode',
u'data': 'date',
u'klasa': 'class',
u'rola': 'role',
u'rola-domy\u015blna': 'default-role',
u'tytu\u0142': 'title',
u'tre\u015b\u0107': 'contents',
u'sectnum': 'sectnum',
u'numeracja-sekcji': 'sectnum',
u'nag\u0142\u00f3wek': 'header',
u'stopka': 'footer',
#'footnotes': 'footnotes',
#'citations': 'citations',
u'target-notes': 'target-notes', # FIXME no polish equivalent?
u'restructuredtext-test-directive': 'restructuredtext-test-directive'}
"""Polish name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
# language-dependent: fixed
u'skr\u00f3t': 'abbreviation',
u'akronim': 'acronym',
u'indeks': 'index',
u'indeks-dolny': 'subscript',
u'indeks-g\u00f3rny': 'superscript',
u'referencja-tytu\u0142': 'title-reference',
u'referencja-pep': 'pep-reference',
u'referencja-rfc': 'rfc-reference',
u'podkre\u015blenie': 'emphasis',
u'wyt\u0142uszczenie': 'strong',
u'dos\u0142ownie': 'literal',
u'referencja-nazwana': 'named-reference',
u'referencja-anonimowa': 'anonymous-reference',
u'referencja-przypis': 'footnote-reference',
u'referencja-cytat': 'citation-reference',
u'referencja-podstawienie': 'substitution-reference',
u'cel': 'target',
u'referencja-uri': 'uri-reference',
u'uri': 'uri-reference',
u'url': 'uri-reference',
u'surowe': 'raw',}
"""Mapping of Polish role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,104 @@
# $Id: pt_br.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Brazilian Portuguese-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
# language-dependent: fixed
u'aten\u00E7\u00E3o': 'attention',
'cuidado': 'caution',
'perigo': 'danger',
'erro': 'error',
u'sugest\u00E3o': 'hint',
'importante': 'important',
'nota': 'note',
'dica': 'tip',
'aviso': 'warning',
u'exorta\u00E7\u00E3o': 'admonition',
'barra-lateral': 'sidebar',
u't\u00F3pico': 'topic',
'bloco-de-linhas': 'line-block',
'literal-interpretado': 'parsed-literal',
'rubrica': 'rubric',
u'ep\u00EDgrafo': 'epigraph',
'destaques': 'highlights',
u'cita\u00E7\u00E3o-destacada': 'pull-quote',
u'compound (translation required)': 'compound',
u'container (translation required)': 'container',
#'perguntas': 'questions',
#'qa': 'questions',
#'faq': 'questions',
u'table (translation required)': 'table',
u'csv-table (translation required)': 'csv-table',
u'list-table (translation required)': 'list-table',
'meta': 'meta',
#'imagemap': 'imagemap',
'imagem': 'image',
'figura': 'figure',
u'inclus\u00E3o': 'include',
'cru': 'raw',
u'substitui\u00E7\u00E3o': 'replace',
'unicode': 'unicode',
'data': 'date',
'classe': 'class',
'role (translation required)': 'role',
u'default-role (translation required)': 'default-role',
u'title (translation required)': 'title',
u'\u00EDndice': 'contents',
'numsec': 'sectnum',
u'numera\u00E7\u00E3o-de-se\u00E7\u00F5es': 'sectnum',
u'header (translation required)': 'header',
u'footer (translation required)': 'footer',
#u'notas-de-rorap\u00E9': 'footnotes',
#u'cita\u00E7\u00F5es': 'citations',
u'links-no-rodap\u00E9': 'target-notes',
'restructuredtext-test-directive': 'restructuredtext-test-directive'}
"""Brazilian Portuguese name to registered (in directives/__init__.py)
directive name mapping."""
roles = {
# language-dependent: fixed
u'abbrevia\u00E7\u00E3o': 'abbreviation',
'ab': 'abbreviation',
u'acr\u00F4nimo': 'acronym',
'ac': 'acronym',
u'\u00EDndice-remissivo': 'index',
'i': 'index',
'subscrito': 'subscript',
'sub': 'subscript',
'sobrescrito': 'superscript',
'sob': 'superscript',
u'refer\u00EAncia-a-t\u00EDtulo': 'title-reference',
u't\u00EDtulo': 'title-reference',
't': 'title-reference',
u'refer\u00EAncia-a-pep': 'pep-reference',
'pep': 'pep-reference',
u'refer\u00EAncia-a-rfc': 'rfc-reference',
'rfc': 'rfc-reference',
u'\u00EAnfase': 'emphasis',
'forte': 'strong',
'literal': 'literal', # translation required?
u'refer\u00EAncia-por-nome': 'named-reference',
u'refer\u00EAncia-an\u00F4nima': 'anonymous-reference',
u'refer\u00EAncia-a-nota-de-rodap\u00E9': 'footnote-reference',
u'refer\u00EAncia-a-cita\u00E7\u00E3o': 'citation-reference',
u'refer\u00EAncia-a-substitui\u00E7\u00E3o': 'substitution-reference',
'alvo': 'target',
u'refer\u00EAncia-a-uri': 'uri-reference',
'uri': 'uri-reference',
'url': 'uri-reference',
'cru': 'raw',}
"""Mapping of Brazilian Portuguese role names to canonical role names
for interpreted text."""
@@ -0,0 +1,103 @@
# $Id: ru.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: Roman Suzi <rnd@onego.ru>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Russian-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
u'\u0431\u043b\u043e\u043a-\u0441\u0442\u0440\u043e\u043a': u'line-block',
u'meta': u'meta',
u'\u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0430\u043d\u043d\u044b\u0439-\u043b\u0438\u0442\u0435\u0440\u0430\u043b':
u'parsed-literal',
u'\u0432\u044b\u0434\u0435\u043b\u0435\u043d\u043d\u0430\u044f-\u0446\u0438\u0442\u0430\u0442\u0430':
u'pull-quote',
u'compound (translation required)': 'compound',
u'container (translation required)': 'container',
u'table (translation required)': 'table',
u'csv-table (translation required)': 'csv-table',
u'list-table (translation required)': 'list-table',
u'\u0441\u044b\u0440\u043e\u0439': u'raw',
u'\u0437\u0430\u043c\u0435\u043d\u0430': u'replace',
u'\u0442\u0435\u0441\u0442\u043e\u0432\u0430\u044f-\u0434\u0438\u0440\u0435\u043a\u0442\u0438\u0432\u0430-restructuredtext':
u'restructuredtext-test-directive',
u'\u0446\u0435\u043b\u0435\u0432\u044b\u0435-\u0441\u043d\u043e\u0441\u043a\u0438':
u'target-notes',
u'unicode': u'unicode',
u'\u0434\u0430\u0442\u0430': u'date',
u'\u0431\u043e\u043a\u043e\u0432\u0430\u044f-\u043f\u043e\u043b\u043e\u0441\u0430':
u'sidebar',
u'\u0432\u0430\u0436\u043d\u043e': u'important',
u'\u0432\u043a\u043b\u044e\u0447\u0430\u0442\u044c': u'include',
u'\u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435': u'attention',
u'\u0432\u044b\u0434\u0435\u043b\u0435\u043d\u0438\u0435': u'highlights',
u'\u0437\u0430\u043c\u0435\u0447\u0430\u043d\u0438\u0435': u'admonition',
u'\u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435':
u'image',
u'\u043a\u043b\u0430\u0441\u0441': u'class',
u'role (translation required)': 'role',
u'default-role (translation required)': 'default-role',
u'title (translation required)': 'title',
u'\u043d\u043e\u043c\u0435\u0440-\u0440\u0430\u0437\u0434\u0435\u043b\u0430':
u'sectnum',
u'\u043d\u0443\u043c\u0435\u0440\u0430\u0446\u0438\u044f-\u0440\u0430\u0437'
u'\u0434\u0435\u043b\u043e\u0432': u'sectnum',
u'\u043e\u043f\u0430\u0441\u043d\u043e': u'danger',
u'\u043e\u0441\u0442\u043e\u0440\u043e\u0436\u043d\u043e': u'caution',
u'\u043e\u0448\u0438\u0431\u043a\u0430': u'error',
u'\u043f\u043e\u0434\u0441\u043a\u0430\u0437\u043a\u0430': u'tip',
u'\u043f\u0440\u0435\u0434\u0443\u043f\u0440\u0435\u0436\u0434\u0435\u043d'
u'\u0438\u0435': u'warning',
u'\u043f\u0440\u0438\u043c\u0435\u0447\u0430\u043d\u0438\u0435': u'note',
u'\u0440\u0438\u0441\u0443\u043d\u043e\u043a': u'figure',
u'\u0440\u0443\u0431\u0440\u0438\u043a\u0430': u'rubric',
u'\u0441\u043e\u0432\u0435\u0442': u'hint',
u'\u0441\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u0435': u'contents',
u'\u0442\u0435\u043c\u0430': u'topic',
u'\u044d\u043f\u0438\u0433\u0440\u0430\u0444': u'epigraph',
u'header (translation required)': 'header',
u'footer (translation required)': 'footer',}
"""Russian name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
u'\u0430\u043a\u0440\u043e\u043d\u0438\u043c': 'acronym',
u'\u0430\u043d\u043e\u043d\u0438\u043c\u043d\u0430\u044f-\u0441\u0441\u044b\u043b\u043a\u0430':
'anonymous-reference',
u'\u0431\u0443\u043a\u0432\u0430\u043b\u044c\u043d\u043e': 'literal',
u'\u0432\u0435\u0440\u0445\u043d\u0438\u0439-\u0438\u043d\u0434\u0435\u043a\u0441':
'superscript',
u'\u0432\u044b\u0434\u0435\u043b\u0435\u043d\u0438\u0435': 'emphasis',
u'\u0438\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u043d\u0430\u044f-\u0441\u0441\u044b\u043b\u043a\u0430':
'named-reference',
u'\u0438\u043d\u0434\u0435\u043a\u0441': 'index',
u'\u043d\u0438\u0436\u043d\u0438\u0439-\u0438\u043d\u0434\u0435\u043a\u0441':
'subscript',
u'\u0441\u0438\u043b\u044c\u043d\u043e\u0435-\u0432\u044b\u0434\u0435\u043b\u0435\u043d\u0438\u0435':
'strong',
u'\u0441\u043e\u043a\u0440\u0430\u0449\u0435\u043d\u0438\u0435':
'abbreviation',
u'\u0441\u0441\u044b\u043b\u043a\u0430-\u0437\u0430\u043c\u0435\u043d\u0430':
'substitution-reference',
u'\u0441\u0441\u044b\u043b\u043a\u0430-\u043d\u0430-pep': 'pep-reference',
u'\u0441\u0441\u044b\u043b\u043a\u0430-\u043d\u0430-rfc': 'rfc-reference',
u'\u0441\u0441\u044b\u043b\u043a\u0430-\u043d\u0430-uri': 'uri-reference',
u'\u0441\u0441\u044b\u043b\u043a\u0430-\u043d\u0430-\u0437\u0430\u0433\u043b\u0430\u0432\u0438\u0435':
'title-reference',
u'\u0441\u0441\u044b\u043b\u043a\u0430-\u043d\u0430-\u0441\u043d\u043e\u0441\u043a\u0443':
'footnote-reference',
u'\u0446\u0438\u0442\u0430\u0442\u043d\u0430\u044f-\u0441\u0441\u044b\u043b\u043a\u0430':
'citation-reference',
u'\u0446\u0435\u043b\u044c': 'target',
u'raw (translation required)': 'raw',}
"""Mapping of Russian role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,91 @@
# $Id: sk.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: Miroslav Vasko <zemiak@zoznam.sk>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Slovak-language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
u'pozor': 'attention',
u'opatrne': 'caution',
u'nebezpe\xe8enstvo': 'danger',
u'chyba': 'error',
u'rada': 'hint',
u'd\xf4le\x9eit\xe9': 'important',
u'pozn\xe1mka': 'note',
u'tip (translation required)': 'tip',
u'varovanie': 'warning',
u'admonition (translation required)': 'admonition',
u'sidebar (translation required)': 'sidebar',
u't\xe9ma': 'topic',
u'blok-riadkov': 'line-block',
u'parsed-literal': 'parsed-literal',
u'rubric (translation required)': 'rubric',
u'epigraph (translation required)': 'epigraph',
u'highlights (translation required)': 'highlights',
u'pull-quote (translation required)': 'pull-quote',
u'compound (translation required)': 'compound',
u'container (translation required)': 'container',
#u'questions': 'questions',
#u'qa': 'questions',
#u'faq': 'questions',
u'table (translation required)': 'table',
u'csv-table (translation required)': 'csv-table',
u'list-table (translation required)': 'list-table',
u'meta': 'meta',
#u'imagemap': 'imagemap',
u'obr\xe1zok': 'image',
u'tvar': 'figure',
u'vlo\x9ei\x9d': 'include',
u'raw (translation required)': 'raw',
u'nahradi\x9d': 'replace',
u'unicode': 'unicode',
u'd\u00E1tum': 'date',
u'class (translation required)': 'class',
u'role (translation required)': 'role',
u'default-role (translation required)': 'default-role',
u'title (translation required)': 'title',
u'obsah': 'contents',
u'\xe8as\x9d': 'sectnum',
u'\xe8as\x9d-\xe8\xedslovanie': 'sectnum',
u'cie\xbeov\xe9-pozn\xe1mky': 'target-notes',
u'header (translation required)': 'header',
u'footer (translation required)': 'footer',
#u'footnotes': 'footnotes',
#u'citations': 'citations',
}
"""Slovak name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
u'abbreviation (translation required)': 'abbreviation',
u'acronym (translation required)': 'acronym',
u'index (translation required)': 'index',
u'subscript (translation required)': 'subscript',
u'superscript (translation required)': 'superscript',
u'title-reference (translation required)': 'title-reference',
u'pep-reference (translation required)': 'pep-reference',
u'rfc-reference (translation required)': 'rfc-reference',
u'emphasis (translation required)': 'emphasis',
u'strong (translation required)': 'strong',
u'literal (translation required)': 'literal',
u'named-reference (translation required)': 'named-reference',
u'anonymous-reference (translation required)': 'anonymous-reference',
u'footnote-reference (translation required)': 'footnote-reference',
u'citation-reference (translation required)': 'citation-reference',
u'substitution-reference (translation required)': 'substitution-reference',
u'target (translation required)': 'target',
u'uri-reference (translation required)': 'uri-reference',
u'raw (translation required)': 'raw',}
"""Mapping of Slovak role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,90 @@
# $Id: sv.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: Adam Chodorowski <chodorowski@users.sourceforge.net>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Swedish language mappings for language-dependent features of reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
u'observera': 'attention',
u'caution (translation required)': 'caution',
u'fara': 'danger',
u'fel': 'error',
u'v\u00e4gledning': 'hint',
u'viktigt': 'important',
u'notera': 'note',
u'tips': 'tip',
u'varning': 'warning',
u'admonition (translation required)': 'admonition',
u'sidebar (translation required)': 'sidebar',
u'\u00e4mne': 'topic',
u'line-block (translation required)': 'line-block',
u'parsed-literal (translation required)': 'parsed-literal',
u'mellanrubrik': 'rubric',
u'epigraph (translation required)': 'epigraph',
u'highlights (translation required)': 'highlights',
u'pull-quote (translation required)': 'pull-quote',
u'compound (translation required)': 'compound',
u'container (translation required)': 'container',
# u'fr\u00e5gor': 'questions',
# NOTE: A bit long, but recommended by http://www.nada.kth.se/dataterm/:
# u'fr\u00e5gor-och-svar': 'questions',
# u'vanliga-fr\u00e5gor': 'questions',
u'table (translation required)': 'table',
u'csv-table (translation required)': 'csv-table',
u'list-table (translation required)': 'list-table',
u'meta': 'meta',
# u'bildkarta': 'imagemap', # FIXME: Translation might be too literal.
u'bild': 'image',
u'figur': 'figure',
u'inkludera': 'include',
u'r\u00e5': 'raw', # FIXME: Translation might be too literal.
u'ers\u00e4tt': 'replace',
u'unicode': 'unicode',
u'datum': 'date',
u'class (translation required)': 'class',
u'role (translation required)': 'role',
u'default-role (translation required)': 'default-role',
u'title (translation required)': 'title',
u'inneh\u00e5ll': 'contents',
u'sektionsnumrering': 'sectnum',
u'target-notes (translation required)': 'target-notes',
u'header (translation required)': 'header',
u'footer (translation required)': 'footer',
# u'fotnoter': 'footnotes',
# u'citeringar': 'citations',
}
"""Swedish name to registered (in directives/__init__.py) directive name
mapping."""
roles = {
u'abbreviation (translation required)': 'abbreviation',
u'acronym (translation required)': 'acronym',
u'index (translation required)': 'index',
u'subscript (translation required)': 'subscript',
u'superscript (translation required)': 'superscript',
u'title-reference (translation required)': 'title-reference',
u'pep-reference (translation required)': 'pep-reference',
u'rfc-reference (translation required)': 'rfc-reference',
u'emphasis (translation required)': 'emphasis',
u'strong (translation required)': 'strong',
u'literal (translation required)': 'literal',
u'named-reference (translation required)': 'named-reference',
u'anonymous-reference (translation required)': 'anonymous-reference',
u'footnote-reference (translation required)': 'footnote-reference',
u'citation-reference (translation required)': 'citation-reference',
u'substitution-reference (translation required)': 'substitution-reference',
u'target (translation required)': 'target',
u'uri-reference (translation required)': 'uri-reference',
u'r\u00e5': 'raw',}
"""Mapping of Swedish role names to canonical role names for interpreted text.
"""
@@ -0,0 +1,100 @@
# -*- coding: utf-8 -*-
# $Id: zh_cn.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: Panjunyong <panjy@zopechina.com>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Simplified Chinese language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
# language-dependent: fixed
u'注意': 'attention',
u'小心': 'caution',
u'危险': 'danger',
u'错误': 'error',
u'提示': 'hint',
u'重要': 'important',
u'注解': 'note',
u'技巧': 'tip',
u'警告': 'warning',
u'忠告': 'admonition',
u'侧框': 'sidebar',
u'主题': 'topic',
u'line-block (translation required)': 'line-block',
u'parsed-literal (translation required)': 'parsed-literal',
u'醒目': 'rubric',
u'铭文': 'epigraph',
u'要点': 'highlights',
u'pull-quote (translation required)': 'pull-quote',
u'复合': 'compound',
u'容器': 'container',
#u'questions (translation required)': 'questions',
u'表格': 'table',
u'csv表格': 'csv-table',
u'列表表格': 'list-table',
#u'qa (translation required)': 'questions',
#u'faq (translation required)': 'questions',
u'元数据': 'meta',
#u'imagemap (translation required)': 'imagemap',
u'图片': 'image',
u'图例': 'figure',
u'包含': 'include',
u'原文': 'raw',
u'代替': 'replace',
u'统一码': 'unicode',
u'日期': 'date',
u'类型': 'class',
u'角色': 'role',
u'默认角色': 'default-role',
u'标题': 'title',
u'目录': 'contents',
u'章节序号': 'sectnum',
u'题头': 'header',
u'页脚': 'footer',
#u'footnotes (translation required)': 'footnotes',
#u'citations (translation required)': 'citations',
u'target-notes (translation required)': 'target-notes',
u'restructuredtext-test-directive': 'restructuredtext-test-directive'}
"""Simplified Chinese name to registered (in directives/__init__.py)
directive name mapping."""
roles = {
# language-dependent: fixed
u'缩写': 'abbreviation',
u'简称': 'acronym',
u'index (translation required)': 'index',
u'i (translation required)': 'index',
u'下标': 'subscript',
u'上标': 'superscript',
u'title-reference (translation required)': 'title-reference',
u'title (translation required)': 'title-reference',
u't (translation required)': 'title-reference',
u'pep-reference (translation required)': 'pep-reference',
u'pep (translation required)': 'pep-reference',
u'rfc-reference (translation required)': 'rfc-reference',
u'rfc (translation required)': 'rfc-reference',
u'强调': 'emphasis',
u'加粗': 'strong',
u'字面': 'literal',
u'named-reference (translation required)': 'named-reference',
u'anonymous-reference (translation required)': 'anonymous-reference',
u'footnote-reference (translation required)': 'footnote-reference',
u'citation-reference (translation required)': 'citation-reference',
u'substitution-reference (translation required)': 'substitution-reference',
u'target (translation required)': 'target',
u'uri-reference (translation required)': 'uri-reference',
u'uri (translation required)': 'uri-reference',
u'url (translation required)': 'uri-reference',
u'raw (translation required)': 'raw',}
"""Mapping of Simplified Chinese role names to canonical role names
for interpreted text."""
@@ -0,0 +1,105 @@
# -*- coding: utf-8 -*-
# $Id: zh_tw.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
# New language mappings are welcome. Before doing a new translation, please
# read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be
# translated for each language: one in docutils/languages, the other in
# docutils/parsers/rst/languages.
"""
Traditional Chinese language mappings for language-dependent features of
reStructuredText.
"""
__docformat__ = 'reStructuredText'
directives = {
# language-dependent: fixed
'attention (translation required)': 'attention',
'caution (translation required)': 'caution',
'danger (translation required)': 'danger',
'error (translation required)': 'error',
'hint (translation required)': 'hint',
'important (translation required)': 'important',
'note (translation required)': 'note',
'tip (translation required)': 'tip',
'warning (translation required)': 'warning',
'admonition (translation required)': 'admonition',
'sidebar (translation required)': 'sidebar',
'topic (translation required)': 'topic',
'line-block (translation required)': 'line-block',
'parsed-literal (translation required)': 'parsed-literal',
'rubric (translation required)': 'rubric',
'epigraph (translation required)': 'epigraph',
'highlights (translation required)': 'highlights',
'pull-quote (translation required)': 'pull-quote',
'compound (translation required)': 'compound',
u'container (translation required)': 'container',
#'questions (translation required)': 'questions',
'table (translation required)': 'table',
'csv-table (translation required)': 'csv-table',
'list-table (translation required)': 'list-table',
#'qa (translation required)': 'questions',
#'faq (translation required)': 'questions',
'meta (translation required)': 'meta',
#'imagemap (translation required)': 'imagemap',
'image (translation required)': 'image',
'figure (translation required)': 'figure',
'include (translation required)': 'include',
'raw (translation required)': 'raw',
'replace (translation required)': 'replace',
'unicode (translation required)': 'unicode',
u'日期': 'date',
'class (translation required)': 'class',
'role (translation required)': 'role',
u'default-role (translation required)': 'default-role',
u'title (translation required)': 'title',
'contents (translation required)': 'contents',
'sectnum (translation required)': 'sectnum',
'section-numbering (translation required)': 'sectnum',
u'header (translation required)': 'header',
u'footer (translation required)': 'footer',
#'footnotes (translation required)': 'footnotes',
#'citations (translation required)': 'citations',
'target-notes (translation required)': 'target-notes',
'restructuredtext-test-directive': 'restructuredtext-test-directive'}
"""Traditional Chinese name to registered (in directives/__init__.py)
directive name mapping."""
roles = {
# language-dependent: fixed
'abbreviation (translation required)': 'abbreviation',
'ab (translation required)': 'abbreviation',
'acronym (translation required)': 'acronym',
'ac (translation required)': 'acronym',
'index (translation required)': 'index',
'i (translation required)': 'index',
'subscript (translation required)': 'subscript',
'sub (translation required)': 'subscript',
'superscript (translation required)': 'superscript',
'sup (translation required)': 'superscript',
'title-reference (translation required)': 'title-reference',
'title (translation required)': 'title-reference',
't (translation required)': 'title-reference',
'pep-reference (translation required)': 'pep-reference',
'pep (translation required)': 'pep-reference',
'rfc-reference (translation required)': 'rfc-reference',
'rfc (translation required)': 'rfc-reference',
'emphasis (translation required)': 'emphasis',
'strong (translation required)': 'strong',
'literal (translation required)': 'literal',
'named-reference (translation required)': 'named-reference',
'anonymous-reference (translation required)': 'anonymous-reference',
'footnote-reference (translation required)': 'footnote-reference',
'citation-reference (translation required)': 'citation-reference',
'substitution-reference (translation required)': 'substitution-reference',
'target (translation required)': 'target',
'uri-reference (translation required)': 'uri-reference',
'uri (translation required)': 'uri-reference',
'url (translation required)': 'uri-reference',
'raw (translation required)': 'raw',}
"""Mapping of Traditional Chinese role names to canonical role names for
interpreted text."""
@@ -0,0 +1,350 @@
# $Id: roles.py 6121 2009-09-10 12:05:04Z milde $
# Author: Edward Loper <edloper@gradient.cis.upenn.edu>
# Copyright: This module has been placed in the public domain.
"""
This module defines standard interpreted text role functions, a registry for
interpreted text roles, and an API for adding to and retrieving from the
registry.
The interface for interpreted role functions is as follows::
def role_fn(name, rawtext, text, lineno, inliner,
options={}, content=[]):
code...
# Set function attributes for customization:
role_fn.options = ...
role_fn.content = ...
Parameters:
- ``name`` is the local name of the interpreted text role, the role name
actually used in the document.
- ``rawtext`` is a string containing the entire interpreted text construct.
Return it as a ``problematic`` node linked to a system message if there is a
problem.
- ``text`` is the interpreted text content, with backslash escapes converted
to nulls (``\x00``).
- ``lineno`` is the line number where the interpreted text beings.
- ``inliner`` is the Inliner object that called the role function.
It defines the following useful attributes: ``reporter``,
``problematic``, ``memo``, ``parent``, ``document``.
- ``options``: A dictionary of directive options for customization, to be
interpreted by the role function. Used for additional attributes for the
generated elements and other functionality.
- ``content``: A list of strings, the directive content for customization
("role" directive). To be interpreted by the role function.
Function attributes for customization, interpreted by the "role" directive:
- ``options``: A dictionary, mapping known option names to conversion
functions such as `int` or `float`. ``None`` or an empty dict implies no
options to parse. Several directive option conversion functions are defined
in the `directives` module.
All role functions implicitly support the "class" option, unless disabled
with an explicit ``{'class': None}``.
- ``content``: A boolean; true if content is allowed. Client code must handle
the case where content is required but not supplied (an empty content list
will be supplied).
Note that unlike directives, the "arguments" function attribute is not
supported for role customization. Directive arguments are handled by the
"role" directive itself.
Interpreted role functions return a tuple of two values:
- A list of nodes which will be inserted into the document tree at the
point where the interpreted role was encountered (can be an empty
list).
- A list of system messages, which will be inserted into the document tree
immediately after the end of the current inline block (can also be empty).
"""
__docformat__ = 'reStructuredText'
from docutils import nodes, utils
from docutils.parsers.rst import directives
from docutils.parsers.rst.languages import en as _fallback_language_module
DEFAULT_INTERPRETED_ROLE = 'title-reference'
"""
The canonical name of the default interpreted role. This role is used
when no role is specified for a piece of interpreted text.
"""
_role_registry = {}
"""Mapping of canonical role names to role functions. Language-dependent role
names are defined in the ``language`` subpackage."""
_roles = {}
"""Mapping of local or language-dependent interpreted text role names to role
functions."""
def role(role_name, language_module, lineno, reporter):
"""
Locate and return a role function from its language-dependent name, along
with a list of system messages. If the role is not found in the current
language, check English. Return a 2-tuple: role function (``None`` if the
named role cannot be found) and a list of system messages.
"""
normname = role_name.lower()
messages = []
msg_text = []
if normname in _roles:
return _roles[normname], messages
if role_name:
canonicalname = None
try:
canonicalname = language_module.roles[normname]
except AttributeError, error:
msg_text.append('Problem retrieving role entry from language '
'module %r: %s.' % (language_module, error))
except KeyError:
msg_text.append('No role entry for "%s" in module "%s".'
% (role_name, language_module.__name__))
else:
canonicalname = DEFAULT_INTERPRETED_ROLE
# If we didn't find it, try English as a fallback.
if not canonicalname:
try:
canonicalname = _fallback_language_module.roles[normname]
msg_text.append('Using English fallback for role "%s".'
% role_name)
except KeyError:
msg_text.append('Trying "%s" as canonical role name.'
% role_name)
# The canonical name should be an English name, but just in case:
canonicalname = normname
# Collect any messages that we generated.
if msg_text:
message = reporter.info('\n'.join(msg_text), line=lineno)
messages.append(message)
# Look the role up in the registry, and return it.
if canonicalname in _role_registry:
role_fn = _role_registry[canonicalname]
register_local_role(normname, role_fn)
return role_fn, messages
else:
return None, messages # Error message will be generated by caller.
def register_canonical_role(name, role_fn):
"""
Register an interpreted text role by its canonical name.
:Parameters:
- `name`: The canonical name of the interpreted role.
- `role_fn`: The role function. See the module docstring.
"""
set_implicit_options(role_fn)
_role_registry[name] = role_fn
def register_local_role(name, role_fn):
"""
Register an interpreted text role by its local or language-dependent name.
:Parameters:
- `name`: The local or language-dependent name of the interpreted role.
- `role_fn`: The role function. See the module docstring.
"""
set_implicit_options(role_fn)
_roles[name] = role_fn
def set_implicit_options(role_fn):
"""
Add customization options to role functions, unless explicitly set or
disabled.
"""
if not hasattr(role_fn, 'options') or role_fn.options is None:
role_fn.options = {'class': directives.class_option}
elif 'class' not in role_fn.options:
role_fn.options['class'] = directives.class_option
def register_generic_role(canonical_name, node_class):
"""For roles which simply wrap a given `node_class` around the text."""
role = GenericRole(canonical_name, node_class)
register_canonical_role(canonical_name, role)
class GenericRole:
"""
Generic interpreted text role, where the interpreted text is simply
wrapped with the provided node class.
"""
def __init__(self, role_name, node_class):
self.name = role_name
self.node_class = node_class
def __call__(self, role, rawtext, text, lineno, inliner,
options={}, content=[]):
set_classes(options)
return [self.node_class(rawtext, utils.unescape(text), **options)], []
class CustomRole:
"""
Wrapper for custom interpreted text roles.
"""
def __init__(self, role_name, base_role, options={}, content=[]):
self.name = role_name
self.base_role = base_role
self.options = None
if hasattr(base_role, 'options'):
self.options = base_role.options
self.content = None
if hasattr(base_role, 'content'):
self.content = base_role.content
self.supplied_options = options
self.supplied_content = content
def __call__(self, role, rawtext, text, lineno, inliner,
options={}, content=[]):
opts = self.supplied_options.copy()
opts.update(options)
cont = list(self.supplied_content)
if cont and content:
cont += '\n'
cont.extend(content)
return self.base_role(role, rawtext, text, lineno, inliner,
options=opts, content=cont)
def generic_custom_role(role, rawtext, text, lineno, inliner,
options={}, content=[]):
""""""
# Once nested inline markup is implemented, this and other methods should
# recursively call inliner.nested_parse().
set_classes(options)
return [nodes.inline(rawtext, utils.unescape(text), **options)], []
generic_custom_role.options = {'class': directives.class_option}
######################################################################
# Define and register the standard roles:
######################################################################
register_generic_role('abbreviation', nodes.abbreviation)
register_generic_role('acronym', nodes.acronym)
register_generic_role('emphasis', nodes.emphasis)
register_generic_role('literal', nodes.literal)
register_generic_role('strong', nodes.strong)
register_generic_role('subscript', nodes.subscript)
register_generic_role('superscript', nodes.superscript)
register_generic_role('title-reference', nodes.title_reference)
def pep_reference_role(role, rawtext, text, lineno, inliner,
options={}, content=[]):
try:
pepnum = int(text)
if pepnum < 0 or pepnum > 9999:
raise ValueError
except ValueError:
msg = inliner.reporter.error(
'PEP number must be a number from 0 to 9999; "%s" is invalid.'
% text, line=lineno)
prb = inliner.problematic(rawtext, rawtext, msg)
return [prb], [msg]
# Base URL mainly used by inliner.pep_reference; so this is correct:
ref = (inliner.document.settings.pep_base_url
+ inliner.document.settings.pep_file_url_template % pepnum)
set_classes(options)
return [nodes.reference(rawtext, 'PEP ' + utils.unescape(text), refuri=ref,
**options)], []
register_canonical_role('pep-reference', pep_reference_role)
def rfc_reference_role(role, rawtext, text, lineno, inliner,
options={}, content=[]):
try:
rfcnum = int(text)
if rfcnum <= 0:
raise ValueError
except ValueError:
msg = inliner.reporter.error(
'RFC number must be a number greater than or equal to 1; '
'"%s" is invalid.' % text, line=lineno)
prb = inliner.problematic(rawtext, rawtext, msg)
return [prb], [msg]
# Base URL mainly used by inliner.rfc_reference, so this is correct:
ref = inliner.document.settings.rfc_base_url + inliner.rfc_url % rfcnum
set_classes(options)
node = nodes.reference(rawtext, 'RFC ' + utils.unescape(text), refuri=ref,
**options)
return [node], []
register_canonical_role('rfc-reference', rfc_reference_role)
def raw_role(role, rawtext, text, lineno, inliner, options={}, content=[]):
if not inliner.document.settings.raw_enabled:
msg = inliner.reporter.warning('raw (and derived) roles disabled')
prb = inliner.problematic(rawtext, rawtext, msg)
return [prb], [msg]
if 'format' not in options:
msg = inliner.reporter.error(
'No format (Writer name) is associated with this role: "%s".\n'
'The "raw" role cannot be used directly.\n'
'Instead, use the "role" directive to create a new role with '
'an associated format.' % role, line=lineno)
prb = inliner.problematic(rawtext, rawtext, msg)
return [prb], [msg]
set_classes(options)
node = nodes.raw(rawtext, utils.unescape(text, 1), **options)
return [node], []
raw_role.options = {'format': directives.unchanged}
register_canonical_role('raw', raw_role)
######################################################################
# Register roles that are currently unimplemented.
######################################################################
def unimplemented_role(role, rawtext, text, lineno, inliner, attributes={}):
msg = inliner.reporter.error(
'Interpreted text role "%s" not implemented.' % role, line=lineno)
prb = inliner.problematic(rawtext, rawtext, msg)
return [prb], [msg]
register_canonical_role('index', unimplemented_role)
register_canonical_role('named-reference', unimplemented_role)
register_canonical_role('anonymous-reference', unimplemented_role)
register_canonical_role('uri-reference', unimplemented_role)
register_canonical_role('footnote-reference', unimplemented_role)
register_canonical_role('citation-reference', unimplemented_role)
register_canonical_role('substitution-reference', unimplemented_role)
register_canonical_role('target', unimplemented_role)
# This should remain unimplemented, for testing purposes:
register_canonical_role('restructuredtext-unimplemented-role',
unimplemented_role)
def set_classes(options):
"""
Auxiliary function to set options['classes'] and delete
options['class'].
"""
if 'class' in options:
assert 'classes' not in options
options['classes'] = options['class']
del options['class']
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,525 @@
# $Id: tableparser.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
This module defines table parser classes,which parse plaintext-graphic tables
and produce a well-formed data structure suitable for building a CALS table.
:Classes:
- `GridTableParser`: Parse fully-formed tables represented with a grid.
- `SimpleTableParser`: Parse simple tables, delimited by top & bottom
borders.
:Exception class: `TableMarkupError`
:Function:
`update_dict_of_lists()`: Merge two dictionaries containing list values.
"""
__docformat__ = 'reStructuredText'
import re
import sys
from docutils import DataError
class TableMarkupError(DataError): pass
class TableParser:
"""
Abstract superclass for the common parts of the syntax-specific parsers.
"""
head_body_separator_pat = None
"""Matches the row separator between head rows and body rows."""
double_width_pad_char = '\x00'
"""Padding character for East Asian double-width text."""
def parse(self, block):
"""
Analyze the text `block` and return a table data structure.
Given a plaintext-graphic table in `block` (list of lines of text; no
whitespace padding), parse the table, construct and return the data
necessary to construct a CALS table or equivalent.
Raise `TableMarkupError` if there is any problem with the markup.
"""
self.setup(block)
self.find_head_body_sep()
self.parse_table()
structure = self.structure_from_cells()
return structure
def find_head_body_sep(self):
"""Look for a head/body row separator line; store the line index."""
for i in range(len(self.block)):
line = self.block[i]
if self.head_body_separator_pat.match(line):
if self.head_body_sep:
raise TableMarkupError(
'Multiple head/body row separators in table (at line '
'offset %s and %s); only one allowed.'
% (self.head_body_sep, i))
else:
self.head_body_sep = i
self.block[i] = line.replace('=', '-')
if self.head_body_sep == 0 or self.head_body_sep == (len(self.block)
- 1):
raise TableMarkupError('The head/body row separator may not be '
'the first or last line of the table.')
class GridTableParser(TableParser):
"""
Parse a grid table using `parse()`.
Here's an example of a grid table::
+------------------------+------------+----------+----------+
| Header row, column 1 | Header 2 | Header 3 | Header 4 |
+========================+============+==========+==========+
| body row 1, column 1 | column 2 | column 3 | column 4 |
+------------------------+------------+----------+----------+
| body row 2 | Cells may span columns. |
+------------------------+------------+---------------------+
| body row 3 | Cells may | - Table cells |
+------------------------+ span rows. | - contain |
| body row 4 | | - body elements. |
+------------------------+------------+---------------------+
Intersections use '+', row separators use '-' (except for one optional
head/body row separator, which uses '='), and column separators use '|'.
Passing the above table to the `parse()` method will result in the
following data structure::
([24, 12, 10, 10],
[[(0, 0, 1, ['Header row, column 1']),
(0, 0, 1, ['Header 2']),
(0, 0, 1, ['Header 3']),
(0, 0, 1, ['Header 4'])]],
[[(0, 0, 3, ['body row 1, column 1']),
(0, 0, 3, ['column 2']),
(0, 0, 3, ['column 3']),
(0, 0, 3, ['column 4'])],
[(0, 0, 5, ['body row 2']),
(0, 2, 5, ['Cells may span columns.']),
None,
None],
[(0, 0, 7, ['body row 3']),
(1, 0, 7, ['Cells may', 'span rows.', '']),
(1, 1, 7, ['- Table cells', '- contain', '- body elements.']),
None],
[(0, 0, 9, ['body row 4']), None, None, None]])
The first item is a list containing column widths (colspecs). The second
item is a list of head rows, and the third is a list of body rows. Each
row contains a list of cells. Each cell is either None (for a cell unused
because of another cell's span), or a tuple. A cell tuple contains four
items: the number of extra rows used by the cell in a vertical span
(morerows); the number of extra columns used by the cell in a horizontal
span (morecols); the line offset of the first line of the cell contents;
and the cell contents, a list of lines of text.
"""
head_body_separator_pat = re.compile(r'\+=[=+]+=\+ *$')
def setup(self, block):
self.block = block[:] # make a copy; it may be modified
self.block.disconnect() # don't propagate changes to parent
self.bottom = len(block) - 1
self.right = len(block[0]) - 1
self.head_body_sep = None
self.done = [-1] * len(block[0])
self.cells = []
self.rowseps = {0: [0]}
self.colseps = {0: [0]}
def parse_table(self):
"""
Start with a queue of upper-left corners, containing the upper-left
corner of the table itself. Trace out one rectangular cell, remember
it, and add its upper-right and lower-left corners to the queue of
potential upper-left corners of further cells. Process the queue in
top-to-bottom order, keeping track of how much of each text column has
been seen.
We'll end up knowing all the row and column boundaries, cell positions
and their dimensions.
"""
corners = [(0, 0)]
while corners:
top, left = corners.pop(0)
if top == self.bottom or left == self.right \
or top <= self.done[left]:
continue
result = self.scan_cell(top, left)
if not result:
continue
bottom, right, rowseps, colseps = result
update_dict_of_lists(self.rowseps, rowseps)
update_dict_of_lists(self.colseps, colseps)
self.mark_done(top, left, bottom, right)
cellblock = self.block.get_2D_block(top + 1, left + 1,
bottom, right)
cellblock.disconnect() # lines in cell can't sync with parent
cellblock.replace(self.double_width_pad_char, '')
self.cells.append((top, left, bottom, right, cellblock))
corners.extend([(top, right), (bottom, left)])
corners.sort()
if not self.check_parse_complete():
raise TableMarkupError('Malformed table; parse incomplete.')
def mark_done(self, top, left, bottom, right):
"""For keeping track of how much of each text column has been seen."""
before = top - 1
after = bottom - 1
for col in range(left, right):
assert self.done[col] == before
self.done[col] = after
def check_parse_complete(self):
"""Each text column should have been completely seen."""
last = self.bottom - 1
for col in range(self.right):
if self.done[col] != last:
return None
return 1
def scan_cell(self, top, left):
"""Starting at the top-left corner, start tracing out a cell."""
assert self.block[top][left] == '+'
result = self.scan_right(top, left)
return result
def scan_right(self, top, left):
"""
Look for the top-right corner of the cell, and make note of all column
boundaries ('+').
"""
colseps = {}
line = self.block[top]
for i in range(left + 1, self.right + 1):
if line[i] == '+':
colseps[i] = [top]
result = self.scan_down(top, left, i)
if result:
bottom, rowseps, newcolseps = result
update_dict_of_lists(colseps, newcolseps)
return bottom, i, rowseps, colseps
elif line[i] != '-':
return None
return None
def scan_down(self, top, left, right):
"""
Look for the bottom-right corner of the cell, making note of all row
boundaries.
"""
rowseps = {}
for i in range(top + 1, self.bottom + 1):
if self.block[i][right] == '+':
rowseps[i] = [right]
result = self.scan_left(top, left, i, right)
if result:
newrowseps, colseps = result
update_dict_of_lists(rowseps, newrowseps)
return i, rowseps, colseps
elif self.block[i][right] != '|':
return None
return None
def scan_left(self, top, left, bottom, right):
"""
Noting column boundaries, look for the bottom-left corner of the cell.
It must line up with the starting point.
"""
colseps = {}
line = self.block[bottom]
for i in range(right - 1, left, -1):
if line[i] == '+':
colseps[i] = [bottom]
elif line[i] != '-':
return None
if line[left] != '+':
return None
result = self.scan_up(top, left, bottom, right)
if result is not None:
rowseps = result
return rowseps, colseps
return None
def scan_up(self, top, left, bottom, right):
"""
Noting row boundaries, see if we can return to the starting point.
"""
rowseps = {}
for i in range(bottom - 1, top, -1):
if self.block[i][left] == '+':
rowseps[i] = [left]
elif self.block[i][left] != '|':
return None
return rowseps
def structure_from_cells(self):
"""
From the data collected by `scan_cell()`, convert to the final data
structure.
"""
rowseps = self.rowseps.keys() # list of row boundaries
rowseps.sort()
rowindex = {}
for i in range(len(rowseps)):
rowindex[rowseps[i]] = i # row boundary -> row number mapping
colseps = self.colseps.keys() # list of column boundaries
colseps.sort()
colindex = {}
for i in range(len(colseps)):
colindex[colseps[i]] = i # column boundary -> col number map
colspecs = [(colseps[i] - colseps[i - 1] - 1)
for i in range(1, len(colseps))] # list of column widths
# prepare an empty table with the correct number of rows & columns
onerow = [None for i in range(len(colseps) - 1)]
rows = [onerow[:] for i in range(len(rowseps) - 1)]
# keep track of # of cells remaining; should reduce to zero
remaining = (len(rowseps) - 1) * (len(colseps) - 1)
for top, left, bottom, right, block in self.cells:
rownum = rowindex[top]
colnum = colindex[left]
assert rows[rownum][colnum] is None, (
'Cell (row %s, column %s) already used.'
% (rownum + 1, colnum + 1))
morerows = rowindex[bottom] - rownum - 1
morecols = colindex[right] - colnum - 1
remaining -= (morerows + 1) * (morecols + 1)
# write the cell into the table
rows[rownum][colnum] = (morerows, morecols, top + 1, block)
assert remaining == 0, 'Unused cells remaining.'
if self.head_body_sep: # separate head rows from body rows
numheadrows = rowindex[self.head_body_sep]
headrows = rows[:numheadrows]
bodyrows = rows[numheadrows:]
else:
headrows = []
bodyrows = rows
return (colspecs, headrows, bodyrows)
class SimpleTableParser(TableParser):
"""
Parse a simple table using `parse()`.
Here's an example of a simple table::
===== =====
col 1 col 2
===== =====
1 Second column of row 1.
2 Second column of row 2.
Second line of paragraph.
3 - Second column of row 3.
- Second item in bullet
list (row 3, column 2).
4 is a span
------------
5
===== =====
Top and bottom borders use '=', column span underlines use '-', column
separation is indicated with spaces.
Passing the above table to the `parse()` method will result in the
following data structure, whose interpretation is the same as for
`GridTableParser`::
([5, 25],
[[(0, 0, 1, ['col 1']),
(0, 0, 1, ['col 2'])]],
[[(0, 0, 3, ['1']),
(0, 0, 3, ['Second column of row 1.'])],
[(0, 0, 4, ['2']),
(0, 0, 4, ['Second column of row 2.',
'Second line of paragraph.'])],
[(0, 0, 6, ['3']),
(0, 0, 6, ['- Second column of row 3.',
'',
'- Second item in bullet',
' list (row 3, column 2).'])],
[(0, 1, 10, ['4 is a span'])],
[(0, 0, 12, ['5']),
(0, 0, 12, [''])]])
"""
head_body_separator_pat = re.compile('=[ =]*$')
span_pat = re.compile('-[ -]*$')
def setup(self, block):
self.block = block[:] # make a copy; it will be modified
self.block.disconnect() # don't propagate changes to parent
# Convert top & bottom borders to column span underlines:
self.block[0] = self.block[0].replace('=', '-')
self.block[-1] = self.block[-1].replace('=', '-')
self.head_body_sep = None
self.columns = []
self.border_end = None
self.table = []
self.done = [-1] * len(block[0])
self.rowseps = {0: [0]}
self.colseps = {0: [0]}
def parse_table(self):
"""
First determine the column boundaries from the top border, then
process rows. Each row may consist of multiple lines; accumulate
lines until a row is complete. Call `self.parse_row` to finish the
job.
"""
# Top border must fully describe all table columns.
self.columns = self.parse_columns(self.block[0], 0)
self.border_end = self.columns[-1][1]
firststart, firstend = self.columns[0]
offset = 1 # skip top border
start = 1
text_found = None
while offset < len(self.block):
line = self.block[offset]
if self.span_pat.match(line):
# Column span underline or border; row is complete.
self.parse_row(self.block[start:offset], start,
(line.rstrip(), offset))
start = offset + 1
text_found = None
elif line[firststart:firstend].strip():
# First column not blank, therefore it's a new row.
if text_found and offset != start:
self.parse_row(self.block[start:offset], start)
start = offset
text_found = 1
elif not text_found:
start = offset + 1
offset += 1
def parse_columns(self, line, offset):
"""
Given a column span underline, return a list of (begin, end) pairs.
"""
cols = []
end = 0
while 1:
begin = line.find('-', end)
end = line.find(' ', begin)
if begin < 0:
break
if end < 0:
end = len(line)
cols.append((begin, end))
if self.columns:
if cols[-1][1] != self.border_end:
raise TableMarkupError('Column span incomplete at line '
'offset %s.' % offset)
# Allow for an unbounded rightmost column:
cols[-1] = (cols[-1][0], self.columns[-1][1])
return cols
def init_row(self, colspec, offset):
i = 0
cells = []
for start, end in colspec:
morecols = 0
try:
assert start == self.columns[i][0]
while end != self.columns[i][1]:
i += 1
morecols += 1
except (AssertionError, IndexError):
raise TableMarkupError('Column span alignment problem at '
'line offset %s.' % (offset + 1))
cells.append([0, morecols, offset, []])
i += 1
return cells
def parse_row(self, lines, start, spanline=None):
"""
Given the text `lines` of a row, parse it and append to `self.table`.
The row is parsed according to the current column spec (either
`spanline` if provided or `self.columns`). For each column, extract
text from each line, and check for text in column margins. Finally,
adjust for insigificant whitespace.
"""
if not (lines or spanline):
# No new row, just blank lines.
return
if spanline:
columns = self.parse_columns(*spanline)
span_offset = spanline[1]
else:
columns = self.columns[:]
span_offset = start
self.check_columns(lines, start, columns)
row = self.init_row(columns, start)
for i in range(len(columns)):
start, end = columns[i]
cellblock = lines.get_2D_block(0, start, len(lines), end)
cellblock.disconnect() # lines in cell can't sync with parent
cellblock.replace(self.double_width_pad_char, '')
row[i][3] = cellblock
self.table.append(row)
def check_columns(self, lines, first_line, columns):
"""
Check for text in column margins and text overflow in the last column.
Raise TableMarkupError if anything but whitespace is in column margins.
Adjust the end value for the last column if there is text overflow.
"""
# "Infinite" value for a dummy last column's beginning, used to
# check for text overflow:
columns.append((sys.maxint, None))
lastcol = len(columns) - 2
for i in range(len(columns) - 1):
start, end = columns[i]
nextstart = columns[i+1][0]
offset = 0
for line in lines:
if i == lastcol and line[end:].strip():
text = line[start:].rstrip()
new_end = start + len(text)
columns[i] = (start, new_end)
main_start, main_end = self.columns[-1]
if new_end > main_end:
self.columns[-1] = (main_start, new_end)
elif line[end:nextstart].strip():
raise TableMarkupError('Text in column margin at line '
'offset %s.' % (first_line + offset))
offset += 1
columns.pop()
def structure_from_cells(self):
colspecs = [end - start for start, end in self.columns]
first_body_row = 0
if self.head_body_sep:
for i in range(len(self.table)):
if self.table[i][0][2] > self.head_body_sep:
first_body_row = i
break
return (colspecs, self.table[:first_body_row],
self.table[first_body_row:])
def update_dict_of_lists(master, newdata):
"""
Extend the list values of `master` with those from `newdata`.
Both parameters must be dictionaries containing list values.
"""
for key, values in newdata.items():
master.setdefault(key, []).extend(values)
+107
View File
@@ -0,0 +1,107 @@
# $Id: __init__.py 5618 2008-07-28 08:37:32Z strank $
# Authors: David Goodger <goodger@python.org>; Ueli Schlaepfer
# Copyright: This module has been placed in the public domain.
"""
This package contains Docutils Reader modules.
"""
__docformat__ = 'reStructuredText'
from docutils import utils, parsers, Component
from docutils.transforms import universal
class Reader(Component):
"""
Abstract base class for docutils Readers.
Each reader module or package must export a subclass also called 'Reader'.
The two steps of a Reader's responsibility are `scan()` and
`parse()`. Call `read()` to process a document.
"""
component_type = 'reader'
config_section = 'readers'
def get_transforms(self):
return Component.get_transforms(self) + [
universal.Decorations,
universal.ExposeInternals,
universal.StripComments,]
def __init__(self, parser=None, parser_name=None):
"""
Initialize the Reader instance.
Several instance attributes are defined with dummy initial values.
Subclasses may use these attributes as they wish.
"""
self.parser = parser
"""A `parsers.Parser` instance shared by all doctrees. May be left
unspecified if the document source determines the parser."""
if parser is None and parser_name:
self.set_parser(parser_name)
self.source = None
"""`docutils.io` IO object, source of input data."""
self.input = None
"""Raw text input; either a single string or, for more complex cases,
a collection of strings."""
def set_parser(self, parser_name):
"""Set `self.parser` by name."""
parser_class = parsers.get_parser_class(parser_name)
self.parser = parser_class()
def read(self, source, parser, settings):
self.source = source
if not self.parser:
self.parser = parser
self.settings = settings
self.input = self.source.read()
self.parse()
return self.document
def parse(self):
"""Parse `self.input` into a document tree."""
self.document = document = self.new_document()
self.parser.parse(self.input, document)
document.current_source = document.current_line = None
def new_document(self):
"""Create and return a new empty document tree (root node)."""
document = utils.new_document(self.source.source_path, self.settings)
return document
class ReReader(Reader):
"""
A reader which rereads an existing document tree (e.g. a
deserializer).
Often used in conjunction with `writers.UnfilteredWriter`.
"""
def get_transforms(self):
# Do not add any transforms. They have already been applied
# by the reader which originally created the document.
return Component.get_transforms(self)
_reader_aliases = {}
def get_reader_class(reader_name):
"""Return the Reader class from the `reader_name` module."""
reader_name = reader_name.lower()
if reader_name in _reader_aliases:
reader_name = _reader_aliases[reader_name]
module = __import__(reader_name, globals(), locals())
return module.Reader
@@ -0,0 +1,46 @@
# $Id: doctree.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: Martin Blais <blais@furius.ca>
# Copyright: This module has been placed in the public domain.
"""Reader for existing document trees."""
from docutils import readers, utils, transforms
class Reader(readers.ReReader):
"""
Adapt the Reader API for an existing document tree.
The existing document tree must be passed as the ``source`` parameter to
the `docutils.core.Publisher` initializer, wrapped in a
`docutils.io.DocTreeInput` object::
pub = docutils.core.Publisher(
..., source=docutils.io.DocTreeInput(document), ...)
The original document settings are overridden; if you want to use the
settings of the original document, pass ``settings=document.settings`` to
the Publisher call above.
"""
supported = ('doctree',)
config_section = 'doctree reader'
config_section_dependencies = ('readers',)
def parse(self):
"""
No parsing to do; refurbish the document tree instead.
Overrides the inherited method.
"""
self.document = self.input
# Create fresh Transformer object, to be populated from Writer
# component.
self.document.transformer = transforms.Transformer(self.document)
# Replace existing settings object with new one.
self.document.settings = self.settings
# Create fresh Reporter object because it is dependent on
# (new) settings.
self.document.reporter = utils.new_reporter(
self.document.get('source', ''), self.document.settings)
+48
View File
@@ -0,0 +1,48 @@
# $Id: pep.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
Python Enhancement Proposal (PEP) Reader.
"""
__docformat__ = 'reStructuredText'
from docutils.readers import standalone
from docutils.transforms import peps, references, misc, frontmatter
from docutils.parsers import rst
class Reader(standalone.Reader):
supported = ('pep',)
"""Contexts this reader supports."""
settings_spec = (
'PEP Reader Option Defaults',
'The --pep-references and --rfc-references options (for the '
'reStructuredText parser) are on by default.',
())
config_section = 'pep reader'
config_section_dependencies = ('readers', 'standalone reader')
def get_transforms(self):
transforms = standalone.Reader.get_transforms(self)
# We have PEP-specific frontmatter handling.
transforms.remove(frontmatter.DocTitle)
transforms.remove(frontmatter.SectionSubTitle)
transforms.remove(frontmatter.DocInfo)
transforms.extend([peps.Headers, peps.Contents, peps.TargetNotes])
return transforms
settings_default_overrides = {'pep_references': 1, 'rfc_references': 1}
inliner_class = rst.states.Inliner
def __init__(self, parser=None, parser_name=None):
"""`parser` should be ``None``."""
if parser is None:
parser = rst.Parser(rfc2822=1, inliner=self.inliner_class())
standalone.Reader.__init__(self, parser, '')
@@ -0,0 +1,127 @@
# $Id: __init__.py 5618 2008-07-28 08:37:32Z strank $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
This package contains the Python Source Reader modules.
"""
__docformat__ = 'reStructuredText'
import sys
import docutils.readers
from docutils.readers.python import moduleparser
from docutils import parsers
from docutils import nodes
from docutils.readers.python import pynodes
from docutils import readers
class Reader(docutils.readers.Reader):
config_section = 'python reader'
config_section_dependencies = ('readers',)
default_parser = 'restructuredtext'
def parse(self):
"""Parse `self.input` into a document tree."""
self.document = document = self.new_document()
module_section = moduleparser.parse_module(self.input,
self.source.source_path)
module_section.walk(DocformatVisitor(self.document))
visitor = DocstringFormattingVisitor(
document=document,
default_parser=self.default_parser)
module_section.walk(visitor)
self.document.append(module_section)
class DocformatVisitor(nodes.SparseNodeVisitor):
"""
This sets docformat attributes in a module. Wherever an assignment
to __docformat__ is found, we look for the enclosing scope -- a class,
a module, or a function -- and set the docformat attribute there.
We can't do this during the DocstringFormattingVisitor walking,
because __docformat__ may appear below a docstring in that format
(typically below the module docstring).
"""
def visit_attribute(self, node):
assert isinstance(node[0], pynodes.object_name)
name = node[0][0].data
if name != '__docformat__':
return
value = None
for child in children:
if isinstance(child, pynodes.expression_value):
value = child[0].data
break
assert value.startswith("'") or value.startswith('"'), "__docformat__ must be assigned a string literal (not %s); line: %s" % (value, node['lineno'])
name = name[1:-1]
looking_in = node.parent
while not isinstance(looking_in, (pynodes.module_section,
pynodes.function_section,
pynodes.class_section)):
looking_in = looking_in.parent
looking_in['docformat'] = name
class DocstringFormattingVisitor(nodes.SparseNodeVisitor):
def __init__(self, document, default_parser):
self.document = document
self.default_parser = default_parser
self.parsers = {}
def visit_docstring(self, node):
text = node[0].data
docformat = self.find_docformat(node)
del node[0]
node['docformat'] = docformat
parser = self.get_parser(docformat)
parser.parse(text, self.document)
for child in self.document.children:
node.append(child)
self.document.current_source = self.document.current_line = None
del self.document[:]
def get_parser(self, parser_name):
"""
Get a parser based on its name. We reuse parsers during this
visitation, so parser instances are cached.
"""
parser_name = parsers._parser_aliases.get(parser_name, parser_name)
if parser_name not in self.parsers:
cls = parsers.get_parser_class(parser_name)
self.parsers[parser_name] = cls()
return self.parsers[parser_name]
def find_docformat(self, node):
"""
Find the __docformat__ closest to this node (i.e., look in the
class or module)
"""
while node:
if node.get('docformat'):
return node['docformat']
node = node.parent
return self.default_parser
if __name__ == '__main__':
try:
import locale
locale.setlocale(locale.LC_ALL, '')
except:
pass
from docutils.core import publish_cmdline, default_description
description = ('Generates pseudo-XML from Python modules '
'(for testing purposes). ' + default_description)
publish_cmdline(description=description,
reader=Reader())
@@ -0,0 +1,757 @@
# $Id: moduleparser.py 5738 2008-11-30 08:59:04Z grubert $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
Parser for Python modules.
The `parse_module()` function takes a module's text and file name,
runs it through the module parser (using compiler.py and tokenize.py)
and produces a parse tree of the source code, using the nodes as found
in pynodes.py. For example, given this module (x.py)::
# comment
'''Docstring'''
'''Additional docstring'''
__docformat__ = 'reStructuredText'
a = 1
'''Attribute docstring'''
class C(Super):
'''C's docstring'''
class_attribute = 1
'''class_attribute's docstring'''
def __init__(self, text=None):
'''__init__'s docstring'''
self.instance_attribute = (text * 7
+ ' whaddyaknow')
'''instance_attribute's docstring'''
def f(x, # parameter x
y=a*5, # parameter y
*args): # parameter args
'''f's docstring'''
return [x + item for item in args]
f.function_attribute = 1
'''f.function_attribute's docstring'''
The module parser will produce this module documentation tree::
<module_section filename="test data">
<docstring>
Docstring
<docstring lineno="5">
Additional docstring
<attribute lineno="7">
<object_name>
__docformat__
<expression_value lineno="7">
'reStructuredText'
<attribute lineno="9">
<object_name>
a
<expression_value lineno="9">
1
<docstring lineno="10">
Attribute docstring
<class_section lineno="12">
<object_name>
C
<class_base>
Super
<docstring lineno="12">
C's docstring
<attribute lineno="16">
<object_name>
class_attribute
<expression_value lineno="16">
1
<docstring lineno="17">
class_attribute's docstring
<method_section lineno="19">
<object_name>
__init__
<docstring lineno="19">
__init__'s docstring
<parameter_list lineno="19">
<parameter lineno="19">
<object_name>
self
<parameter lineno="19">
<object_name>
text
<parameter_default lineno="19">
None
<attribute lineno="22">
<object_name>
self.instance_attribute
<expression_value lineno="22">
(text * 7 + ' whaddyaknow')
<docstring lineno="24">
instance_attribute's docstring
<function_section lineno="27">
<object_name>
f
<docstring lineno="27">
f's docstring
<parameter_list lineno="27">
<parameter lineno="27">
<object_name>
x
<comment>
# parameter x
<parameter lineno="27">
<object_name>
y
<parameter_default lineno="27">
a * 5
<comment>
# parameter y
<parameter excess_positional="1" lineno="27">
<object_name>
args
<comment>
# parameter args
<attribute lineno="33">
<object_name>
f.function_attribute
<expression_value lineno="33">
1
<docstring lineno="34">
f.function_attribute's docstring
(Comments are not implemented yet.)
compiler.parse() provides most of what's needed for this doctree, and
"tokenize" can be used to get the rest. We can determine the line
number from the compiler.parse() AST, and the TokenParser.rhs(lineno)
method provides the rest.
The Docutils Python reader component will transform this module doctree into a
Python-specific Docutils doctree, and then a "stylist transform" will
further transform it into a generic doctree. Namespaces will have to be
compiled for each of the scopes, but I'm not certain at what stage of
processing.
It's very important to keep all docstring processing out of this, so that it's
a completely generic and not tool-specific.
::
> Why perform all of those transformations? Why not go from the AST to a
> generic doctree? Or, even from the AST to the final output?
I want the docutils.readers.python.moduleparser.parse_module() function to
produce a standard documentation-oriented tree that can be used by any tool.
We can develop it together without having to compromise on the rest of our
design (i.e., HappyDoc doesn't have to be made to work like Docutils, and
vice-versa). It would be a higher-level version of what compiler.py provides.
The Python reader component transforms this generic AST into a Python-specific
doctree (it knows about modules, classes, functions, etc.), but this is
specific to Docutils and cannot be used by HappyDoc or others. The stylist
transform does the final layout, converting Python-specific structures
("class" sections, etc.) into a generic doctree using primitives (tables,
sections, lists, etc.). This generic doctree does *not* know about Python
structures any more. The advantage is that this doctree can be handed off to
any of the output writers to create any output format we like.
The latter two transforms are separate because I want to be able to have
multiple independent layout styles (multiple runtime-selectable "stylist
transforms"). Each of the existing tools (HappyDoc, pydoc, epydoc, Crystal,
etc.) has its own fixed format. I personally don't like the tables-based
format produced by these tools, and I'd like to be able to customize the
format easily. That's the goal of stylist transforms, which are independent
from the Reader component itself. One stylist transform could produce
HappyDoc-like output, another could produce output similar to module docs in
the Python library reference manual, and so on.
It's for exactly this reason::
>> It's very important to keep all docstring processing out of this, so that
>> it's a completely generic and not tool-specific.
... but it goes past docstring processing. It's also important to keep style
decisions and tool-specific data transforms out of this module parser.
Issues
======
* At what point should namespaces be computed? Should they be part of the
basic AST produced by the ASTVisitor walk, or generated by another tree
traversal?
* At what point should a distinction be made between local variables &
instance attributes in __init__ methods?
* Docstrings are getting their lineno from their parents. Should the
TokenParser find the real line no's?
* Comments: include them? How and when? Only full-line comments, or
parameter comments too? (See function "f" above for an example.)
* Module could use more docstrings & refactoring in places.
"""
__docformat__ = 'reStructuredText'
import sys
import compiler
import compiler.ast
import tokenize
import token
from compiler.consts import OP_ASSIGN
from compiler.visitor import ASTVisitor
from docutils.readers.python import pynodes
from docutils.nodes import Text
def parse_module(module_text, filename):
"""Return a module documentation tree from `module_text`."""
ast = compiler.parse(module_text)
token_parser = TokenParser(module_text)
visitor = ModuleVisitor(filename, token_parser)
compiler.walk(ast, visitor, walker=visitor)
return visitor.module
class BaseVisitor(ASTVisitor):
def __init__(self, token_parser):
ASTVisitor.__init__(self)
self.token_parser = token_parser
self.context = []
self.documentable = None
def default(self, node, *args):
self.documentable = None
#print 'in default (%s)' % node.__class__.__name__
#ASTVisitor.default(self, node, *args)
def default_visit(self, node, *args):
#print 'in default_visit (%s)' % node.__class__.__name__
ASTVisitor.default(self, node, *args)
class DocstringVisitor(BaseVisitor):
def visitDiscard(self, node):
if self.documentable:
self.visit(node.expr)
def visitConst(self, node):
if self.documentable:
if type(node.value) in (str, unicode):
self.documentable.append(make_docstring(node.value, node.lineno))
else:
self.documentable = None
def visitStmt(self, node):
self.default_visit(node)
class AssignmentVisitor(DocstringVisitor):
def visitAssign(self, node):
visitor = AttributeVisitor(self.token_parser)
compiler.walk(node, visitor, walker=visitor)
if visitor.attributes:
self.context[-1].extend(visitor.attributes)
if len(visitor.attributes) == 1:
self.documentable = visitor.attributes[0]
else:
self.documentable = None
class ModuleVisitor(AssignmentVisitor):
def __init__(self, filename, token_parser):
AssignmentVisitor.__init__(self, token_parser)
self.filename = filename
self.module = None
def visitModule(self, node):
self.module = module = pynodes.module_section()
module['filename'] = self.filename
append_docstring(module, node.doc, node.lineno)
self.context.append(module)
self.documentable = module
self.visit(node.node)
self.context.pop()
def visitImport(self, node):
self.context[-1] += make_import_group(names=node.names,
lineno=node.lineno)
self.documentable = None
def visitFrom(self, node):
self.context[-1].append(
make_import_group(names=node.names, from_name=node.modname,
lineno=node.lineno))
self.documentable = None
def visitFunction(self, node):
visitor = FunctionVisitor(self.token_parser,
function_class=pynodes.function_section)
compiler.walk(node, visitor, walker=visitor)
self.context[-1].append(visitor.function)
def visitClass(self, node):
visitor = ClassVisitor(self.token_parser)
compiler.walk(node, visitor, walker=visitor)
self.context[-1].append(visitor.klass)
class AttributeVisitor(BaseVisitor):
def __init__(self, token_parser):
BaseVisitor.__init__(self, token_parser)
self.attributes = pynodes.class_attribute_section()
def visitAssign(self, node):
# Don't visit the expression itself, just the attribute nodes:
for child in node.nodes:
self.dispatch(child)
expression_text = self.token_parser.rhs(node.lineno)
expression = pynodes.expression_value()
expression.append(Text(expression_text))
for attribute in self.attributes:
attribute.append(expression)
def visitAssName(self, node):
self.attributes.append(make_attribute(node.name,
lineno=node.lineno))
def visitAssTuple(self, node):
attributes = self.attributes
self.attributes = []
self.default_visit(node)
n = pynodes.attribute_tuple()
n.extend(self.attributes)
n['lineno'] = self.attributes[0]['lineno']
attributes.append(n)
self.attributes = attributes
#self.attributes.append(att_tuple)
def visitAssAttr(self, node):
self.default_visit(node, node.attrname)
def visitGetattr(self, node, suffix):
self.default_visit(node, node.attrname + '.' + suffix)
def visitName(self, node, suffix):
self.attributes.append(make_attribute(node.name + '.' + suffix,
lineno=node.lineno))
class FunctionVisitor(DocstringVisitor):
in_function = 0
def __init__(self, token_parser, function_class):
DocstringVisitor.__init__(self, token_parser)
self.function_class = function_class
def visitFunction(self, node):
if self.in_function:
self.documentable = None
# Don't bother with nested function definitions.
return
self.in_function = 1
self.function = function = make_function_like_section(
name=node.name,
lineno=node.lineno,
doc=node.doc,
function_class=self.function_class)
self.context.append(function)
self.documentable = function
self.parse_parameter_list(node)
self.visit(node.code)
self.context.pop()
def parse_parameter_list(self, node):
parameters = []
special = []
argnames = list(node.argnames)
if node.kwargs:
special.append(make_parameter(argnames[-1], excess_keyword=1))
argnames.pop()
if node.varargs:
special.append(make_parameter(argnames[-1],
excess_positional=1))
argnames.pop()
defaults = list(node.defaults)
defaults = [None] * (len(argnames) - len(defaults)) + defaults
function_parameters = self.token_parser.function_parameters(
node.lineno)
#print >>sys.stderr, function_parameters
for argname, default in zip(argnames, defaults):
if type(argname) is tuple:
parameter = pynodes.parameter_tuple()
for tuplearg in argname:
parameter.append(make_parameter(tuplearg))
argname = normalize_parameter_name(argname)
else:
parameter = make_parameter(argname)
if default:
n_default = pynodes.parameter_default()
n_default.append(Text(function_parameters[argname]))
parameter.append(n_default)
parameters.append(parameter)
if parameters or special:
special.reverse()
parameters.extend(special)
parameter_list = pynodes.parameter_list()
parameter_list.extend(parameters)
self.function.append(parameter_list)
class ClassVisitor(AssignmentVisitor):
in_class = 0
def __init__(self, token_parser):
AssignmentVisitor.__init__(self, token_parser)
self.bases = []
def visitClass(self, node):
if self.in_class:
self.documentable = None
# Don't bother with nested class definitions.
return
self.in_class = 1
#import mypdb as pdb
#pdb.set_trace()
for base in node.bases:
self.visit(base)
self.klass = klass = make_class_section(node.name, self.bases,
doc=node.doc,
lineno=node.lineno)
self.context.append(klass)
self.documentable = klass
self.visit(node.code)
self.context.pop()
def visitGetattr(self, node, suffix=None):
if suffix:
name = node.attrname + '.' + suffix
else:
name = node.attrname
self.default_visit(node, name)
def visitName(self, node, suffix=None):
if suffix:
name = node.name + '.' + suffix
else:
name = node.name
self.bases.append(name)
def visitFunction(self, node):
if node.name == '__init__':
visitor = InitMethodVisitor(self.token_parser,
function_class=pynodes.method_section)
compiler.walk(node, visitor, walker=visitor)
else:
visitor = FunctionVisitor(self.token_parser,
function_class=pynodes.method_section)
compiler.walk(node, visitor, walker=visitor)
self.context[-1].append(visitor.function)
class InitMethodVisitor(FunctionVisitor, AssignmentVisitor): pass
class TokenParser:
def __init__(self, text):
self.text = text + '\n\n'
self.lines = self.text.splitlines(1)
self.generator = tokenize.generate_tokens(iter(self.lines).next)
self.next()
def __iter__(self):
return self
def next(self):
self.token = self.generator.next()
self.type, self.string, self.start, self.end, self.line = self.token
return self.token
def goto_line(self, lineno):
while self.start[0] < lineno:
self.next()
return token
def rhs(self, lineno):
"""
Return a whitespace-normalized expression string from the right-hand
side of an assignment at line `lineno`.
"""
self.goto_line(lineno)
while self.string != '=':
self.next()
self.stack = None
while self.type != token.NEWLINE and self.string != ';':
if self.string == '=' and not self.stack:
self.tokens = []
self.stack = []
self._type = None
self._string = None
self._backquote = 0
else:
self.note_token()
self.next()
self.next()
text = ''.join(self.tokens)
return text.strip()
closers = {')': '(', ']': '[', '}': '{'}
openers = {'(': 1, '[': 1, '{': 1}
del_ws_prefix = {'.': 1, '=': 1, ')': 1, ']': 1, '}': 1, ':': 1, ',': 1}
no_ws_suffix = {'.': 1, '=': 1, '(': 1, '[': 1, '{': 1}
def note_token(self):
if self.type == tokenize.NL:
return
del_ws = self.string in self.del_ws_prefix
append_ws = self.string not in self.no_ws_suffix
if self.string in self.openers:
self.stack.append(self.string)
if (self._type == token.NAME
or self._string in self.closers):
del_ws = 1
elif self.string in self.closers:
assert self.stack[-1] == self.closers[self.string]
self.stack.pop()
elif self.string == '`':
if self._backquote:
del_ws = 1
assert self.stack[-1] == '`'
self.stack.pop()
else:
append_ws = 0
self.stack.append('`')
self._backquote = not self._backquote
if del_ws and self.tokens and self.tokens[-1] == ' ':
del self.tokens[-1]
self.tokens.append(self.string)
self._type = self.type
self._string = self.string
if append_ws:
self.tokens.append(' ')
def function_parameters(self, lineno):
"""
Return a dictionary mapping parameters to defaults
(whitespace-normalized strings).
"""
self.goto_line(lineno)
while self.string != 'def':
self.next()
while self.string != '(':
self.next()
name = None
default = None
parameter_tuple = None
self.tokens = []
parameters = {}
self.stack = [self.string]
self.next()
while 1:
if len(self.stack) == 1:
if parameter_tuple:
# Just encountered ")".
#print >>sys.stderr, 'parameter_tuple: %r' % self.tokens
name = ''.join(self.tokens).strip()
self.tokens = []
parameter_tuple = None
if self.string in (')', ','):
if name:
if self.tokens:
default_text = ''.join(self.tokens).strip()
else:
default_text = None
parameters[name] = default_text
self.tokens = []
name = None
default = None
if self.string == ')':
break
elif self.type == token.NAME:
if name and default:
self.note_token()
else:
assert name is None, (
'token=%r name=%r parameters=%r stack=%r'
% (self.token, name, parameters, self.stack))
name = self.string
#print >>sys.stderr, 'name=%r' % name
elif self.string == '=':
assert name is not None, 'token=%r' % (self.token,)
assert default is None, 'token=%r' % (self.token,)
assert self.tokens == [], 'token=%r' % (self.token,)
default = 1
self._type = None
self._string = None
self._backquote = 0
elif name:
self.note_token()
elif self.string == '(':
parameter_tuple = 1
self._type = None
self._string = None
self._backquote = 0
self.note_token()
else: # ignore these tokens:
assert (self.string in ('*', '**', '\n')
or self.type == tokenize.COMMENT), (
'token=%r' % (self.token,))
else:
self.note_token()
self.next()
return parameters
def make_docstring(doc, lineno):
n = pynodes.docstring()
if lineno:
# Really, only module docstrings don't have a line
# (@@: but maybe they should)
n['lineno'] = lineno
n.append(Text(doc))
return n
def append_docstring(node, doc, lineno):
if doc:
node.append(make_docstring(doc, lineno))
def make_class_section(name, bases, lineno, doc):
n = pynodes.class_section()
n['lineno'] = lineno
n.append(make_object_name(name))
for base in bases:
b = pynodes.class_base()
b.append(make_object_name(base))
n.append(b)
append_docstring(n, doc, lineno)
return n
def make_object_name(name):
n = pynodes.object_name()
n.append(Text(name))
return n
def make_function_like_section(name, lineno, doc, function_class):
n = function_class()
n['lineno'] = lineno
n.append(make_object_name(name))
append_docstring(n, doc, lineno)
return n
def make_import_group(names, lineno, from_name=None):
n = pynodes.import_group()
n['lineno'] = lineno
if from_name:
n_from = pynodes.import_from()
n_from.append(Text(from_name))
n.append(n_from)
for name, alias in names:
n_name = pynodes.import_name()
n_name.append(Text(name))
if alias:
n_alias = pynodes.import_alias()
n_alias.append(Text(alias))
n_name.append(n_alias)
n.append(n_name)
return n
def make_class_attribute(name, lineno):
n = pynodes.class_attribute()
n['lineno'] = lineno
n.append(Text(name))
return n
def make_attribute(name, lineno):
n = pynodes.attribute()
n['lineno'] = lineno
n.append(make_object_name(name))
return n
def make_parameter(name, excess_keyword=0, excess_positional=0):
"""
excess_keyword and excess_positional must be either 1 or 0, and
not both of them can be 1.
"""
n = pynodes.parameter()
n.append(make_object_name(name))
assert not excess_keyword or not excess_positional
if excess_keyword:
n['excess_keyword'] = 1
if excess_positional:
n['excess_positional'] = 1
return n
def trim_docstring(text):
"""
Trim indentation and blank lines from docstring text & return it.
See PEP 257.
"""
if not text:
return text
# Convert tabs to spaces (following the normal Python rules)
# and split into a list of lines:
lines = text.expandtabs().splitlines()
# Determine minimum indentation (first line doesn't count):
indent = sys.maxint
for line in lines[1:]:
stripped = line.lstrip()
if stripped:
indent = min(indent, len(line) - len(stripped))
# Remove indentation (first line is special):
trimmed = [lines[0].strip()]
if indent < sys.maxint:
for line in lines[1:]:
trimmed.append(line[indent:].rstrip())
# Strip off trailing and leading blank lines:
while trimmed and not trimmed[-1]:
trimmed.pop()
while trimmed and not trimmed[0]:
trimmed.pop(0)
# Return a single string:
return '\n'.join(trimmed)
def normalize_parameter_name(name):
"""
Converts a tuple like ``('a', ('b', 'c'), 'd')`` into ``'(a, (b, c), d)'``
"""
if type(name) is tuple:
return '(%s)' % ', '.join([normalize_parameter_name(n) for n in name])
else:
return name
if __name__ == '__main__':
import sys
args = sys.argv[1:]
if args[0] == '-v':
filename = args[1]
module_text = open(filename).read()
ast = compiler.parse(module_text)
visitor = compiler.visitor.ExampleASTVisitor()
compiler.walk(ast, visitor, walker=visitor, verbose=1)
else:
filename = args[0]
content = open(filename).read()
print parse_module(content, filename).pformat()
@@ -0,0 +1,81 @@
#! /usr/bin/env python
# $Id: pynodes.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
from docutils import nodes
from docutils.nodes import Element, TextElement, Structural, Inline, Part, \
Text
import types
# This is the parent class of all the other pynode classes:
class PythonStructural(Structural): pass
# =====================
# Structural Elements
# =====================
class module_section(PythonStructural, Element): pass
class class_section(PythonStructural, Element): pass
class class_base(PythonStructural, Element): pass
class method_section(PythonStructural, Element): pass
class attribute(PythonStructural, Element): pass
class function_section(PythonStructural, Element): pass
class class_attribute_section(PythonStructural, Element): pass
class class_attribute(PythonStructural, Element): pass
class expression_value(PythonStructural, Element): pass
class attribute(PythonStructural, Element): pass
# Structural Support Elements
# ---------------------------
class parameter_list(PythonStructural, Element): pass
class parameter_tuple(PythonStructural, Element): pass
class parameter_default(PythonStructural, TextElement): pass
class import_group(PythonStructural, TextElement): pass
class import_from(PythonStructural, TextElement): pass
class import_name(PythonStructural, TextElement): pass
class import_alias(PythonStructural, TextElement): pass
class docstring(PythonStructural, Element): pass
# =================
# Inline Elements
# =================
# These elements cannot become references until the second
# pass. Initially, we'll use "reference" or "name".
class object_name(PythonStructural, TextElement): pass
class parameter_list(PythonStructural, TextElement): pass
class parameter(PythonStructural, TextElement): pass
class parameter_default(PythonStructural, TextElement): pass
class class_attribute(PythonStructural, TextElement): pass
class attribute_tuple(PythonStructural, TextElement): pass
# =================
# Unused Elements
# =================
# These were part of the model, and maybe should be in the future, but
# aren't now.
#class package_section(PythonStructural, Element): pass
#class module_attribute_section(PythonStructural, Element): pass
#class instance_attribute_section(PythonStructural, Element): pass
#class module_attribute(PythonStructural, TextElement): pass
#class instance_attribute(PythonStructural, TextElement): pass
#class exception_class(PythonStructural, TextElement): pass
#class warning_class(PythonStructural, TextElement): pass
# Collect all the classes we've written above
def install_node_class_names():
node_class_names = []
for name, var in globals().items():
if (type(var) is types.ClassType
and issubclass(var, PythonStructural) \
and name.lower() == name):
node_class_names.append(var.tagname or name)
# Register the new node names with GenericNodeVisitor and
# SpecificNodeVisitor:
nodes._add_node_class_names(node_class_names)
install_node_class_names()
@@ -0,0 +1,66 @@
# $Id: standalone.py 4802 2006-11-12 18:02:17Z goodger $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
Standalone file Reader for the reStructuredText markup syntax.
"""
__docformat__ = 'reStructuredText'
import sys
from docutils import frontend, readers
from docutils.transforms import frontmatter, references, misc
class Reader(readers.Reader):
supported = ('standalone',)
"""Contexts this reader supports."""
document = None
"""A single document tree."""
settings_spec = (
'Standalone Reader',
None,
(('Disable the promotion of a lone top-level section title to '
'document title (and subsequent section title to document '
'subtitle promotion; enabled by default).',
['--no-doc-title'],
{'dest': 'doctitle_xform', 'action': 'store_false', 'default': 1,
'validator': frontend.validate_boolean}),
('Disable the bibliographic field list transform (enabled by '
'default).',
['--no-doc-info'],
{'dest': 'docinfo_xform', 'action': 'store_false', 'default': 1,
'validator': frontend.validate_boolean}),
('Activate the promotion of lone subsection titles to '
'section subtitles (disabled by default).',
['--section-subtitles'],
{'dest': 'sectsubtitle_xform', 'action': 'store_true', 'default': 0,
'validator': frontend.validate_boolean}),
('Deactivate the promotion of lone subsection titles.',
['--no-section-subtitles'],
{'dest': 'sectsubtitle_xform', 'action': 'store_false'}),
))
config_section = 'standalone reader'
config_section_dependencies = ('readers',)
def get_transforms(self):
return readers.Reader.get_transforms(self) + [
references.Substitutions,
references.PropagateTargets,
frontmatter.DocTitle,
frontmatter.SectionSubTitle,
frontmatter.DocInfo,
references.AnonymousHyperlinks,
references.IndirectHyperlinks,
references.Footnotes,
references.ExternalTargets,
references.InternalTargets,
references.DanglingReferences,
misc.Transitions,
]
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,172 @@
# $Id: __init__.py 4975 2007-03-01 18:08:32Z wiemann $
# Authors: David Goodger <goodger@python.org>; Ueli Schlaepfer
# Copyright: This module has been placed in the public domain.
"""
This package contains modules for standard tree transforms available
to Docutils components. Tree transforms serve a variety of purposes:
- To tie up certain syntax-specific "loose ends" that remain after the
initial parsing of the input plaintext. These transforms are used to
supplement a limited syntax.
- To automate the internal linking of the document tree (hyperlink
references, footnote references, etc.).
- To extract useful information from the document tree. These
transforms may be used to construct (for example) indexes and tables
of contents.
Each transform is an optional step that a Docutils component may
choose to perform on the parsed document.
"""
__docformat__ = 'reStructuredText'
from docutils import languages, ApplicationError, TransformSpec
class TransformError(ApplicationError): pass
class Transform:
"""
Docutils transform component abstract base class.
"""
default_priority = None
"""Numerical priority of this transform, 0 through 999 (override)."""
def __init__(self, document, startnode=None):
"""
Initial setup for in-place document transforms.
"""
self.document = document
"""The document tree to transform."""
self.startnode = startnode
"""Node from which to begin the transform. For many transforms which
apply to the document as a whole, `startnode` is not set (i.e. its
value is `None`)."""
self.language = languages.get_language(
document.settings.language_code)
"""Language module local to this document."""
def apply(self, **kwargs):
"""Override to apply the transform to the document tree."""
raise NotImplementedError('subclass must override this method')
class Transformer(TransformSpec):
"""
Stores transforms (`Transform` classes) and applies them to document
trees. Also keeps track of components by component type name.
"""
def __init__(self, document):
self.transforms = []
"""List of transforms to apply. Each item is a 3-tuple:
``(priority string, transform class, pending node or None)``."""
self.unknown_reference_resolvers = []
"""List of hook functions which assist in resolving references"""
self.document = document
"""The `nodes.document` object this Transformer is attached to."""
self.applied = []
"""Transforms already applied, in order."""
self.sorted = 0
"""Boolean: is `self.tranforms` sorted?"""
self.components = {}
"""Mapping of component type name to component object. Set by
`self.populate_from_components()`."""
self.serialno = 0
"""Internal serial number to keep track of the add order of
transforms."""
def add_transform(self, transform_class, priority=None, **kwargs):
"""
Store a single transform. Use `priority` to override the default.
`kwargs` is a dictionary whose contents are passed as keyword
arguments to the `apply` method of the transform. This can be used to
pass application-specific data to the transform instance.
"""
if priority is None:
priority = transform_class.default_priority
priority_string = self.get_priority_string(priority)
self.transforms.append(
(priority_string, transform_class, None, kwargs))
self.sorted = 0
def add_transforms(self, transform_list):
"""Store multiple transforms, with default priorities."""
for transform_class in transform_list:
priority_string = self.get_priority_string(
transform_class.default_priority)
self.transforms.append(
(priority_string, transform_class, None, {}))
self.sorted = 0
def add_pending(self, pending, priority=None):
"""Store a transform with an associated `pending` node."""
transform_class = pending.transform
if priority is None:
priority = transform_class.default_priority
priority_string = self.get_priority_string(priority)
self.transforms.append(
(priority_string, transform_class, pending, {}))
self.sorted = 0
def get_priority_string(self, priority):
"""
Return a string, `priority` combined with `self.serialno`.
This ensures FIFO order on transforms with identical priority.
"""
self.serialno += 1
return '%03d-%03d' % (priority, self.serialno)
def populate_from_components(self, components):
"""
Store each component's default transforms, with default priorities.
Also, store components by type name in a mapping for later lookup.
"""
for component in components:
if component is None:
continue
self.add_transforms(component.get_transforms())
self.components[component.component_type] = component
self.sorted = 0
# Set up all of the reference resolvers for this transformer. Each
# component of this transformer is able to register its own helper
# functions to help resolve references.
unknown_reference_resolvers = []
for i in components:
unknown_reference_resolvers.extend(i.unknown_reference_resolvers)
decorated_list = [(f.priority, f) for f in unknown_reference_resolvers]
decorated_list.sort()
self.unknown_reference_resolvers.extend([f[1] for f in decorated_list])
def apply_transforms(self):
"""Apply all of the stored transforms, in priority order."""
self.document.reporter.attach_observer(
self.document.note_transform_message)
while self.transforms:
if not self.sorted:
# Unsorted initially, and whenever a transform is added.
self.transforms.sort()
self.transforms.reverse()
self.sorted = 1
priority, transform_class, pending, kwargs = self.transforms.pop()
transform = transform_class(self.document, startnode=pending)
transform.apply(**kwargs)
self.applied.append((priority, transform_class, pending, kwargs))
@@ -0,0 +1,52 @@
# $Id: components.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
Docutils component-related transforms.
"""
__docformat__ = 'reStructuredText'
import sys
import os
import re
import time
from docutils import nodes, utils
from docutils import ApplicationError, DataError
from docutils.transforms import Transform, TransformError
class Filter(Transform):
"""
Include or exclude elements which depend on a specific Docutils component.
For use with `nodes.pending` elements. A "pending" element's dictionary
attribute ``details`` must contain the keys "component" and "format". The
value of ``details['component']`` must match the type name of the
component the elements depend on (e.g. "writer"). The value of
``details['format']`` is the name of a specific format or context of that
component (e.g. "html"). If the matching Docutils component supports that
format or context, the "pending" element is replaced by the contents of
``details['nodes']`` (a list of nodes); otherwise, the "pending" element
is removed.
For example, the reStructuredText "meta" directive creates a "pending"
element containing a "meta" element (in ``pending.details['nodes']``).
Only writers (``pending.details['component'] == 'writer'``) supporting the
"html" format (``pending.details['format'] == 'html'``) will include the
"meta" element; it will be deleted from the output of all other writers.
"""
default_priority = 780
def apply(self):
pending = self.startnode
component_type = pending.details['component'] # 'reader' or 'writer'
format = pending.details['format']
component = self.document.transformer.components[component_type]
if component.supports(format):
pending.replace_self(pending.details['nodes'])
else:
pending.parent.remove(pending)
@@ -0,0 +1,512 @@
# $Id: frontmatter.py 5618 2008-07-28 08:37:32Z strank $
# Author: David Goodger, Ueli Schlaepfer <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
Transforms related to the front matter of a document or a section
(information found before the main text):
- `DocTitle`: Used to transform a lone top level section's title to
the document title, promote a remaining lone top-level section's
title to the document subtitle, and determine the document's title
metadata (document['title']) based on the document title and/or the
"title" setting.
- `SectionSubTitle`: Used to transform a lone subsection into a
subtitle.
- `DocInfo`: Used to transform a bibliographic field list into docinfo
elements.
"""
__docformat__ = 'reStructuredText'
import re
from docutils import nodes, utils
from docutils.transforms import TransformError, Transform
class TitlePromoter(Transform):
"""
Abstract base class for DocTitle and SectionSubTitle transforms.
"""
def promote_title(self, node):
"""
Transform the following tree::
<node>
<section>
<title>
...
into ::
<node>
<title>
...
`node` is normally a document.
"""
# `node` must not have a title yet.
assert not (len(node) and isinstance(node[0], nodes.title))
section, index = self.candidate_index(node)
if index is None:
return None
# Transfer the section's attributes to the node:
node.attributes.update(section.attributes)
# setup_child is called automatically for all nodes.
node[:] = (section[:1] # section title
+ node[:index] # everything that was in the
# node before the section
+ section[1:]) # everything that was in the section
assert isinstance(node[0], nodes.title)
return 1
def promote_subtitle(self, node):
"""
Transform the following node tree::
<node>
<title>
<section>
<title>
...
into ::
<node>
<title>
<subtitle>
...
"""
subsection, index = self.candidate_index(node)
if index is None:
return None
subtitle = nodes.subtitle()
# Transfer the subsection's attributes to the new subtitle:
# This causes trouble with list attributes! To do: Write a
# test case which catches direct access to the `attributes`
# dictionary and/or write a test case which shows problems in
# this particular case.
subtitle.attributes.update(subsection.attributes)
# We're losing the subtitle's attributes here! To do: Write a
# test case which shows this behavior.
# Transfer the contents of the subsection's title to the
# subtitle:
subtitle[:] = subsection[0][:]
node[:] = (node[:1] # title
+ [subtitle]
# everything that was before the section:
+ node[1:index]
# everything that was in the subsection:
+ subsection[1:])
return 1
def candidate_index(self, node):
"""
Find and return the promotion candidate and its index.
Return (None, None) if no valid candidate was found.
"""
index = node.first_child_not_matching_class(
nodes.PreBibliographic)
if index is None or len(node) > (index + 1) or \
not isinstance(node[index], nodes.section):
return None, None
else:
return node[index], index
class DocTitle(TitlePromoter):
"""
In reStructuredText_, there is no way to specify a document title
and subtitle explicitly. Instead, we can supply the document title
(and possibly the subtitle as well) implicitly, and use this
two-step transform to "raise" or "promote" the title(s) (and their
corresponding section contents) to the document level.
1. If the document contains a single top-level section as its
first non-comment element, the top-level section's title
becomes the document's title, and the top-level section's
contents become the document's immediate contents. The lone
top-level section header must be the first non-comment element
in the document.
For example, take this input text::
=================
Top-Level Title
=================
A paragraph.
Once parsed, it looks like this::
<document>
<section names="top-level title">
<title>
Top-Level Title
<paragraph>
A paragraph.
After running the DocTitle transform, we have::
<document names="top-level title">
<title>
Top-Level Title
<paragraph>
A paragraph.
2. If step 1 successfully determines the document title, we
continue by checking for a subtitle.
If the lone top-level section itself contains a single
second-level section as its first non-comment element, that
section's title is promoted to the document's subtitle, and
that section's contents become the document's immediate
contents. Given this input text::
=================
Top-Level Title
=================
Second-Level Title
~~~~~~~~~~~~~~~~~~
A paragraph.
After parsing and running the Section Promotion transform, the
result is::
<document names="top-level title">
<title>
Top-Level Title
<subtitle names="second-level title">
Second-Level Title
<paragraph>
A paragraph.
(Note that the implicit hyperlink target generated by the
"Second-Level Title" is preserved on the "subtitle" element
itself.)
Any comment elements occurring before the document title or
subtitle are accumulated and inserted as the first body elements
after the title(s).
This transform also sets the document's metadata title
(document['title']).
.. _reStructuredText: http://docutils.sf.net/rst.html
"""
default_priority = 320
def set_metadata(self):
"""
Set document['title'] metadata title from the following
sources, listed in order of priority:
* Existing document['title'] attribute.
* "title" setting.
* Document title node (as promoted by promote_title).
"""
if not self.document.hasattr('title'):
if self.document.settings.title is not None:
self.document['title'] = self.document.settings.title
elif len(self.document) and isinstance(self.document[0], nodes.title):
self.document['title'] = self.document[0].astext()
def apply(self):
if getattr(self.document.settings, 'doctitle_xform', 1):
# promote_(sub)title defined in TitlePromoter base class.
if self.promote_title(self.document):
# If a title has been promoted, also try to promote a
# subtitle.
self.promote_subtitle(self.document)
# Set document['title'].
self.set_metadata()
class SectionSubTitle(TitlePromoter):
"""
This works like document subtitles, but for sections. For example, ::
<section>
<title>
Title
<section>
<title>
Subtitle
...
is transformed into ::
<section>
<title>
Title
<subtitle>
Subtitle
...
For details refer to the docstring of DocTitle.
"""
default_priority = 350
def apply(self):
if not getattr(self.document.settings, 'sectsubtitle_xform', 1):
return
for section in self.document.traverse(nodes.section):
# On our way through the node tree, we are deleting
# sections, but we call self.promote_subtitle for those
# sections nonetheless. To do: Write a test case which
# shows the problem and discuss on Docutils-develop.
self.promote_subtitle(section)
class DocInfo(Transform):
"""
This transform is specific to the reStructuredText_ markup syntax;
see "Bibliographic Fields" in the `reStructuredText Markup
Specification`_ for a high-level description. This transform
should be run *after* the `DocTitle` transform.
Given a field list as the first non-comment element after the
document title and subtitle (if present), registered bibliographic
field names are transformed to the corresponding DTD elements,
becoming child elements of the "docinfo" element (except for a
dedication and/or an abstract, which become "topic" elements after
"docinfo").
For example, given this document fragment after parsing::
<document>
<title>
Document Title
<field_list>
<field>
<field_name>
Author
<field_body>
<paragraph>
A. Name
<field>
<field_name>
Status
<field_body>
<paragraph>
$RCSfile$
...
After running the bibliographic field list transform, the
resulting document tree would look like this::
<document>
<title>
Document Title
<docinfo>
<author>
A. Name
<status>
frontmatter.py
...
The "Status" field contained an expanded RCS keyword, which is
normally (but optionally) cleaned up by the transform. The sole
contents of the field body must be a paragraph containing an
expanded RCS keyword of the form "$keyword: expansion text $". Any
RCS keyword can be processed in any bibliographic field. The
dollar signs and leading RCS keyword name are removed. Extra
processing is done for the following RCS keywords:
- "RCSfile" expands to the name of the file in the RCS or CVS
repository, which is the name of the source file with a ",v"
suffix appended. The transform will remove the ",v" suffix.
- "Date" expands to the format "YYYY/MM/DD hh:mm:ss" (in the UTC
time zone). The RCS Keywords transform will extract just the
date itself and transform it to an ISO 8601 format date, as in
"2000-12-31".
(Since the source file for this text is itself stored under CVS,
we can't show an example of the "Date" RCS keyword because we
can't prevent any RCS keywords used in this explanation from
being expanded. Only the "RCSfile" keyword is stable; its
expansion text changes only if the file name changes.)
.. _reStructuredText: http://docutils.sf.net/rst.html
.. _reStructuredText Markup Specification:
http://docutils.sf.net/docs/ref/rst/restructuredtext.html
"""
default_priority = 340
biblio_nodes = {
'author': nodes.author,
'authors': nodes.authors,
'organization': nodes.organization,
'address': nodes.address,
'contact': nodes.contact,
'version': nodes.version,
'revision': nodes.revision,
'status': nodes.status,
'date': nodes.date,
'copyright': nodes.copyright,
'dedication': nodes.topic,
'abstract': nodes.topic}
"""Canonical field name (lowcased) to node class name mapping for
bibliographic fields (field_list)."""
def apply(self):
if not getattr(self.document.settings, 'docinfo_xform', 1):
return
document = self.document
index = document.first_child_not_matching_class(
nodes.PreBibliographic)
if index is None:
return
candidate = document[index]
if isinstance(candidate, nodes.field_list):
biblioindex = document.first_child_not_matching_class(
(nodes.Titular, nodes.Decorative))
nodelist = self.extract_bibliographic(candidate)
del document[index] # untransformed field list (candidate)
document[biblioindex:biblioindex] = nodelist
def extract_bibliographic(self, field_list):
docinfo = nodes.docinfo()
bibliofields = self.language.bibliographic_fields
labels = self.language.labels
topics = {'dedication': None, 'abstract': None}
for field in field_list:
try:
name = field[0][0].astext()
normedname = nodes.fully_normalize_name(name)
if not (len(field) == 2 and normedname in bibliofields
and self.check_empty_biblio_field(field, name)):
raise TransformError
canonical = bibliofields[normedname]
biblioclass = self.biblio_nodes[canonical]
if issubclass(biblioclass, nodes.TextElement):
if not self.check_compound_biblio_field(field, name):
raise TransformError
utils.clean_rcs_keywords(
field[1][0], self.rcs_keyword_substitutions)
docinfo.append(biblioclass('', '', *field[1][0]))
elif issubclass(biblioclass, nodes.authors):
self.extract_authors(field, name, docinfo)
elif issubclass(biblioclass, nodes.topic):
if topics[canonical]:
field[-1] += self.document.reporter.warning(
'There can only be one "%s" field.' % name,
base_node=field)
raise TransformError
title = nodes.title(name, labels[canonical])
topics[canonical] = biblioclass(
'', title, classes=[canonical], *field[1].children)
else:
docinfo.append(biblioclass('', *field[1].children))
except TransformError:
if len(field[-1]) == 1 \
and isinstance(field[-1][0], nodes.paragraph):
utils.clean_rcs_keywords(
field[-1][0], self.rcs_keyword_substitutions)
docinfo.append(field)
nodelist = []
if len(docinfo) != 0:
nodelist.append(docinfo)
for name in ('dedication', 'abstract'):
if topics[name]:
nodelist.append(topics[name])
return nodelist
def check_empty_biblio_field(self, field, name):
if len(field[-1]) < 1:
field[-1] += self.document.reporter.warning(
'Cannot extract empty bibliographic field "%s".' % name,
base_node=field)
return None
return 1
def check_compound_biblio_field(self, field, name):
if len(field[-1]) > 1:
field[-1] += self.document.reporter.warning(
'Cannot extract compound bibliographic field "%s".' % name,
base_node=field)
return None
if not isinstance(field[-1][0], nodes.paragraph):
field[-1] += self.document.reporter.warning(
'Cannot extract bibliographic field "%s" containing '
'anything other than a single paragraph.' % name,
base_node=field)
return None
return 1
rcs_keyword_substitutions = [
(re.compile(r'\$' r'Date: (\d\d\d\d)[-/](\d\d)[-/](\d\d)[ T][\d:]+'
r'[^$]* \$', re.IGNORECASE), r'\1-\2-\3'),
(re.compile(r'\$' r'RCSfile: (.+),v \$', re.IGNORECASE), r'\1'),
(re.compile(r'\$[a-zA-Z]+: (.+) \$'), r'\1'),]
def extract_authors(self, field, name, docinfo):
try:
if len(field[1]) == 1:
if isinstance(field[1][0], nodes.paragraph):
authors = self.authors_from_one_paragraph(field)
elif isinstance(field[1][0], nodes.bullet_list):
authors = self.authors_from_bullet_list(field)
else:
raise TransformError
else:
authors = self.authors_from_paragraphs(field)
authornodes = [nodes.author('', '', *author)
for author in authors if author]
if len(authornodes) >= 1:
docinfo.append(nodes.authors('', *authornodes))
else:
raise TransformError
except TransformError:
field[-1] += self.document.reporter.warning(
'Bibliographic field "%s" incompatible with extraction: '
'it must contain either a single paragraph (with authors '
'separated by one of "%s"), multiple paragraphs (one per '
'author), or a bullet list with one paragraph (one author) '
'per item.'
% (name, ''.join(self.language.author_separators)),
base_node=field)
raise
def authors_from_one_paragraph(self, field):
text = field[1][0].astext().strip()
if not text:
raise TransformError
for authorsep in self.language.author_separators:
authornames = text.split(authorsep)
if len(authornames) > 1:
break
authornames = [author.strip() for author in authornames]
authors = [[nodes.Text(author)] for author in authornames if author]
return authors
def authors_from_bullet_list(self, field):
authors = []
for item in field[1][0]:
if len(item) != 1 or not isinstance(item[0], nodes.paragraph):
raise TransformError
authors.append(item[0].children)
if not authors:
raise TransformError
return authors
def authors_from_paragraphs(self, field):
for item in field[1]:
if not isinstance(item, nodes.paragraph):
raise TransformError
authors = [item.children for item in field[1]]
return authors
+144
View File
@@ -0,0 +1,144 @@
# $Id: misc.py 6314 2010-04-26 10:04:17Z milde $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
Miscellaneous transforms.
"""
__docformat__ = 'reStructuredText'
from docutils import nodes
from docutils.transforms import Transform, TransformError
class CallBack(Transform):
"""
Inserts a callback into a document. The callback is called when the
transform is applied, which is determined by its priority.
For use with `nodes.pending` elements. Requires a ``details['callback']``
entry, a bound method or function which takes one parameter: the pending
node. Other data can be stored in the ``details`` attribute or in the
object hosting the callback method.
"""
default_priority = 990
def apply(self):
pending = self.startnode
pending.details['callback'](pending)
pending.parent.remove(pending)
class ClassAttribute(Transform):
"""
Move the "class" attribute specified in the "pending" node into the
immediately following non-comment element.
"""
default_priority = 210
def apply(self):
pending = self.startnode
parent = pending.parent
child = pending
while parent:
# Check for appropriate following siblings:
for index in range(parent.index(child) + 1, len(parent)):
element = parent[index]
if (isinstance(element, nodes.Invisible) or
isinstance(element, nodes.system_message)):
continue
element['classes'] += pending.details['class']
pending.parent.remove(pending)
return
else:
# At end of section or container; apply to sibling
child = parent
parent = parent.parent
error = self.document.reporter.error(
'No suitable element following "%s" directive'
% pending.details['directive'],
nodes.literal_block(pending.rawsource, pending.rawsource),
line=pending.line)
pending.replace_self(error)
class Transitions(Transform):
"""
Move transitions at the end of sections up the tree. Complain
on transitions after a title, at the beginning or end of the
document, and after another transition.
For example, transform this::
<section>
...
<transition>
<section>
...
into this::
<section>
...
<transition>
<section>
...
"""
default_priority = 830
def apply(self):
for node in self.document.traverse(nodes.transition):
self.visit_transition(node)
def visit_transition(self, node):
index = node.parent.index(node)
error = None
if (index == 0 or
isinstance(node.parent[0], nodes.title) and
(index == 1 or
isinstance(node.parent[1], nodes.subtitle) and
index == 2)):
assert (isinstance(node.parent, nodes.document) or
isinstance(node.parent, nodes.section))
error = self.document.reporter.error(
'Document or section may not begin with a transition.',
source=node.source, line=node.line)
elif isinstance(node.parent[index - 1], nodes.transition):
error = self.document.reporter.error(
'At least one body element must separate transitions; '
'adjacent transitions are not allowed.',
source=node.source, line=node.line)
if error:
# Insert before node and update index.
node.parent.insert(index, error)
index += 1
assert index < len(node.parent)
if index != len(node.parent) - 1:
# No need to move the node.
return
# Node behind which the transition is to be moved.
sibling = node
# While sibling is the last node of its parent.
while index == len(sibling.parent) - 1:
sibling = sibling.parent
# If sibling is the whole document (i.e. it has no parent).
if sibling.parent is None:
# Transition at the end of document. Do not move the
# transition up, and place an error behind.
error = self.document.reporter.error(
'Document may not end with a transition.',
line=node.line)
node.parent.insert(node.parent.index(node) + 1, error)
return
index = sibling.parent.index(sibling)
# Remove the original transition node.
node.parent.remove(node)
# Insert the transition after the sibling.
sibling.parent.insert(index + 1, node)
+180
View File
@@ -0,0 +1,180 @@
# $Id: parts.py 6073 2009-08-06 12:21:10Z milde $
# Authors: David Goodger <goodger@python.org>; Ueli Schlaepfer; Dmitry Jemerov
# Copyright: This module has been placed in the public domain.
"""
Transforms related to document parts.
"""
__docformat__ = 'reStructuredText'
import re
import sys
from docutils import nodes, utils
from docutils.transforms import TransformError, Transform
class SectNum(Transform):
"""
Automatically assigns numbers to the titles of document sections.
It is possible to limit the maximum section level for which the numbers
are added. For those sections that are auto-numbered, the "autonum"
attribute is set, informing the contents table generator that a different
form of the TOC should be used.
"""
default_priority = 710
"""Should be applied before `Contents`."""
def apply(self):
self.maxdepth = self.startnode.details.get('depth', None)
self.startvalue = self.startnode.details.get('start', 1)
self.prefix = self.startnode.details.get('prefix', '')
self.suffix = self.startnode.details.get('suffix', '')
self.startnode.parent.remove(self.startnode)
if self.document.settings.sectnum_xform:
if self.maxdepth is None:
self.maxdepth = sys.maxint
self.update_section_numbers(self.document)
else: # store details for eventual section numbering by the writer
self.document.settings.sectnum_depth = self.maxdepth
self.document.settings.sectnum_start = self.startvalue
self.document.settings.sectnum_prefix = self.prefix
self.document.settings.sectnum_suffix = self.suffix
def update_section_numbers(self, node, prefix=(), depth=0):
depth += 1
if prefix:
sectnum = 1
else:
sectnum = self.startvalue
for child in node:
if isinstance(child, nodes.section):
numbers = prefix + (str(sectnum),)
title = child[0]
# Use &nbsp; for spacing:
generated = nodes.generated(
'', (self.prefix + '.'.join(numbers) + self.suffix
+ u'\u00a0' * 3),
classes=['sectnum'])
title.insert(0, generated)
title['auto'] = 1
if depth < self.maxdepth:
self.update_section_numbers(child, numbers, depth)
sectnum += 1
class Contents(Transform):
"""
This transform generates a table of contents from the entire document tree
or from a single branch. It locates "section" elements and builds them
into a nested bullet list, which is placed within a "topic" created by the
contents directive. A title is either explicitly specified, taken from
the appropriate language module, or omitted (local table of contents).
The depth may be specified. Two-way references between the table of
contents and section titles are generated (requires Writer support).
This transform requires a startnode, which contains generation
options and provides the location for the generated table of contents (the
startnode is replaced by the table of contents "topic").
"""
default_priority = 720
def apply(self):
try: # let the writer (or output software) build the contents list?
toc_by_writer = self.document.settings.use_latex_toc
except AttributeError:
toc_by_writer = False
details = self.startnode.details
if 'local' in details:
startnode = self.startnode.parent.parent
while not (isinstance(startnode, nodes.section)
or isinstance(startnode, nodes.document)):
# find the ToC root: a direct ancestor of startnode
startnode = startnode.parent
else:
startnode = self.document
self.toc_id = self.startnode.parent['ids'][0]
if 'backlinks' in details:
self.backlinks = details['backlinks']
else:
self.backlinks = self.document.settings.toc_backlinks
if toc_by_writer:
# move customization settings to the parent node
self.startnode.parent.attributes.update(details)
self.startnode.parent.remove(self.startnode)
else:
contents = self.build_contents(startnode)
if len(contents):
self.startnode.replace_self(contents)
else:
self.startnode.parent.parent.remove(self.startnode.parent)
def build_contents(self, node, level=0):
level += 1
sections = [sect for sect in node if isinstance(sect, nodes.section)]
entries = []
autonum = 0
depth = self.startnode.details.get('depth', sys.maxint)
for section in sections:
title = section[0]
auto = title.get('auto') # May be set by SectNum.
entrytext = self.copy_and_filter(title)
reference = nodes.reference('', '', refid=section['ids'][0],
*entrytext)
ref_id = self.document.set_id(reference)
entry = nodes.paragraph('', '', reference)
item = nodes.list_item('', entry)
if ( self.backlinks in ('entry', 'top')
and title.next_node(nodes.reference) is None):
if self.backlinks == 'entry':
title['refid'] = ref_id
elif self.backlinks == 'top':
title['refid'] = self.toc_id
if level < depth:
subsects = self.build_contents(section, level)
item += subsects
entries.append(item)
if entries:
contents = nodes.bullet_list('', *entries)
if auto:
contents['classes'].append('auto-toc')
return contents
else:
return []
def copy_and_filter(self, node):
"""Return a copy of a title, with references, images, etc. removed."""
visitor = ContentsFilter(self.document)
node.walkabout(visitor)
return visitor.get_entry_text()
class ContentsFilter(nodes.TreeCopyVisitor):
def get_entry_text(self):
return self.get_tree_copy().children
def visit_citation_reference(self, node):
raise nodes.SkipNode
def visit_footnote_reference(self, node):
raise nodes.SkipNode
def visit_image(self, node):
if node.hasattr('alt'):
self.parent.append(nodes.Text(node['alt']))
raise nodes.SkipNode
def ignore_node_but_process_children(self, node):
raise nodes.SkipDeparture
visit_interpreted = ignore_node_but_process_children
visit_problematic = ignore_node_but_process_children
visit_reference = ignore_node_but_process_children
visit_target = ignore_node_but_process_children
+304
View File
@@ -0,0 +1,304 @@
# $Id: peps.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
Transforms for PEP processing.
- `Headers`: Used to transform a PEP's initial RFC-2822 header. It remains a
field list, but some entries get processed.
- `Contents`: Auto-inserts a table of contents.
- `PEPZero`: Special processing for PEP 0.
"""
__docformat__ = 'reStructuredText'
import sys
import os
import re
import time
from docutils import nodes, utils, languages
from docutils import ApplicationError, DataError
from docutils.transforms import Transform, TransformError
from docutils.transforms import parts, references, misc
class Headers(Transform):
"""
Process fields in a PEP's initial RFC-2822 header.
"""
default_priority = 360
pep_url = 'pep-%04d'
pep_cvs_url = ('http://svn.python.org/view/*checkout*'
'/peps/trunk/pep-%04d.txt')
rcs_keyword_substitutions = (
(re.compile(r'\$' r'RCSfile: (.+),v \$$', re.IGNORECASE), r'\1'),
(re.compile(r'\$[a-zA-Z]+: (.+) \$$'), r'\1'),)
def apply(self):
if not len(self.document):
# @@@ replace these DataErrors with proper system messages
raise DataError('Document tree is empty.')
header = self.document[0]
if not isinstance(header, nodes.field_list) or \
'rfc2822' not in header['classes']:
raise DataError('Document does not begin with an RFC-2822 '
'header; it is not a PEP.')
pep = None
for field in header:
if field[0].astext().lower() == 'pep': # should be the first field
value = field[1].astext()
try:
pep = int(value)
cvs_url = self.pep_cvs_url % pep
except ValueError:
pep = value
cvs_url = None
msg = self.document.reporter.warning(
'"PEP" header must contain an integer; "%s" is an '
'invalid value.' % pep, base_node=field)
msgid = self.document.set_id(msg)
prb = nodes.problematic(value, value or '(none)',
refid=msgid)
prbid = self.document.set_id(prb)
msg.add_backref(prbid)
if len(field[1]):
field[1][0][:] = [prb]
else:
field[1] += nodes.paragraph('', '', prb)
break
if pep is None:
raise DataError('Document does not contain an RFC-2822 "PEP" '
'header.')
if pep == 0:
# Special processing for PEP 0.
pending = nodes.pending(PEPZero)
self.document.insert(1, pending)
self.document.note_pending(pending)
if len(header) < 2 or header[1][0].astext().lower() != 'title':
raise DataError('No title!')
for field in header:
name = field[0].astext().lower()
body = field[1]
if len(body) > 1:
raise DataError('PEP header field body contains multiple '
'elements:\n%s' % field.pformat(level=1))
elif len(body) == 1:
if not isinstance(body[0], nodes.paragraph):
raise DataError('PEP header field body may only contain '
'a single paragraph:\n%s'
% field.pformat(level=1))
elif name == 'last-modified':
date = time.strftime(
'%d-%b-%Y',
time.localtime(os.stat(self.document['source'])[8]))
if cvs_url:
body += nodes.paragraph(
'', '', nodes.reference('', date, refuri=cvs_url))
else:
# empty
continue
para = body[0]
if name == 'author':
for node in para:
if isinstance(node, nodes.reference):
node.replace_self(mask_email(node))
elif name == 'discussions-to':
for node in para:
if isinstance(node, nodes.reference):
node.replace_self(mask_email(node, pep))
elif name in ('replaces', 'replaced-by', 'requires'):
newbody = []
space = nodes.Text(' ')
for refpep in re.split(',?\s+', body.astext()):
pepno = int(refpep)
newbody.append(nodes.reference(
refpep, refpep,
refuri=(self.document.settings.pep_base_url
+ self.pep_url % pepno)))
newbody.append(space)
para[:] = newbody[:-1] # drop trailing space
elif name == 'last-modified':
utils.clean_rcs_keywords(para, self.rcs_keyword_substitutions)
if cvs_url:
date = para.astext()
para[:] = [nodes.reference('', date, refuri=cvs_url)]
elif name == 'content-type':
pep_type = para.astext()
uri = self.document.settings.pep_base_url + self.pep_url % 12
para[:] = [nodes.reference('', pep_type, refuri=uri)]
elif name == 'version' and len(body):
utils.clean_rcs_keywords(para, self.rcs_keyword_substitutions)
class Contents(Transform):
"""
Insert an empty table of contents topic and a transform placeholder into
the document after the RFC 2822 header.
"""
default_priority = 380
def apply(self):
language = languages.get_language(self.document.settings.language_code)
name = language.labels['contents']
title = nodes.title('', name)
topic = nodes.topic('', title, classes=['contents'])
name = nodes.fully_normalize_name(name)
if not self.document.has_name(name):
topic['names'].append(name)
self.document.note_implicit_target(topic)
pending = nodes.pending(parts.Contents)
topic += pending
self.document.insert(1, topic)
self.document.note_pending(pending)
class TargetNotes(Transform):
"""
Locate the "References" section, insert a placeholder for an external
target footnote insertion transform at the end, and schedule the
transform to run immediately.
"""
default_priority = 520
def apply(self):
doc = self.document
i = len(doc) - 1
refsect = copyright = None
while i >= 0 and isinstance(doc[i], nodes.section):
title_words = doc[i][0].astext().lower().split()
if 'references' in title_words:
refsect = doc[i]
break
elif 'copyright' in title_words:
copyright = i
i -= 1
if not refsect:
refsect = nodes.section()
refsect += nodes.title('', 'References')
doc.set_id(refsect)
if copyright:
# Put the new "References" section before "Copyright":
doc.insert(copyright, refsect)
else:
# Put the new "References" section at end of doc:
doc.append(refsect)
pending = nodes.pending(references.TargetNotes)
refsect.append(pending)
self.document.note_pending(pending, 0)
pending = nodes.pending(misc.CallBack,
details={'callback': self.cleanup_callback})
refsect.append(pending)
self.document.note_pending(pending, 1)
def cleanup_callback(self, pending):
"""
Remove an empty "References" section.
Called after the `references.TargetNotes` transform is complete.
"""
if len(pending.parent) == 2: # <title> and <pending>
pending.parent.parent.remove(pending.parent)
class PEPZero(Transform):
"""
Special processing for PEP 0.
"""
default_priority =760
def apply(self):
visitor = PEPZeroSpecial(self.document)
self.document.walk(visitor)
self.startnode.parent.remove(self.startnode)
class PEPZeroSpecial(nodes.SparseNodeVisitor):
"""
Perform the special processing needed by PEP 0:
- Mask email addresses.
- Link PEP numbers in the second column of 4-column tables to the PEPs
themselves.
"""
pep_url = Headers.pep_url
def unknown_visit(self, node):
pass
def visit_reference(self, node):
node.replace_self(mask_email(node))
def visit_field_list(self, node):
if 'rfc2822' in node['classes']:
raise nodes.SkipNode
def visit_tgroup(self, node):
self.pep_table = node['cols'] == 4
self.entry = 0
def visit_colspec(self, node):
self.entry += 1
if self.pep_table and self.entry == 2:
node['classes'].append('num')
def visit_row(self, node):
self.entry = 0
def visit_entry(self, node):
self.entry += 1
if self.pep_table and self.entry == 2 and len(node) == 1:
node['classes'].append('num')
p = node[0]
if isinstance(p, nodes.paragraph) and len(p) == 1:
text = p.astext()
try:
pep = int(text)
ref = (self.document.settings.pep_base_url
+ self.pep_url % pep)
p[0] = nodes.reference(text, text, refuri=ref)
except ValueError:
pass
non_masked_addresses = ('peps@python.org',
'python-list@python.org',
'python-dev@python.org')
def mask_email(ref, pepno=None):
"""
Mask the email address in `ref` and return a replacement node.
`ref` is returned unchanged if it contains no email address.
For email addresses such as "user@host", mask the address as "user at
host" (text) to thwart simple email address harvesters (except for those
listed in `non_masked_addresses`). If a PEP number (`pepno`) is given,
return a reference including a default email subject.
"""
if ref.hasattr('refuri') and ref['refuri'].startswith('mailto:'):
if ref['refuri'][8:] in non_masked_addresses:
replacement = ref[0]
else:
replacement_text = ref.astext().replace('@', '&#32;&#97;t&#32;')
replacement = nodes.raw('', replacement_text, format='html')
if pepno is None:
return replacement
else:
ref['refuri'] += '?subject=PEP%%20%s' % pepno
ref[:] = [replacement]
return ref
else:
return ref
@@ -0,0 +1,904 @@
# $Id: references.py 6167 2009-10-11 14:51:42Z grubert $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
Transforms for resolving references.
"""
__docformat__ = 'reStructuredText'
import sys
import re
from docutils import nodes, utils
from docutils.transforms import TransformError, Transform
class PropagateTargets(Transform):
"""
Propagate empty internal targets to the next element.
Given the following nodes::
<target ids="internal1" names="internal1">
<target anonymous="1" ids="id1">
<target ids="internal2" names="internal2">
<paragraph>
This is a test.
PropagateTargets propagates the ids and names of the internal
targets preceding the paragraph to the paragraph itself::
<target refid="internal1">
<target anonymous="1" refid="id1">
<target refid="internal2">
<paragraph ids="internal2 id1 internal1" names="internal2 internal1">
This is a test.
"""
default_priority = 260
def apply(self):
for target in self.document.traverse(nodes.target):
# Only block-level targets without reference (like ".. target:"):
if (isinstance(target.parent, nodes.TextElement) or
(target.hasattr('refid') or target.hasattr('refuri') or
target.hasattr('refname'))):
continue
assert len(target) == 0, 'error: block-level target has children'
next_node = target.next_node(ascend=1)
# Do not move names and ids into Invisibles (we'd lose the
# attributes) or different Targetables (e.g. footnotes).
if (next_node is not None and
((not isinstance(next_node, nodes.Invisible) and
not isinstance(next_node, nodes.Targetable)) or
isinstance(next_node, nodes.target))):
next_node['ids'].extend(target['ids'])
next_node['names'].extend(target['names'])
# Set defaults for next_node.expect_referenced_by_name/id.
if not hasattr(next_node, 'expect_referenced_by_name'):
next_node.expect_referenced_by_name = {}
if not hasattr(next_node, 'expect_referenced_by_id'):
next_node.expect_referenced_by_id = {}
for id in target['ids']:
# Update IDs to node mapping.
self.document.ids[id] = next_node
# If next_node is referenced by id ``id``, this
# target shall be marked as referenced.
next_node.expect_referenced_by_id[id] = target
for name in target['names']:
next_node.expect_referenced_by_name[name] = target
# If there are any expect_referenced_by_... attributes
# in target set, copy them to next_node.
next_node.expect_referenced_by_name.update(
getattr(target, 'expect_referenced_by_name', {}))
next_node.expect_referenced_by_id.update(
getattr(target, 'expect_referenced_by_id', {}))
# Set refid to point to the first former ID of target
# which is now an ID of next_node.
target['refid'] = target['ids'][0]
# Clear ids and names; they have been moved to
# next_node.
target['ids'] = []
target['names'] = []
self.document.note_refid(target)
class AnonymousHyperlinks(Transform):
"""
Link anonymous references to targets. Given::
<paragraph>
<reference anonymous="1">
internal
<reference anonymous="1">
external
<target anonymous="1" ids="id1">
<target anonymous="1" ids="id2" refuri="http://external">
Corresponding references are linked via "refid" or resolved via "refuri"::
<paragraph>
<reference anonymous="1" refid="id1">
text
<reference anonymous="1" refuri="http://external">
external
<target anonymous="1" ids="id1">
<target anonymous="1" ids="id2" refuri="http://external">
"""
default_priority = 440
def apply(self):
anonymous_refs = []
anonymous_targets = []
for node in self.document.traverse(nodes.reference):
if node.get('anonymous'):
anonymous_refs.append(node)
for node in self.document.traverse(nodes.target):
if node.get('anonymous'):
anonymous_targets.append(node)
if len(anonymous_refs) \
!= len(anonymous_targets):
msg = self.document.reporter.error(
'Anonymous hyperlink mismatch: %s references but %s '
'targets.\nSee "backrefs" attribute for IDs.'
% (len(anonymous_refs), len(anonymous_targets)))
msgid = self.document.set_id(msg)
for ref in anonymous_refs:
prb = nodes.problematic(
ref.rawsource, ref.rawsource, refid=msgid)
prbid = self.document.set_id(prb)
msg.add_backref(prbid)
ref.replace_self(prb)
return
for ref, target in zip(anonymous_refs, anonymous_targets):
target.referenced = 1
while 1:
if target.hasattr('refuri'):
ref['refuri'] = target['refuri']
ref.resolved = 1
break
else:
if not target['ids']:
# Propagated target.
target = self.document.ids[target['refid']]
continue
ref['refid'] = target['ids'][0]
self.document.note_refid(ref)
break
class IndirectHyperlinks(Transform):
"""
a) Indirect external references::
<paragraph>
<reference refname="indirect external">
indirect external
<target id="id1" name="direct external"
refuri="http://indirect">
<target id="id2" name="indirect external"
refname="direct external">
The "refuri" attribute is migrated back to all indirect targets
from the final direct target (i.e. a target not referring to
another indirect target)::
<paragraph>
<reference refname="indirect external">
indirect external
<target id="id1" name="direct external"
refuri="http://indirect">
<target id="id2" name="indirect external"
refuri="http://indirect">
Once the attribute is migrated, the preexisting "refname" attribute
is dropped.
b) Indirect internal references::
<target id="id1" name="final target">
<paragraph>
<reference refname="indirect internal">
indirect internal
<target id="id2" name="indirect internal 2"
refname="final target">
<target id="id3" name="indirect internal"
refname="indirect internal 2">
Targets which indirectly refer to an internal target become one-hop
indirect (their "refid" attributes are directly set to the internal
target's "id"). References which indirectly refer to an internal
target become direct internal references::
<target id="id1" name="final target">
<paragraph>
<reference refid="id1">
indirect internal
<target id="id2" name="indirect internal 2" refid="id1">
<target id="id3" name="indirect internal" refid="id1">
"""
default_priority = 460
def apply(self):
for target in self.document.indirect_targets:
if not target.resolved:
self.resolve_indirect_target(target)
self.resolve_indirect_references(target)
def resolve_indirect_target(self, target):
refname = target.get('refname')
if refname is None:
reftarget_id = target['refid']
else:
reftarget_id = self.document.nameids.get(refname)
if not reftarget_id:
# Check the unknown_reference_resolvers
for resolver_function in \
self.document.transformer.unknown_reference_resolvers:
if resolver_function(target):
break
else:
self.nonexistent_indirect_target(target)
return
reftarget = self.document.ids[reftarget_id]
reftarget.note_referenced_by(id=reftarget_id)
if isinstance(reftarget, nodes.target) \
and not reftarget.resolved and reftarget.hasattr('refname'):
if hasattr(target, 'multiply_indirect'):
#and target.multiply_indirect):
#del target.multiply_indirect
self.circular_indirect_reference(target)
return
target.multiply_indirect = 1
self.resolve_indirect_target(reftarget) # multiply indirect
del target.multiply_indirect
if reftarget.hasattr('refuri'):
target['refuri'] = reftarget['refuri']
if 'refid' in target:
del target['refid']
elif reftarget.hasattr('refid'):
target['refid'] = reftarget['refid']
self.document.note_refid(target)
else:
if reftarget['ids']:
target['refid'] = reftarget_id
self.document.note_refid(target)
else:
self.nonexistent_indirect_target(target)
return
if refname is not None:
del target['refname']
target.resolved = 1
def nonexistent_indirect_target(self, target):
if target['refname'] in self.document.nameids:
self.indirect_target_error(target, 'which is a duplicate, and '
'cannot be used as a unique reference')
else:
self.indirect_target_error(target, 'which does not exist')
def circular_indirect_reference(self, target):
self.indirect_target_error(target, 'forming a circular reference')
def indirect_target_error(self, target, explanation):
naming = ''
reflist = []
if target['names']:
naming = '"%s" ' % target['names'][0]
for name in target['names']:
reflist.extend(self.document.refnames.get(name, []))
for id in target['ids']:
reflist.extend(self.document.refids.get(id, []))
naming += '(id="%s")' % target['ids'][0]
msg = self.document.reporter.error(
'Indirect hyperlink target %s refers to target "%s", %s.'
% (naming, target['refname'], explanation), base_node=target)
msgid = self.document.set_id(msg)
for ref in utils.uniq(reflist):
prb = nodes.problematic(
ref.rawsource, ref.rawsource, refid=msgid)
prbid = self.document.set_id(prb)
msg.add_backref(prbid)
ref.replace_self(prb)
target.resolved = 1
def resolve_indirect_references(self, target):
if target.hasattr('refid'):
attname = 'refid'
call_method = self.document.note_refid
elif target.hasattr('refuri'):
attname = 'refuri'
call_method = None
else:
return
attval = target[attname]
for name in target['names']:
reflist = self.document.refnames.get(name, [])
if reflist:
target.note_referenced_by(name=name)
for ref in reflist:
if ref.resolved:
continue
del ref['refname']
ref[attname] = attval
if call_method:
call_method(ref)
ref.resolved = 1
if isinstance(ref, nodes.target):
self.resolve_indirect_references(ref)
for id in target['ids']:
reflist = self.document.refids.get(id, [])
if reflist:
target.note_referenced_by(id=id)
for ref in reflist:
if ref.resolved:
continue
del ref['refid']
ref[attname] = attval
if call_method:
call_method(ref)
ref.resolved = 1
if isinstance(ref, nodes.target):
self.resolve_indirect_references(ref)
class ExternalTargets(Transform):
"""
Given::
<paragraph>
<reference refname="direct external">
direct external
<target id="id1" name="direct external" refuri="http://direct">
The "refname" attribute is replaced by the direct "refuri" attribute::
<paragraph>
<reference refuri="http://direct">
direct external
<target id="id1" name="direct external" refuri="http://direct">
"""
default_priority = 640
def apply(self):
for target in self.document.traverse(nodes.target):
if target.hasattr('refuri'):
refuri = target['refuri']
for name in target['names']:
reflist = self.document.refnames.get(name, [])
if reflist:
target.note_referenced_by(name=name)
for ref in reflist:
if ref.resolved:
continue
del ref['refname']
ref['refuri'] = refuri
ref.resolved = 1
class InternalTargets(Transform):
default_priority = 660
def apply(self):
for target in self.document.traverse(nodes.target):
if not target.hasattr('refuri') and not target.hasattr('refid'):
self.resolve_reference_ids(target)
def resolve_reference_ids(self, target):
"""
Given::
<paragraph>
<reference refname="direct internal">
direct internal
<target id="id1" name="direct internal">
The "refname" attribute is replaced by "refid" linking to the target's
"id"::
<paragraph>
<reference refid="id1">
direct internal
<target id="id1" name="direct internal">
"""
for name in target['names']:
refid = self.document.nameids[name]
reflist = self.document.refnames.get(name, [])
if reflist:
target.note_referenced_by(name=name)
for ref in reflist:
if ref.resolved:
continue
del ref['refname']
ref['refid'] = refid
ref.resolved = 1
class Footnotes(Transform):
"""
Assign numbers to autonumbered footnotes, and resolve links to footnotes,
citations, and their references.
Given the following ``document`` as input::
<document>
<paragraph>
A labeled autonumbered footnote referece:
<footnote_reference auto="1" id="id1" refname="footnote">
<paragraph>
An unlabeled autonumbered footnote referece:
<footnote_reference auto="1" id="id2">
<footnote auto="1" id="id3">
<paragraph>
Unlabeled autonumbered footnote.
<footnote auto="1" id="footnote" name="footnote">
<paragraph>
Labeled autonumbered footnote.
Auto-numbered footnotes have attribute ``auto="1"`` and no label.
Auto-numbered footnote_references have no reference text (they're
empty elements). When resolving the numbering, a ``label`` element
is added to the beginning of the ``footnote``, and reference text
to the ``footnote_reference``.
The transformed result will be::
<document>
<paragraph>
A labeled autonumbered footnote referece:
<footnote_reference auto="1" id="id1" refid="footnote">
2
<paragraph>
An unlabeled autonumbered footnote referece:
<footnote_reference auto="1" id="id2" refid="id3">
1
<footnote auto="1" id="id3" backrefs="id2">
<label>
1
<paragraph>
Unlabeled autonumbered footnote.
<footnote auto="1" id="footnote" name="footnote" backrefs="id1">
<label>
2
<paragraph>
Labeled autonumbered footnote.
Note that the footnotes are not in the same order as the references.
The labels and reference text are added to the auto-numbered ``footnote``
and ``footnote_reference`` elements. Footnote elements are backlinked to
their references via "refids" attributes. References are assigned "id"
and "refid" attributes.
After adding labels and reference text, the "auto" attributes can be
ignored.
"""
default_priority = 620
autofootnote_labels = None
"""Keep track of unlabeled autonumbered footnotes."""
symbols = [
# Entries 1-4 and 6 below are from section 12.51 of
# The Chicago Manual of Style, 14th edition.
'*', # asterisk/star
u'\u2020', # dagger &dagger;
u'\u2021', # double dagger &Dagger;
u'\u00A7', # section mark &sect;
u'\u00B6', # paragraph mark (pilcrow) &para;
# (parallels ['||'] in CMoS)
'#', # number sign
# The entries below were chosen arbitrarily.
u'\u2660', # spade suit &spades;
u'\u2665', # heart suit &hearts;
u'\u2666', # diamond suit &diams;
u'\u2663', # club suit &clubs;
]
def apply(self):
self.autofootnote_labels = []
startnum = self.document.autofootnote_start
self.document.autofootnote_start = self.number_footnotes(startnum)
self.number_footnote_references(startnum)
self.symbolize_footnotes()
self.resolve_footnotes_and_citations()
def number_footnotes(self, startnum):
"""
Assign numbers to autonumbered footnotes.
For labeled autonumbered footnotes, copy the number over to
corresponding footnote references.
"""
for footnote in self.document.autofootnotes:
while 1:
label = str(startnum)
startnum += 1
if label not in self.document.nameids:
break
footnote.insert(0, nodes.label('', label))
for name in footnote['names']:
for ref in self.document.footnote_refs.get(name, []):
ref += nodes.Text(label)
ref.delattr('refname')
assert len(footnote['ids']) == len(ref['ids']) == 1
ref['refid'] = footnote['ids'][0]
footnote.add_backref(ref['ids'][0])
self.document.note_refid(ref)
ref.resolved = 1
if not footnote['names'] and not footnote['dupnames']:
footnote['names'].append(label)
self.document.note_explicit_target(footnote, footnote)
self.autofootnote_labels.append(label)
return startnum
def number_footnote_references(self, startnum):
"""Assign numbers to autonumbered footnote references."""
i = 0
for ref in self.document.autofootnote_refs:
if ref.resolved or ref.hasattr('refid'):
continue
try:
label = self.autofootnote_labels[i]
except IndexError:
msg = self.document.reporter.error(
'Too many autonumbered footnote references: only %s '
'corresponding footnotes available.'
% len(self.autofootnote_labels), base_node=ref)
msgid = self.document.set_id(msg)
for ref in self.document.autofootnote_refs[i:]:
if ref.resolved or ref.hasattr('refname'):
continue
prb = nodes.problematic(
ref.rawsource, ref.rawsource, refid=msgid)
prbid = self.document.set_id(prb)
msg.add_backref(prbid)
ref.replace_self(prb)
break
ref += nodes.Text(label)
id = self.document.nameids[label]
footnote = self.document.ids[id]
ref['refid'] = id
self.document.note_refid(ref)
assert len(ref['ids']) == 1
footnote.add_backref(ref['ids'][0])
ref.resolved = 1
i += 1
def symbolize_footnotes(self):
"""Add symbols indexes to "[*]"-style footnotes and references."""
labels = []
for footnote in self.document.symbol_footnotes:
reps, index = divmod(self.document.symbol_footnote_start,
len(self.symbols))
labeltext = self.symbols[index] * (reps + 1)
labels.append(labeltext)
footnote.insert(0, nodes.label('', labeltext))
self.document.symbol_footnote_start += 1
self.document.set_id(footnote)
i = 0
for ref in self.document.symbol_footnote_refs:
try:
ref += nodes.Text(labels[i])
except IndexError:
msg = self.document.reporter.error(
'Too many symbol footnote references: only %s '
'corresponding footnotes available.' % len(labels),
base_node=ref)
msgid = self.document.set_id(msg)
for ref in self.document.symbol_footnote_refs[i:]:
if ref.resolved or ref.hasattr('refid'):
continue
prb = nodes.problematic(
ref.rawsource, ref.rawsource, refid=msgid)
prbid = self.document.set_id(prb)
msg.add_backref(prbid)
ref.replace_self(prb)
break
footnote = self.document.symbol_footnotes[i]
assert len(footnote['ids']) == 1
ref['refid'] = footnote['ids'][0]
self.document.note_refid(ref)
footnote.add_backref(ref['ids'][0])
i += 1
def resolve_footnotes_and_citations(self):
"""
Link manually-labeled footnotes and citations to/from their
references.
"""
for footnote in self.document.footnotes:
for label in footnote['names']:
if label in self.document.footnote_refs:
reflist = self.document.footnote_refs[label]
self.resolve_references(footnote, reflist)
for citation in self.document.citations:
for label in citation['names']:
if label in self.document.citation_refs:
reflist = self.document.citation_refs[label]
self.resolve_references(citation, reflist)
def resolve_references(self, note, reflist):
assert len(note['ids']) == 1
id = note['ids'][0]
for ref in reflist:
if ref.resolved:
continue
ref.delattr('refname')
ref['refid'] = id
assert len(ref['ids']) == 1
note.add_backref(ref['ids'][0])
ref.resolved = 1
note.resolved = 1
class CircularSubstitutionDefinitionError(Exception): pass
class Substitutions(Transform):
"""
Given the following ``document`` as input::
<document>
<paragraph>
The
<substitution_reference refname="biohazard">
biohazard
symbol is deservedly scary-looking.
<substitution_definition name="biohazard">
<image alt="biohazard" uri="biohazard.png">
The ``substitution_reference`` will simply be replaced by the
contents of the corresponding ``substitution_definition``.
The transformed result will be::
<document>
<paragraph>
The
<image alt="biohazard" uri="biohazard.png">
symbol is deservedly scary-looking.
<substitution_definition name="biohazard">
<image alt="biohazard" uri="biohazard.png">
"""
default_priority = 220
"""The Substitutions transform has to be applied very early, before
`docutils.tranforms.frontmatter.DocTitle` and others."""
def apply(self):
defs = self.document.substitution_defs
normed = self.document.substitution_names
subreflist = self.document.traverse(nodes.substitution_reference)
nested = {}
for ref in subreflist:
refname = ref['refname']
key = None
if refname in defs:
key = refname
else:
normed_name = refname.lower()
if normed_name in normed:
key = normed[normed_name]
if key is None:
msg = self.document.reporter.error(
'Undefined substitution referenced: "%s".'
% refname, base_node=ref)
msgid = self.document.set_id(msg)
prb = nodes.problematic(
ref.rawsource, ref.rawsource, refid=msgid)
prbid = self.document.set_id(prb)
msg.add_backref(prbid)
ref.replace_self(prb)
else:
subdef = defs[key]
parent = ref.parent
index = parent.index(ref)
if ('ltrim' in subdef.attributes
or 'trim' in subdef.attributes):
if index > 0 and isinstance(parent[index - 1],
nodes.Text):
parent.replace(parent[index - 1],
parent[index - 1].rstrip())
if ('rtrim' in subdef.attributes
or 'trim' in subdef.attributes):
if (len(parent) > index + 1
and isinstance(parent[index + 1], nodes.Text)):
parent.replace(parent[index + 1],
parent[index + 1].lstrip())
subdef_copy = subdef.deepcopy()
try:
# Take care of nested substitution references:
for nested_ref in subdef_copy.traverse(
nodes.substitution_reference):
nested_name = normed[nested_ref['refname'].lower()]
if nested_name in nested.setdefault(nested_name, []):
raise CircularSubstitutionDefinitionError
else:
nested[nested_name].append(key)
subreflist.append(nested_ref)
except CircularSubstitutionDefinitionError:
parent = ref.parent
if isinstance(parent, nodes.substitution_definition):
msg = self.document.reporter.error(
'Circular substitution definition detected:',
nodes.literal_block(parent.rawsource,
parent.rawsource),
line=parent.line, base_node=parent)
parent.replace_self(msg)
else:
msg = self.document.reporter.error(
'Circular substitution definition referenced: "%s".'
% refname, base_node=ref)
msgid = self.document.set_id(msg)
prb = nodes.problematic(
ref.rawsource, ref.rawsource, refid=msgid)
prbid = self.document.set_id(prb)
msg.add_backref(prbid)
ref.replace_self(prb)
else:
ref.replace_self(subdef_copy.children)
# register refname of the replacment node(s)
# (needed for resolution of references)
for node in subdef_copy.children:
if isinstance(node, nodes.Referential):
# HACK: verify refname attribute exists.
# Test with docs/dev/todo.txt, see. |donate|
if 'refname' in node:
self.document.note_refname(node)
class TargetNotes(Transform):
"""
Creates a footnote for each external target in the text, and corresponding
footnote references after each reference.
"""
default_priority = 540
"""The TargetNotes transform has to be applied after `IndirectHyperlinks`
but before `Footnotes`."""
def __init__(self, document, startnode):
Transform.__init__(self, document, startnode=startnode)
self.classes = startnode.details.get('class', [])
def apply(self):
notes = {}
nodelist = []
for target in self.document.traverse(nodes.target):
# Only external targets.
if not target.hasattr('refuri'):
continue
names = target['names']
refs = []
for name in names:
refs.extend(self.document.refnames.get(name, []))
if not refs:
continue
footnote = self.make_target_footnote(target['refuri'], refs,
notes)
if target['refuri'] not in notes:
notes[target['refuri']] = footnote
nodelist.append(footnote)
# Take care of anonymous references.
for ref in self.document.traverse(nodes.reference):
if not ref.get('anonymous'):
continue
if ref.hasattr('refuri'):
footnote = self.make_target_footnote(ref['refuri'], [ref],
notes)
if ref['refuri'] not in notes:
notes[ref['refuri']] = footnote
nodelist.append(footnote)
self.startnode.replace_self(nodelist)
def make_target_footnote(self, refuri, refs, notes):
if refuri in notes: # duplicate?
footnote = notes[refuri]
assert len(footnote['names']) == 1
footnote_name = footnote['names'][0]
else: # original
footnote = nodes.footnote()
footnote_id = self.document.set_id(footnote)
# Use uppercase letters and a colon; they can't be
# produced inside names by the parser.
footnote_name = 'TARGET_NOTE: ' + footnote_id
footnote['auto'] = 1
footnote['names'] = [footnote_name]
footnote_paragraph = nodes.paragraph()
footnote_paragraph += nodes.reference('', refuri, refuri=refuri)
footnote += footnote_paragraph
self.document.note_autofootnote(footnote)
self.document.note_explicit_target(footnote, footnote)
for ref in refs:
if isinstance(ref, nodes.target):
continue
refnode = nodes.footnote_reference(
refname=footnote_name, auto=1)
refnode['classes'] += self.classes
self.document.note_autofootnote_ref(refnode)
self.document.note_footnote_ref(refnode)
index = ref.parent.index(ref) + 1
reflist = [refnode]
if not utils.get_trim_footnote_ref_space(self.document.settings):
if self.classes:
reflist.insert(0, nodes.inline(text=' ', Classes=self.classes))
else:
reflist.insert(0, nodes.Text(' '))
ref.parent.insert(index, reflist)
return footnote
class DanglingReferences(Transform):
"""
Check for dangling references (incl. footnote & citation) and for
unreferenced targets.
"""
default_priority = 850
def apply(self):
visitor = DanglingReferencesVisitor(
self.document,
self.document.transformer.unknown_reference_resolvers)
self.document.walk(visitor)
# *After* resolving all references, check for unreferenced
# targets:
for target in self.document.traverse(nodes.target):
if not target.referenced:
if target.get('anonymous'):
# If we have unreferenced anonymous targets, there
# is already an error message about anonymous
# hyperlink mismatch; no need to generate another
# message.
continue
if target['names']:
naming = target['names'][0]
elif target['ids']:
naming = target['ids'][0]
else:
# Hack: Propagated targets always have their refid
# attribute set.
naming = target['refid']
self.document.reporter.info(
'Hyperlink target "%s" is not referenced.'
% naming, base_node=target)
class DanglingReferencesVisitor(nodes.SparseNodeVisitor):
def __init__(self, document, unknown_reference_resolvers):
nodes.SparseNodeVisitor.__init__(self, document)
self.document = document
self.unknown_reference_resolvers = unknown_reference_resolvers
def unknown_visit(self, node):
pass
def visit_reference(self, node):
if node.resolved or not node.hasattr('refname'):
return
refname = node['refname']
id = self.document.nameids.get(refname)
if id is None:
for resolver_function in self.unknown_reference_resolvers:
if resolver_function(node):
break
else:
if refname in self.document.nameids:
msg = self.document.reporter.error(
'Duplicate target name, cannot be used as a unique '
'reference: "%s".' % (node['refname']), base_node=node)
else:
msg = self.document.reporter.error(
'Unknown target name: "%s".' % (node['refname']),
base_node=node)
msgid = self.document.set_id(msg)
prb = nodes.problematic(
node.rawsource, node.rawsource, refid=msgid)
prbid = self.document.set_id(prb)
msg.add_backref(prbid)
node.replace_self(prb)
else:
del node['refname']
node['refid'] = id
self.document.ids[id].note_referenced_by(id=id)
node.resolved = 1
visit_footnote_reference = visit_citation_reference = visit_reference
@@ -0,0 +1,203 @@
# $Id: universal.py 6112 2009-09-03 07:27:59Z milde $
# Authors: David Goodger <goodger@python.org>; Ueli Schlaepfer
# Copyright: This module has been placed in the public domain.
"""
Transforms needed by most or all documents:
- `Decorations`: Generate a document's header & footer.
- `Messages`: Placement of system messages stored in
`nodes.document.transform_messages`.
- `TestMessages`: Like `Messages`, used on test runs.
- `FinalReferences`: Resolve remaining references.
"""
__docformat__ = 'reStructuredText'
import re
import sys
import time
from docutils import nodes, utils
from docutils.transforms import TransformError, Transform
class Decorations(Transform):
"""
Populate a document's decoration element (header, footer).
"""
default_priority = 820
def apply(self):
header_nodes = self.generate_header()
if header_nodes:
decoration = self.document.get_decoration()
header = decoration.get_header()
header.extend(header_nodes)
footer_nodes = self.generate_footer()
if footer_nodes:
decoration = self.document.get_decoration()
footer = decoration.get_footer()
footer.extend(footer_nodes)
def generate_header(self):
return None
def generate_footer(self):
# @@@ Text is hard-coded for now.
# Should be made dynamic (language-dependent).
settings = self.document.settings
if settings.generator or settings.datestamp or settings.source_link \
or settings.source_url:
text = []
if settings.source_link and settings._source \
or settings.source_url:
if settings.source_url:
source = settings.source_url
else:
source = utils.relative_path(settings._destination,
settings._source)
text.extend([
nodes.reference('', 'View document source',
refuri=source),
nodes.Text('.\n')])
if settings.datestamp:
datestamp = time.strftime(settings.datestamp, time.gmtime())
text.append(nodes.Text('Generated on: ' + datestamp + '.\n'))
if settings.generator:
text.extend([
nodes.Text('Generated by '),
nodes.reference('', 'Docutils', refuri=
'http://docutils.sourceforge.net/'),
nodes.Text(' from '),
nodes.reference('', 'reStructuredText', refuri='http://'
'docutils.sourceforge.net/rst.html'),
nodes.Text(' source.\n')])
return [nodes.paragraph('', '', *text)]
else:
return None
class ExposeInternals(Transform):
"""
Expose internal attributes if ``expose_internals`` setting is set.
"""
default_priority = 840
def not_Text(self, node):
return not isinstance(node, nodes.Text)
def apply(self):
if self.document.settings.expose_internals:
for node in self.document.traverse(self.not_Text):
for att in self.document.settings.expose_internals:
value = getattr(node, att, None)
if value is not None:
node['internal:' + att] = value
class Messages(Transform):
"""
Place any system messages generated after parsing into a dedicated section
of the document.
"""
default_priority = 860
def apply(self):
unfiltered = self.document.transform_messages
threshold = self.document.reporter.report_level
messages = []
for msg in unfiltered:
if msg['level'] >= threshold and not msg.parent:
messages.append(msg)
if messages:
section = nodes.section(classes=['system-messages'])
# @@@ get this from the language module?
section += nodes.title('', 'Docutils System Messages')
section += messages
self.document.transform_messages[:] = []
self.document += section
class FilterMessages(Transform):
"""
Remove system messages below verbosity threshold.
"""
default_priority = 870
def apply(self):
for node in self.document.traverse(nodes.system_message):
if node['level'] < self.document.reporter.report_level:
node.parent.remove(node)
class TestMessages(Transform):
"""
Append all post-parse system messages to the end of the document.
Used for testing purposes.
"""
default_priority = 880
def apply(self):
for msg in self.document.transform_messages:
if not msg.parent:
self.document += msg
class StripComments(Transform):
"""
Remove comment elements from the document tree (only if the
``strip_comments`` setting is enabled).
"""
default_priority = 740
def apply(self):
if self.document.settings.strip_comments:
for node in self.document.traverse(nodes.comment):
node.parent.remove(node)
class StripClassesAndElements(Transform):
"""
Remove from the document tree all elements with classes in
`self.document.settings.strip_elements_with_classes` and all "classes"
attribute values in `self.document.settings.strip_classes`.
"""
default_priority = 420
def apply(self):
if not (self.document.settings.strip_elements_with_classes
or self.document.settings.strip_classes):
return
# prepare dicts for lookup (not sets, for Python 2.2 compatibility):
self.strip_elements = dict(
[(key, None)
for key in (self.document.settings.strip_elements_with_classes
or [])])
self.strip_classes = dict(
[(key, None) for key in (self.document.settings.strip_classes
or [])])
for node in self.document.traverse(self.check_classes):
node.parent.remove(node)
def check_classes(self, node):
if isinstance(node, nodes.Element):
for class_value in node['classes'][:]:
if class_value in self.strip_classes:
node['classes'].remove(class_value)
if class_value in self.strip_elements:
return 1
@@ -0,0 +1,88 @@
# $Id: writer_aux.py 5174 2007-05-31 00:01:52Z wiemann $
# Author: Lea Wiemann <LeWiemann@gmail.com>
# Copyright: This module has been placed in the public domain.
"""
Auxiliary transforms mainly to be used by Writer components.
This module is called "writer_aux" because otherwise there would be
conflicting imports like this one::
from docutils import writers
from docutils.transforms import writers
"""
__docformat__ = 'reStructuredText'
from docutils import nodes, utils, languages
from docutils.transforms import Transform
class Compound(Transform):
"""
Flatten all compound paragraphs. For example, transform ::
<compound>
<paragraph>
<literal_block>
<paragraph>
into ::
<paragraph>
<literal_block classes="continued">
<paragraph classes="continued">
"""
default_priority = 910
def apply(self):
for compound in self.document.traverse(nodes.compound):
first_child = 1
for child in compound:
if first_child:
if not isinstance(child, nodes.Invisible):
first_child = 0
else:
child['classes'].append('continued')
# Substitute children for compound.
compound.replace_self(compound[:])
class Admonitions(Transform):
"""
Transform specific admonitions, like this:
<note>
<paragraph>
Note contents ...
into generic admonitions, like this::
<admonition classes="note">
<title>
Note
<paragraph>
Note contents ...
The admonition title is localized.
"""
default_priority = 920
def apply(self):
lcode = self.document.settings.language_code
language = languages.get_language(lcode)
for node in self.document.traverse(nodes.Admonition):
node_name = node.__class__.__name__
# Set class, so that we know what node this admonition came from.
node['classes'].append(node_name)
if not isinstance(node, nodes.admonition):
# Specific admonition. Transform into a generic admonition.
admonition = nodes.admonition(node.rawsource, *node.children,
**node.attributes)
title = nodes.title('', language.labels[node_name])
admonition.insert(0, title)
node.replace_self(admonition)
+136
View File
@@ -0,0 +1,136 @@
# $Id: urischemes.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: David Goodger <goodger@python.org>
# Copyright: This module has been placed in the public domain.
"""
`schemes` is a dictionary with lowercase URI addressing schemes as
keys and descriptions as values. It was compiled from the index at
http://www.iana.org/assignments/uri-schemes (revised 2005-11-28)
and an older list at http://www.w3.org/Addressing/schemes.html.
"""
# Many values are blank and should be filled in with useful descriptions.
schemes = {
'about': 'provides information on Navigator',
'acap': 'Application Configuration Access Protocol; RFC 2244',
'addbook': "To add vCard entries to Communicator's Address Book",
'afp': 'Apple Filing Protocol',
'afs': 'Andrew File System global file names',
'aim': 'AOL Instant Messenger',
'callto': 'for NetMeeting links',
'castanet': 'Castanet Tuner URLs for Netcaster',
'chttp': 'cached HTTP supported by RealPlayer',
'cid': 'content identifier; RFC 2392',
'crid': 'TV-Anytime Content Reference Identifier; RFC 4078',
'data': ('allows inclusion of small data items as "immediate" data; '
'RFC 2397'),
'dav': 'Distributed Authoring and Versioning Protocol; RFC 2518',
'dict': 'dictionary service protocol; RFC 2229',
'dns': 'Domain Name System resources',
'eid': ('External ID; non-URL data; general escape mechanism to allow '
'access to information for applications that are too '
'specialized to justify their own schemes'),
'fax': ('a connection to a terminal that can handle telefaxes '
'(facsimiles); RFC 2806'),
'feed' : 'NetNewsWire feed',
'file': 'Host-specific file names; RFC 1738',
'finger': '',
'freenet': '',
'ftp': 'File Transfer Protocol; RFC 1738',
'go': 'go; RFC 3368',
'gopher': 'The Gopher Protocol',
'gsm-sms': ('Global System for Mobile Communications Short Message '
'Service'),
'h323': ('video (audiovisual) communication on local area networks; '
'RFC 3508'),
'h324': ('video and audio communications over low bitrate connections '
'such as POTS modem connections'),
'hdl': 'CNRI handle system',
'hnews': 'an HTTP-tunneling variant of the NNTP news protocol',
'http': 'Hypertext Transfer Protocol; RFC 2616',
'https': 'HTTP over SSL; RFC 2818',
'hydra': 'SubEthaEdit URI. See http://www.codingmonkeys.de/subethaedit.',
'iioploc': 'Internet Inter-ORB Protocol Location?',
'ilu': 'Inter-Language Unification',
'im': 'Instant Messaging; RFC 3860',
'imap': 'Internet Message Access Protocol; RFC 2192',
'info': 'Information Assets with Identifiers in Public Namespaces',
'ior': 'CORBA interoperable object reference',
'ipp': 'Internet Printing Protocol; RFC 3510',
'irc': 'Internet Relay Chat',
'iris.beep': 'iris.beep; RFC 3983',
'iseek' : 'See www.ambrosiasw.com; a little util for OS X.',
'jar': 'Java archive',
'javascript': ('JavaScript code; evaluates the expression after the '
'colon'),
'jdbc': 'JDBC connection URI.',
'ldap': 'Lightweight Directory Access Protocol',
'lifn': '',
'livescript': '',
'lrq': '',
'mailbox': 'Mail folder access',
'mailserver': 'Access to data available from mail servers',
'mailto': 'Electronic mail address; RFC 2368',
'md5': '',
'mid': 'message identifier; RFC 2392',
'mocha': '',
'modem': ('a connection to a terminal that can handle incoming data '
'calls; RFC 2806'),
'mtqp': 'Message Tracking Query Protocol; RFC 3887',
'mupdate': 'Mailbox Update (MUPDATE) Protocol; RFC 3656',
'news': 'USENET news; RFC 1738',
'nfs': 'Network File System protocol; RFC 2224',
'nntp': 'USENET news using NNTP access; RFC 1738',
'opaquelocktoken': 'RFC 2518',
'phone': '',
'pop': 'Post Office Protocol; RFC 2384',
'pop3': 'Post Office Protocol v3',
'pres': 'Presence; RFC 3859',
'printer': '',
'prospero': 'Prospero Directory Service; RFC 4157',
'rdar' : ('URLs found in Darwin source '
'(http://www.opensource.apple.com/darwinsource/).'),
'res': '',
'rtsp': 'real time streaming protocol; RFC 2326',
'rvp': '',
'rwhois': '',
'rx': 'Remote Execution',
'sdp': '',
'service': 'service location; RFC 2609',
'shttp': 'secure hypertext transfer protocol',
'sip': 'Session Initiation Protocol; RFC 3261',
'sips': 'secure session intitiaion protocol; RFC 3261',
'smb': 'SAMBA filesystems.',
'snews': 'For NNTP postings via SSL',
'snmp': 'Simple Network Management Protocol; RFC 4088',
'soap.beep': 'RFC 3288',
'soap.beeps': 'RFC 3288',
'ssh': 'Reference to interactive sessions via ssh.',
't120': 'real time data conferencing (audiographics)',
'tag': 'RFC 4151',
'tcp': '',
'tel': ('a connection to a terminal that handles normal voice '
'telephone calls, a voice mailbox or another voice messaging '
'system or a service that can be operated using DTMF tones; '
'RFC 2806.'),
'telephone': 'telephone',
'telnet': 'Reference to interactive sessions; RFC 4248',
'tftp': 'Trivial File Transfer Protocol; RFC 3617',
'tip': 'Transaction Internet Protocol; RFC 2371',
'tn3270': 'Interactive 3270 emulation sessions',
'tv': '',
'urn': 'Uniform Resource Name; RFC 2141',
'uuid': '',
'vemmi': 'versatile multimedia interface; RFC 2122',
'videotex': '',
'view-source': 'displays HTML code that was generated with JavaScript',
'wais': 'Wide Area Information Servers; RFC 4156',
'whodp': '',
'whois++': 'Distributed directory service.',
'x-man-page': ('Opens man page in Terminal.app on OS X '
'(see macosxhints.com)'),
'xmlrpc.beep': 'RFC 3529',
'xmlrpc.beeps': 'RFC 3529',
'z39.50r': 'Z39.50 Retrieval; RFC 2056',
'z39.50s': 'Z39.50 Session; RFC 2056',}

Some files were not shown because too many files have changed in this diff Show More