Package restxsl :: Module directives
[frames | no frames]

Module restxsl.directives

reStructuredText directives provided by the restxsl module.

Author: Michael Alyn Miller <malyn@strangeGizmo.com>

Copyright: 2006 by Michael Alyn Miller

License: BSD License (see source code for full license)

Function Summary
  code_block_directive(name, arguments, options, content, lineno, content_offset, block_text, state, state_machine)
Provides syntax highlighting for blocks of code.
  pyxslt_directive(name, arguments, options, content, lineno, content_offset, block_text, state, state_machine)
The pyxslt directive allows you to call Python routines and include the serialized XML results in the input document.

Function Details

code_block_directive(name, arguments, options, content, lineno, content_offset, block_text, state, state_machine)

Provides syntax highlighting for blocks of code. It is used with the following syntax:
   .. code-block:: cpp
        
       #include <iostream>
       
       int main( int argc, char* argv[] )
       {
           std::cout << "Hello world" << std::endl;
       }

The directive requires the name of a language supported by SilverCity as its only argument. All code in the indented block following the directive will be colorized.

The directive can also be told to include a source file directly:
   .. code-block::
        :language: Python
        :source-file: ../myfile.py
You cannot both specify a source-file and include code directly.

pyxslt_directive(name, arguments, options, content, lineno, content_offset, block_text, state, state_machine)

The pyxslt directive allows you to call Python routines and include the serialized XML results in the input document. These nodes will then be processed by the document's XSL template.

Only keyword arguments may be passed to the target Python function:
   .. pyxslt:: sampleFunction
       :sampleArg: One
       :anotherArg: 27
The resulting XML tree will be enclosed in a <pyxslt> tag, which will be passed straight-through to the XSL stylesheet for parsing.

Generated by Epydoc 2.1 on Wed Jul 12 11:20:40 2006 http://epydoc.sf.net