= WikiFormatting = Wiki serves as the core component of Trac, which tightly integrates all the other parts of Trac into flexible and powerful system. Trac has a built in small and powerful wiki rendering engine. This wiki engine implements an ever growing subset of the commands from other popular Wikis especially [http://moin.sf.net/ MoinWiki]. This page demonstrates some of the formatting commands available in the Trac Wiki. == Font styles == The Trac wiki support the following font styles: '''bold''', ''italic'' and __underline__. {{{ The Trac wiki support the following font styles: '''bold''', ''italic'' and __underline__. }}} == Heading == You can create heading by starting a line with one up to five equal signs followed by a space and the headline text. The line should end with a space followed by the same number of equal signs. === Example: === {{{ = Heading = == Subheading == }}} == Paragraphs == A new text paragraph is created whenever two blocks of text are separated by an empty line. A newline can also be inserted like this: {{{ Line 1[[BR]]Line 2 }}} Display: Line 1[[BR]]Line 2 Text paragraphs can also be indented by starting the lines with a few spaces. == Lists == Example: {{{ * Item 1 * Item 1.1 * Item 2 1. Item 1 1. Item 1.1 1. Item 2 }}} Display: * Item 1 * Item 1.1 * Item 2 1. Item 1 1. Item 1.1 1. Item 2 == Preformatted text == Block quotes, also know as preformatted text, is suitable for source code snippets, notes and examples. Use three ''curly braces'' wrapped around the text: {{{ {{{ def HelloWorld() print "Hello World" }}} }}} Display: {{{ def HelloWorld() print "Hello World" }}} == Tables == Simple tables can be created like this: {{{ ||Cell 1||Cell 2||Cell 3|| ||Cell 4||Cell 5||Cell 6|| }}} Display: ||Cell 1||Cell 2||Cell 3|| ||Cell 4||Cell 5||Cell 6|| == Links == Hyperlinks are automatically created for WikiPageNames and urls. !WikiPageLinks can be disabled by prepending a bang (!) character like this {{{!WikiPageLink}}}. For example: TitleIndex, http://www.edgewall.com/. Links can be given a more descriptive title by writing the link followed by a space and a title and all this inside two square brackets. Like this: {{{ * [http://www.edgewall.com/ Edgewall Software] * [wiki:TitleIndex Title Index] }}} Display: * [http://www.edgewall.com/ Edgewall Software] * [wiki:TitleIndex Title Index] === Intra Trac Links === Trac allows wiki pages to link directly to other parts of the Trac system. Pages can refer to tickets, reports and changesets by simply writing the ticket, report and changeset numbers in the following notation: {{{ * Ticket #1 * Report {1} * Changeset [1] * File source:trunk/COPYING. * A specific file revision: source:/trunk/COPYING#200 }}} Display: * Ticket #1 * Report {1} * Changeset [1] * File source:trunk/COPYING. * A specific file revision: source:/trunk/COPYING#200 See TracLinks for more information about intra-trac linking. == Images == Urls ending with .png, .gif or .jpg will be converted to an IMG-tag. Example: {{{ http://www.edgewall.com/gfx/trac_example_image.png }}} Display: http://www.edgewall.com/gfx/trac_example_image.png == Macros == Macros are ''custom functions'' to insert dynamic content in a page. See WikiMacros for usage. Example: {{{ [[Timestamp]] }}} Display: [[Timestamp]] == Processors == Trac supports alternative markup formats using WikiProcessors. For example, processors are used to write pages in [wiki:WikiRestructuredText reStructuredText] or [wiki:WikiHtml HTML]. See WikiProcessors for documentation. '''Example 1:''' {{{ #!html
{{{
#!html
<h1 style="text-align: right; color: blue">HTML Test</h1>
}}}
}}} Display: {{{ #!html

HTML Test

}}} '''Example 2:''' {{{ #!html
{{{
#!python
class Test:
    def __init__(self):
        print "Hello World"
if __name__ == '__main__':
   Test()
}}}
}}} Display: {{{ #!python class Test: def __init__(self): print "Hello World" if __name__ == '__main__': Test() }}} == Miscellaneous == Four or more dashes will be replaced by a horizontal line (
) {{{ ---- }}} Display: ----