Support

Support Options

Submit a Support Ticket

 
HomeTopicsHelp: Wiki Formatting › Compare

Help: Wiki Formatting

Version 7
by Lynn Zentner
Version 9
by Lynn Zentner

Deletions or items before changed

Additions or items after changed

1 = Wiki Formatting =
2
3 Wiki markup is a core feature for Topic pages, tightly integrating all the other parts of Trac into a flexible and powerful whole.
4
5 nanoHUB 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://moinmoin.wikiwikiweb.de/ MoinMoin].
6
7 This page demonstrates the formatting syntax available anywhere [Help:WikiFormatting Wiki Formatting] is allowed.
8
9 == Font Styles ==
10
11 The pages supports the following font styles:
12
13 {{{
14 * '''bold''', '''!''' can be bold too''', and '''! '''
15 * ''italic''
16 * '''''bold italic'''''
17 * __underline__
18 * {{{monospace}}} or `monospace`
19 * ~~strike-through~~
20 * ^superscript^
21 * ,,subscript,,
22 }}}
23
24 Display:
25
26 * '''bold''', '''!''' can be bold too''', and '''! '''
27 * ''italic''
28 * '''''bold italic'''''
29 * __underline__
30 * {{{monospace}}} or `monospace`
31 * ~~strike-through~~
32 * ^superscript^
33 * ,,subscript,,
34
35 Notes:
36
37 * `{{{...}}}` 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.
38 * ` ! ` 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.
39
40 == Headings ==
41
42 You can create heading by starting a line with one up to five ''equal'' characters ("=") followed by a single space and the headline text. The line should end with a space followed by the same number of ''='' characters. The heading might optionally be followed by an explicit id. If not, an implicit but nevertheless readable id will be generated.
43
44 Example:
45
46 {{{
47 = Heading =
48 == Subheading ==
49 === About ''this'' ===
50 === Explicit id === #using-explicit-id-in-heading
51 }}}
52
53 Display:
54
55 = Heading =
56 == Subheading ==
57 === About ''this'' ===
58 === Explicit id === #using-explicit-id-in-heading
59
60 == Paragraphs ==
61
62 A new text paragraph is created whenever two blocks of text are separated by one or more empty lines.
63
64 A forced line break can also be inserted, using:
65
66 {{{
67 Line 1[[BR]]Line 2
68 }}}
69
70 Display:
71
72 Line 1[[BR]]Line 2
73
74 == Lists ==
75
76 The wiki supports both ordered/numbered and unordered lists.
77
78 Example:
79
80 {{{
81 * Item 1
82 * Item 1.1
83 * Item 2
84
85 # Item 1
86 # Item 1.a
87 # Item 1.b
88 # Item 1.b.i
89 # Item 1.b.ii
90 # Item 2
91 }}}
92
93 Display:
94
95 * Item 1
96 * Item 1.1
97 * Item 2
98
99 # Item 1
100 # Item 1.a
101 # Item 1.b
102 # Item 1.b.i
103 # Item 1.b.ii
104 # Item 2
105
106 Note that there must be one or more spaces preceding the list item markers, otherwise the list will be treated as a normal paragraph.
107
108 == Definition Lists ==
109
110 The wiki also supports definition lists.
111
112 Example:
113
114 {{{
115 llama::
116 some kind of mammal, with hair
117 ppython::
118 some kind of reptile, without hair
119 (can you spot the typo?)
120 }}}
121
122 Display:
123
124 llama::
125 some kind of mammal, with hair
126 ppython::
127 some kind of reptile, without hair
128 (can you spot the typo?)
129
130
131 Note that you need a space in front of the defined term.
132
133 == Preformatted Text ==
134
135 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.
136
137 Example:
138
139 {{{
140 {{{
141 def HelloWorld():
142 print "Hello World"
143 }}}
144 }}}
145
146 Display:
147
148 {{{
149 def HelloWorld():
150 print "Hello World"
151 }}}
152
153 Note that this type of formatting can also be used to display html with minor changes in the syntax.
154 See [Help:WikiHtml] for details.
155
156 == Tables ==
157
158 Simple tables can be created like this:
159
160 {{{
161 ||Cell 1||Cell 2||Cell 3||
162 ||Cell 4||Cell 5||Cell 6||
163 }}}
164
165 Display:
166
167 ||Cell 1||Cell 2||Cell 3||
168 ||Cell 4||Cell 5||Cell 6||
169
170 -
For a blank cell, use   as the content to ensure that the cell displays properly.
171
172 == Links ==
173
174 Hyperlinks are automatically created for WikiPageNames and URLs. !WikiPageLinks can be disabled by prepending an exclamation mark "!" character, such as {{{!WikiPageLink}}}.
175
176 Example:
177
178 {{{
179 MainPage, http://www.edgewall.com/, !NotAlink
180 }}}
181
182 Display:
183
184 MainPage, http://www.edgewall.com/, !NotAlink
185
186 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. 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.
187
188 Example:
189
190 {{{
191 * [http://www.edgewall.com/ Edgewall Software]
192 * [MainPage Main Page]
193 * [Help:WikiMacros]
194 }}}
195
196 Display:
197
198 * [http://www.edgewall.com/ Edgewall Software]
199 * [MainPage Main Page]
200 * [Help:WikiMacros]
201
202 == Escaping Links and WikiPageNames ==
203
204 You may avoid making hyperlinks out of TracLinks by preceding an expression with a single "!" (exclamation mark).
205
206 Example:
207
208 {{{
209 !NoHyperLink
210 }}}
211
212 Display:
213
214 !NoHyperLink
215
216 == Images ==
217
218 The simplest way to include an image is to upload it as attachment to the current page, and put the filename in a macro call like `[[Image(picture.gif)]]`.
219
220 In addition to the current page, it is possible to refer to other resources:
221
222 * `[[Image(picture.gif)]]` (simplest)
223 * `[[Image(picture.gif, 120px)]]` (give it a specific width)
224 * `[[Image(picture.gif, align-right)]]` (add the CSS class "align-right" to the image)
225 * `[[Image(picture.gif, nolink)]]` (unlinked)
226 * `[[Image(picture.gif, align=right)]]` (align by attribute)
227
228 See [Help:WikiMacros Help: Wiki Macros] for further documentation on the `[[Image()]]` macro.
229
230 == Macros ==
231
232 Macros are ''custom functions'' to insert dynamic content in a page.
233
234 Example:
235
236 {{{
237 [[Timestamp]]
238 }}}
239
240 Display:
241
242 [[Timestamp]]
243
244 See [Help:WikiMacros Wiki Macros] for more information, and a list of installed macros.
245
246 == Miscellaneous ==
247
248 Four or more dashes will be replaced by a horizontal line.
249
250 Example:
251
252 {{{
253 ----
254 }}}
255
256 Display:
257
258 ----

nanoHUB.org, a resource for nanoscience and nanotechnology, is supported by the National Science Foundation and other funding agencies.