Changes between Version 4 and Version 5 of WikiProcessors


Ignore:
Timestamp:
Mar 27, 2008, 7:31:47 AM (12 years ago)
Author:
trac
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • WikiProcessors

    v4 v5  
    11= Wiki Processors =
    2 Processors are WikiMacros designed to provide alternative markup formats for the Trac Wiki engine. Processors can be thought of as ''macro functions to process user-edited text''.
    32
    4 The wiki engine uses processors to allow using [wiki:WikiRestructuredText Restructured Text] and [wiki:WikiHtml raw HTML] in any wiki text throughout Trac.
     3Processors are [TracWikiMacros wiki macros] designed to provide alternative markup formats for the [TracWiki Wiki engine]. Processors can be thought of as ''macro functions to process user-edited text''.
     4
     5The Wiki engine uses processors to allow using [wiki:WikiRestructuredText Restructured Text], [wiki:WikiHtml raw HTML] and [http://www.textism.com/tools/textile/ textile] in any Wiki text throughout Trac.
     6
    57
    68== Using Processors ==
    7 To use a processor on a block of text, use a wiki blockquote, selecting a processor by name using ''shebang notation'' (#!), familiar to most UNIX users from scripts.
     9
     10To use a processor on a block of text, use a Wiki code block, selecting a processor by name using ''shebang notation'' (#!), familiar to most UNIX users from scripts.
    811
    912'''Example 1''' (''inserting raw HTML in a wiki text''):
     
    8083The following processors are included in the Trac distribution:
    8184 * '''html''' -- Insert custom HTML in a wiki page. See WikiHtml.
     85 * '''div''' -- Wrap an arbitrary Wiki content in a <div> element (''since 0.11''). See WikiHtml.
    8286 * '''rst''' -- Trac support for Restructured Text. See WikiRestructuredText.
    83  * '''textile''' -- Supported if  [http://dealmeida.net/projects/textile/ Textile] is installed.
     87 * '''textile''' -- Supported if [http://cheeseshop.python.org/pypi/textile Textile] is installed. See [http://www.textism.com/tools/textile/ a Textile reference].
     88 * '''comment''' -- Do not process the text in this section (i.e. contents exist only in the plain text - not in the rendered page).
    8489
    8590=== Code Highlighting Support ===
     
    9499 * '''sql''' -- SQL
    95100 * '''xml''' -- XML
     101 * '''sh''' -- Bourne/Bash shell
    96102'''Note:''' ''Trac relies on external software packages for syntax coloring. See TracSyntaxColoring for more info.''
    97103
     
    108114
    109115For more processor macros developed and/or contributed by users, visit:
    110  * [http://projects.edgewall.com/trac/wiki/ProcessorBazaar ProcessorBazaar]
    111  * [http://projects.edgewall.com/trac/wiki/MacroBazaar MacroBazaar]
     116 * [http://trac.edgewall.org/wiki/ProcessorBazaar ProcessorBazaar]
     117 * [http://trac.edgewall.org/wiki/MacroBazaar MacroBazaar]
    112118
    113119
    114120== Advanced Topics: Developing Processor Macros ==
    115 Developing processors is no different than WikiMacros. In fact they work the same way, only the usage syntax differs. See WikiMacros for more information.
     121Developing processors is no different from [TracWikiMacros wiki macros]. In fact they work the same way, only the usage syntax differs.
    116122
    117 '''Example:''' (''Restructured Text Processor''):
    118 {{{
    119 from docutils.core import publish_string
    120 
    121 def execute(hdf, text, env):
    122     html = publish_string(text, writer_name = 'html')
    123     return html[html.find('<body>')+6:html.find('</body>')].strip()
    124 }}}
    125123
    126124----
    127 See also: WikiMacros, WikiHtml, WikiRestructuredText, TracSyntaxColoring, WikiFormatting, TracGuide
     125See also: TracWikiMacros, WikiHtml, WikiRestructuredText, TracSyntaxColoring, WikiFormatting, TracGuide