Changes between Version 30 and Version 31 of WikiRestructuredText
- Timestamp:
- Oct 20, 2015, 9:25:14 PM (8 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
WikiRestructuredText
v30 v31 1 = reStructuredText Support in Trac = 1 = reStructuredText Support in Trac 2 3 == Introduction 4 2 5 [[TranslatedPages]] 3 6 … … 5 8 6 9 From the reStucturedText webpage: 7 " ''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 "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." 8 11 9 12 If 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]. 10 13 11 === Requirements === 14 === Requirements 15 12 16 To 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]. 13 17 14 18 Do not use the package manager of your OS, eg `apt-get install python-docutils`, because Trac will not find docutils then. 15 19 16 === More information on RST ===20 === More information on RST 17 21 18 22 * reStructuredText Website -- http://docutils.sourceforge.net/rst.html 19 23 * RST Quick Reference -- http://docutils.sourceforge.net/docs/rst/quickref.html 20 24 21 ---- 22 23 == Using RST in Trac == 25 == Using RST in Trac 26 24 27 To specify that a block of text should be parsed using RST, use the ''rst'' processor. 25 28 26 === TracLinks in reStructuredText ===29 === TracLinks in reStructuredText 27 30 28 31 * Trac provides a custom RST directive `trac::` to allow TracLinks from within RST text. … … 70 73 For a complete example of all uses of the `:trac:` role, please see WikiRestructuredTextLinks. 71 74 72 === Syntax highlighting in reStructuredText ===75 === Syntax highlighting in reStructuredText 73 76 74 77 There is a directive for doing TracSyntaxColoring in RST as well. The directive is called code-block: … … 105 108 Note the need to indent the code at least one character after the `.. code-block` directive. 106 109 107 === Wiki Macros in reStructuredText ===110 === Wiki Macros in reStructuredText 108 111 109 112 To enable [WikiMacros Wiki Macros] in RST, you use the same directive as for syntax highlighting, ie code-block: … … 153 156 }}} 154 157 155 === Bigger RST Example === 158 === Bigger RST Example 159 156 160 The example below should be self-explanatory: 157 161