Changes between Version 2 and Version 3 of WikiRestructuredText


Ignore:
Timestamp:
10/18/16 10:54:24 (8 years ago)
Author:
trac
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • WikiRestructuredText

    v2 v3  
    1 = reStructuredText Support in Trac =
    2 
    3 Trac supports using ''reStructuredText'' (RST) as an alternative to wiki markup in any context WikiFormatting is used.
     1= reStructuredText Support in Trac
     2
     3== Introduction
     4
     5
     6Trac supports [http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html reStructuredText (RST)] as an alternative to wiki markup where WikiFormatting is used.
    47
    58From the reStucturedText webpage:
    6  "''reStructuredText is an easy-to-read, what-you-see-is-what-you-get plaintext markup syntax and parser   system. It is useful for in-line program documentation (such as Python docstrings), for quickly creating  simple web pages, and for standalone documents. reStructuredText is designed for extensibility for  specific application domains. ''"
    7 
    8 If you want a file from your Subversion repository be displayed as reStructuredText in Trac's source browser, set `text/x-rst` as value for the Subversion property `svn:mime-type`. See [trac:source:/trunk/INSTALL this example].
    9 
    10 === Requirements ===
    11 Note that to activate RST support in Trac, the python docutils package must be installed.
    12 If not already available on your operating system, you can download it at the [http://docutils.sourceforge.net/rst.html RST Website].
    13 
    14 Install docutils using `easy_install docutils`. Do not use the package manager of your OS (e.g. `apt-get install python-docutils`), because Trac will not find docutils then.
    15 
    16 === More information on RST ===
     9 "reStructuredText is an easy-to-read, what-you-see-is-what-you-get plaintext markup syntax and parser system. It is useful for in-line program documentation (such as Python docstrings), for quickly creating simple web pages, and for standalone documents. reStructuredText is designed for extensibility for specific application domains."
     10
     11If you want a file from your Subversion repository to be displayed as reStructuredText in the Trac source browser, set `text/x-rst` as the value for the Subversion property `svn:mime-type`. See [trac:source:/trunk/INSTALL this example].
     12
     13=== Requirements
     14
     15To activate RST support in Trac, install the python docutils package: `easy_install docutils`. If not already available on your operating system, you can download it at the [http://docutils.sourceforge.net/rst.html RST Website].
     16
     17Do not use the package manager of your OS, eg `apt-get install python-docutils`, because Trac will not find docutils then.
     18
     19=== More information on RST
    1720
    1821 * reStructuredText Website -- http://docutils.sourceforge.net/rst.html
    1922 * RST Quick Reference -- http://docutils.sourceforge.net/docs/rst/quickref.html
    2023
    21 ----
    22 
    23 == Using RST in Trac ==
     24== Using RST in Trac
     25
    2426To specify that a block of text should be parsed using RST, use the ''rst'' processor.
    2527
    26 === TracLinks in reStructuredText ===
     28=== TracLinks in reStructuredText
    2729
    2830 * Trac provides a custom RST directive `trac::` to allow TracLinks from within RST text.
     
    7072 For a complete example of all uses of the `:trac:` role, please see WikiRestructuredTextLinks.
    7173
    72 
    73 === Syntax highlighting in reStructuredText ===
    74 
    75 There is a directive for doing TracSyntaxColoring in RST as well. The directive is called
    76 code-block
     74=== Syntax highlighting in reStructuredText
     75
     76There is a directive for doing TracSyntaxColoring in RST as well. The directive is called code-block:
    7777
    7878||= Wiki Markup ||= Display ||
     
    107107Note the need to indent the code at least one character after the `.. code-block` directive.
    108108
    109 === Wiki Macros in reStructuredText ===
    110 
    111 For doing [WikiMacros Wiki Macros] in RST you use the same directive as for syntax highlighting i.e code-block.
     109=== Wiki Macros in reStructuredText
     110
     111To enable [WikiMacros Wiki Macros] in RST, you use the same directive as for syntax highlighting, ie code-block:
    112112
    113113||= Wiki Markup ||= Display ||
     
    135135}}}
    136136
    137 Or a more concise Wiki Macro like syntax is also available, using the `:code-block:` role:
     137Or a more concise Wiki Macro-like syntax is also available, using the `:code-block:` role:
    138138
    139139||= Wiki Markup ||= Display ||
     
    155155}}}
    156156
    157 === Bigger RST Example ===
    158 The example below should be mostly self-explanatory:
     157=== Bigger RST Example
     158
     159The example below should be self-explanatory:
    159160
    160161||= Wiki Markup ||= Display ||