Changes between Version 4 and Version 5 of WikiFormatting
- Timestamp:
- Sep 24, 2024, 8:57:15 AM (2 months ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
WikiFormatting
v4 v5 5 5 Wiki markup is a core feature in Trac, tightly integrating all the other parts of Trac into a flexible and unified whole. 6 6 7 Trac has a powerful wiki rendering engine that implements a subset of the commands from other popular Wikis, such as [http ://moinmo.in/ MoinMoin] and [trac:WikiCreole].7 Trac has a powerful wiki rendering engine that implements a subset of the commands from other popular Wikis, such as [https://moinmo.in/ MoinMoin] and [trac:WikiCreole]. 8 8 9 9 The sections below provide an overview for the most common syntax, each link in the ''Category'' column leads you to the more detailed explanation later in this page. 10 10 11 The following wiki pages present the advanced features of the Trac wiki markup in more depth: 11 The following wiki pages present the advanced features of the Trac wiki markup in more depth: 12 12 - TracLinks covers all the possible ways to refer to any Trac resource or parts thereof. 13 13 - WikiPageNames covers the various names a wiki page can take, whether in CamelCase or not. … … 31 31 |----------------------------------------------------------- 32 32 ||= [#Headings Headings] =||\ 33 {{{#!td 33 {{{#!td 34 34 {{{ 35 35 == Level 2 … … 64 64 on multiple lines 65 65 1. nested list 66 a. different numbering 66 a. different numbering 67 67 styles 68 68 }}} … … 145 145 [#Links Links] 146 146 }}} 147 || `http ://trac.edgewall.org` ||\148 || http ://trac.edgewall.org ||147 || `https://trac.edgewall.org` ||\ 148 || https://trac.edgewall.org || 149 149 || `WikiFormatting (CamelCase)` ||\ 150 150 || WikiFormatting (CamelCase) || … … 164 164 || Ticket [[ticket:1]], [[ticket:1|ticket one]] || 165 165 |----------------------------------------------------------- 166 {{{#!th rowspan=2 166 {{{#!th rowspan=2 167 167 [#SettingAnchors Setting Anchors] 168 168 }}} … … 204 204 {{{#!div style="font-size: 80%" 205 205 Code highlighting: 206 {{{#!python 206 {{{#!python 207 207 hello = lambda: "world" 208 208 }}} … … 223 223 {{{#!td 224 224 {{{ 225 Line [[br]] break 225 Line [[br]] break 226 226 Line \\ break 227 227 ---- … … 240 240 {{{#!td 241 241 {{{ 242 * '''bold''', 243 ''' triple quotes !''' 244 can be bold too if prefixed by ! ''', 242 * '''bold''', 243 ''' triple quotes !''' 244 can be bold too if prefixed by ! ''', 245 245 * ''italic'' 246 246 * '''''bold italic''''' or ''italic and … … 250 250 (hence `{{{` or {{{`}}} quoting) 251 251 * ~~strike-through~~ 252 * ^superscript^ 252 * ^superscript^ 253 253 * ,,subscript,, 254 * **also bold**, //italic as well//, 254 * **also bold**, //italic as well//, 255 255 and **'' bold italic **'' //(since 0.12)// 256 256 * [[span(style=color: #FF0000, a red text )]] … … 258 258 }}} 259 259 {{{#!td 260 * '''bold''', 261 ''' triple quotes !''' 262 can be bold too if prefixed by ! ''', 260 * '''bold''', 261 ''' triple quotes !''' 262 can be bold too if prefixed by ! ''', 263 263 * ''italic'' 264 264 * '''''bold italic''''' or ''italic and … … 268 268 (hence `{{{` or {{{`}}} quoting) 269 269 * ~~strike-through~~ 270 * ^superscript^ 270 * ^superscript^ 271 271 * ,,subscript,, 272 * **also bold**, //italic as well//, 272 * **also bold**, //italic as well//, 273 273 and **'' bold italic **'' //(since 0.12)// 274 274 * [[span(style=color: #FF0000, a red text )]] … … 278 278 * `{{{...}}}` and {{{`...`}}} commands not only select a monospace font, but also treat their content as verbatim text, meaning that no further wiki processing is done on this text. 279 279 * {{{ ! }}} tells wiki parser to not take the following characters as wiki format, so pay attention to put a space after `!`, e.g. when ending bold. 280 * all the font styles marks have to be used in opening/closing pairs, 281 and they must nest properly; in particular, an `''` italic can't be paired 280 * all the font styles marks have to be used in opening/closing pairs, 281 and they must nest properly; in particular, an `''` italic can't be paired 282 282 with a `//` one, and `'''` can't be paired with `**`. 283 283 284 284 == Headings 285 285 286 You can create a heading by starting a line with one up to six ''equal'' characters (`=`) followed by a single space and the headline text. 286 You can create a heading by starting a line with one up to six ''equal'' characters (`=`) followed by a single space and the headline text. 287 287 288 288 [=#hn] … … 326 326 one 327 327 328 Paragraph 328 Paragraph 329 329 two 330 330 }}} … … 333 333 Line 1[[BR]]Line 2 334 334 335 Paragraph 335 Paragraph 336 336 one 337 337 338 Paragraph 338 Paragraph 339 339 two 340 340 }}} … … 349 349 * Item 1 350 350 * Item 1.1 351 * Item 1.1.1 351 * Item 1.1.1 352 352 * Item 1.1.2 353 353 * Item 1.1.3 … … 356 356 - items can start at the beginning of a line 357 357 and they can span multiple lines 358 - be careful though to continue the line 358 - be careful though to continue the line 359 359 with the appropriate indentation, otherwise 360 360 that will start a new paragraph... 361 361 362 362 1. Item 1 363 363 a. Item 1.a … … 374 374 * Item 1 375 375 * Item 1.1 376 * Item 1.1.1 376 * Item 1.1.1 377 377 * Item 1.1.2 378 378 * Item 1.1.3 … … 381 381 - items can start at the beginning of a line 382 382 and they can span multiple lines 383 - be careful though to continue the line 383 - be careful though to continue the line 384 384 with the appropriate indentation, otherwise 385 385 that will start a new paragraph... … … 422 422 423 423 Block containing preformatted text are suitable for source code snippets, notes and examples. Use three ''curly braces'' wrapped around the text to define a block quote. The curly braces need to be on a separate line. 424 424 425 425 ||= Wiki Markup =||= Display =|| 426 426 {{{#!td … … 459 459 == Discussion Citations 460 460 461 To delineate a citation in an ongoing discussion thread, such as the ticket comment area, email-like citation marks (`>`, `>>`, etc.) may be used. 461 To delineate a citation in an ongoing discussion thread, such as the ticket comment area, email-like citation marks (`>`, `>>`, etc.) may be used. 462 462 463 463 ||= Wiki Markup =||= Display =|| … … 556 556 {{{#!td 557 557 {{{ 558 || this is column 1 [http ://trac.edgewall.org/newticket new ticket] || \559 || this is column 2 [http ://trac.edgewall.org/roadmap the road ahead] || \558 || this is column 1 [https://trac.edgewall.org/newticket new ticket] || \ 559 || this is column 2 [https://trac.edgewall.org/roadmap the road ahead] || \ 560 560 || that's column 3 and last one || 561 561 }}} … … 564 564 ||= Display =|| 565 565 {{{#!td style="padding: 2em;" 566 || this is column 1 [http ://trac.edgewall.org/newticket new ticket] || \567 || this is column 2 [http ://trac.edgewall.org/roadmap the road ahead] || \566 || this is column 1 [https://trac.edgewall.org/newticket new ticket] || \ 567 || this is column 2 [https://trac.edgewall.org/roadmap the road ahead] || \ 568 568 || that's column 3 and last one || 569 569 }}} … … 580 580 {{{#!td 581 581 {{{ 582 TitleIndex, http ://www.edgewall.com/, !NotAlink583 }}} 584 }}} 585 {{{#!td 586 TitleIndex, http ://www.edgewall.com/, !NotAlink587 }}} 588 589 Links can be given a more descriptive title by writing the link followed by a space and a title and all this inside square brackets. 582 TitleIndex, https://www.edgewall.com/, !NotAlink 583 }}} 584 }}} 585 {{{#!td 586 TitleIndex, https://www.edgewall.com/, !NotAlink 587 }}} 588 589 Links can be given a more descriptive title by writing the link followed by a space and a title and all this inside square brackets. 590 590 If the descriptive title is omitted, then the explicit prefix is discarded, unless the link is an external link. This can be useful for wiki pages not adhering to the WikiPageNames convention. 591 591 … … 593 593 {{{#!td 594 594 {{{ 595 * [http ://www.edgewall.com Edgewall Software]596 * [wiki:TitleIndex Title Index] 597 * [wiki:TitleIndex] 595 * [https://www.edgewall.com Edgewall Software] 596 * [wiki:TitleIndex Title Index] 597 * [wiki:TitleIndex] 598 598 * [wiki:ISO9000] 599 599 }}} 600 600 }}} 601 601 {{{#!td 602 * [http ://www.edgewall.com Edgewall Software]603 * [wiki:TitleIndex Title Index] 604 * [wiki:TitleIndex] 602 * [https://www.edgewall.com Edgewall Software] 603 * [wiki:TitleIndex Title Index] 604 * [wiki:TitleIndex] 605 605 * [wiki:ISO9000] 606 606 }}} 607 607 608 Following the [trac:WikiCreole] trend, the descriptive title can also be specified by writing the link followed by a pipe (`|`) and a title and all this inside //double// square brackets. 609 610 {{{#!td 611 {{{ 612 * [[http ://www.edgewall.com|Edgewall Software]]608 Following the [trac:WikiCreole] trend, the descriptive title can also be specified by writing the link followed by a pipe (`|`) and a title and all this inside //double// square brackets. 609 610 {{{#!td 611 {{{ 612 * [[https://www.edgewall.com|Edgewall Software]] 613 613 * [[wiki:TitleIndex|Title Index]] 614 614 or even [[TitleIndex|Title Index]] … … 619 619 }}} 620 620 {{{#!td 621 * [[http ://www.edgewall.com|Edgewall Software]]621 * [[https://www.edgewall.com|Edgewall Software]] 622 622 * [[wiki:TitleIndex|Title Index]] 623 623 or even [[TitleIndex|Title Index]] … … 641 641 * Changesets: r1, [1] or changeset:1 642 642 * ... 643 * targeting other Trac instances, 643 * targeting other Trac instances, 644 644 so called InterTrac links: 645 645 - Tickets: #Trac1 or Trac:ticket:1 … … 651 651 * Reports: {1} or report:1 652 652 * Changesets: r1, [1] or changeset:1 653 * ... 654 * targeting other Trac instances, 653 * ... 654 * targeting other Trac instances, 655 655 so called InterTrac links: 656 656 - Tickets: #Trac1 or Trac:ticket:1 … … 662 662 == Setting Anchors 663 663 664 An anchor, or more correctly speaking, an [http ://www.w3.org/TR/REC-html40/struct/links.html#h-12.2.1 anchor name] can be added explicitly at any place in the Wiki page, to uniquely identify a position in the document:664 An anchor, or more correctly speaking, an [https://www.w3.org/TR/REC-html40/struct/links.html#h-12.2.1 anchor name] can be added explicitly at any place in the Wiki page, to uniquely identify a position in the document: 665 665 666 666 {{{ … … 785 785 == Processors 786 786 787 Trac supports alternative markup formats using WikiProcessors. For example, processors are used to write pages in 788 [wiki:WikiRestructuredText reStructuredText] or [wiki:WikiHtml HTML]. 787 Trac supports alternative markup formats using WikiProcessors. For example, processors are used to write pages in 788 [wiki:WikiRestructuredText reStructuredText] or [wiki:WikiHtml HTML]. 789 789 790 790 ||= Wiki Markup =||= Display =|| … … 823 823 {{{#!python 824 824 class Test: 825 825 826 826 def __init__(self): 827 827 print "Hello World" … … 863 863 |---------------- 864 864 {{{#!td 865 As processors can be easily nested, 865 As processors can be easily nested, 866 866 so can be tables: 867 867 {{{#!th … … 894 894 |---------------- 895 895 {{{#!td 896 As processors can be easily nested, 896 As processors can be easily nested, 897 897 so can be tables: 898 898 {{{#!th … … 942 942 Horizontal line: 943 943 {{{ 944 Four or more dashes will be replaced 944 Four or more dashes will be replaced 945 945 by a horizontal line (<HR>) 946 946 ----