RedCloth 4.0.0-x86-mswin32-60
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of RedCloth might be problematic. Click here for more details.
- data/CHANGELOG +17 -0
- data/COPYING +18 -0
- data/README +156 -0
- data/Rakefile +240 -0
- data/bin/redcloth +28 -0
- data/ext/redcloth_scan/extconf.rb +9 -0
- data/ext/redcloth_scan/redcloth.h +149 -0
- data/ext/redcloth_scan/redcloth_attributes.c +650 -0
- data/ext/redcloth_scan/redcloth_attributes.rl +78 -0
- data/ext/redcloth_scan/redcloth_common.rl +113 -0
- data/ext/redcloth_scan/redcloth_inline.c +5102 -0
- data/ext/redcloth_scan/redcloth_inline.rl +282 -0
- data/ext/redcloth_scan/redcloth_scan.c +9300 -0
- data/ext/redcloth_scan/redcloth_scan.rl +523 -0
- data/extras/mingw-rbconfig.rb +176 -0
- data/extras/ragel_profiler.rb +73 -0
- data/lib/redcloth.rb +24 -0
- data/lib/redcloth/formatters/base.rb +50 -0
- data/lib/redcloth/formatters/html.rb +342 -0
- data/lib/redcloth/formatters/latex.rb +227 -0
- data/lib/redcloth/formatters/latex_entities.yml +2414 -0
- data/lib/redcloth/textile_doc.rb +105 -0
- data/lib/redcloth/version.rb +18 -0
- data/lib/redcloth_scan.bundle +0 -0
- data/lib/redcloth_scan.so +0 -0
- data/test/basic.yml +794 -0
- data/test/code.yml +195 -0
- data/test/definitions.yml +71 -0
- data/test/extra_whitespace.yml +64 -0
- data/test/filter_html.yml +177 -0
- data/test/filter_pba.yml +12 -0
- data/test/helper.rb +108 -0
- data/test/html.yml +271 -0
- data/test/images.yml +202 -0
- data/test/instiki.yml +38 -0
- data/test/links.yml +214 -0
- data/test/lists.yml +283 -0
- data/test/poignant.yml +89 -0
- data/test/sanitize_html.yml +42 -0
- data/test/table.yml +267 -0
- data/test/test_custom_tags.rb +46 -0
- data/test/test_extensions.rb +31 -0
- data/test/test_formatters.rb +15 -0
- data/test/test_parser.rb +68 -0
- data/test/test_restrictions.rb +41 -0
- data/test/textism.yml +480 -0
- data/test/threshold.yml +772 -0
- data/test/validate_fixtures.rb +73 -0
- metadata +104 -0
data/test/threshold.yml
ADDED
@@ -0,0 +1,772 @@
|
|
1
|
+
--- # From http://thresholdstate.com/articles/4312/the-textile-reference-manual
|
2
|
+
name: paragraph
|
3
|
+
desc: Paragraphs are separated by blank lines. Each paragraph of text is transformed into a XHTML <p> paragraph block.
|
4
|
+
in: |-
|
5
|
+
A paragraph.
|
6
|
+
|
7
|
+
Another paragraph.
|
8
|
+
html: |-
|
9
|
+
<p>A paragraph.</p>
|
10
|
+
<p>Another paragraph.</p>
|
11
|
+
---
|
12
|
+
name: line breaks
|
13
|
+
desc: Line breaks within paragraphs are transformed into XHTML line breaks.
|
14
|
+
in: |-
|
15
|
+
A paragraph with
|
16
|
+
a line break.
|
17
|
+
html: |-
|
18
|
+
<p>A paragraph with<br />
|
19
|
+
a line break.</p>
|
20
|
+
---
|
21
|
+
name: xhtml tags
|
22
|
+
desc: Simple XHTML tags may be included in a paragraph.
|
23
|
+
in: Here's some <b>bold</b> text.
|
24
|
+
html: <p>Here’s some <b>bold</b> text.</p>
|
25
|
+
---
|
26
|
+
name: no paragraph tags
|
27
|
+
desc: A line beginning with a space will be left untouched, and not wrapped in <p> tags.
|
28
|
+
in: " No paragraph tags here."
|
29
|
+
html: "No paragraph tags here."
|
30
|
+
valid_html: false
|
31
|
+
---
|
32
|
+
name: smart quotes
|
33
|
+
desc: Single and double typewriter quotation marks ' and " are transformed into typographically correct “curly” quote marks.
|
34
|
+
in: '"Proceed!" said he to the host.'
|
35
|
+
html: '<p>“Proceed!” said he to the host.</p>'
|
36
|
+
---
|
37
|
+
name: smart quotes 2
|
38
|
+
in: "'Proceed!' said he to the host."
|
39
|
+
html: "<p>‘Proceed!’ said he to the host.</p>"
|
40
|
+
---
|
41
|
+
name: nested quotation marks
|
42
|
+
desc: Single and double quotation marks may be nested one inside the other.
|
43
|
+
in: |-
|
44
|
+
"'I swear, captain,' replied I."
|
45
|
+
html: |-
|
46
|
+
<p>“‘I swear, captain,’ replied I.”</p>
|
47
|
+
---
|
48
|
+
name: nested quotation marks 2
|
49
|
+
in: |-
|
50
|
+
'"I swear, captain," replied I.'
|
51
|
+
html: |-
|
52
|
+
<p>‘“I swear, captain,” replied I.’</p>
|
53
|
+
---
|
54
|
+
name: apostrophe glyphs
|
55
|
+
desc: Single quotation marks ' will be turned into apostrophe glyphs when used as such.
|
56
|
+
in: Greengrocers' apostrophe's.
|
57
|
+
html: <p>Greengrocers’ apostrophe’s.</p>
|
58
|
+
---
|
59
|
+
name: em-dash glyphs
|
60
|
+
desc: Double -- dashes become an em-dash glyph.
|
61
|
+
in: You know the Italian proverb -- Chi ha compagno ha padrone.
|
62
|
+
html: <p>You know the Italian proverb — Chi ha compagno ha padrone.</p>
|
63
|
+
---
|
64
|
+
name: em-dash glyphs 2
|
65
|
+
in: You know the Italian proverb--Chi ha compagno ha padrone.
|
66
|
+
html: <p>You know the Italian proverb—Chi ha compagno ha padrone.</p>
|
67
|
+
---
|
68
|
+
name: en-dash glyphs
|
69
|
+
desc: Single - dashes are replaced with en-dashes.
|
70
|
+
in: You know the Italian proverb - Chi ha compagno ha padrone.
|
71
|
+
html: <p>You know the Italian proverb – Chi ha compagno ha padrone.</p>
|
72
|
+
---
|
73
|
+
name: ellipsis character
|
74
|
+
desc: Three period marks become an ellipsis character.
|
75
|
+
in: Meanwhile...
|
76
|
+
html: <p>Meanwhile…</p>
|
77
|
+
---
|
78
|
+
name: dimension character
|
79
|
+
desc: An “x” is replaced with the dimension character when used between numbers.
|
80
|
+
in: 1 x 2 x 3 = 6
|
81
|
+
html: <p>1 × 2 × 3 = 6</p>
|
82
|
+
---
|
83
|
+
name: dimension character 2
|
84
|
+
in: 1x2x3 = 6
|
85
|
+
html: <p>1×2×3 = 6</p>
|
86
|
+
---
|
87
|
+
name: trademark register copyright
|
88
|
+
desc: Trademark, Registered and Copyright symbols are represented by their common plain text equivalents.
|
89
|
+
in: Registered(r) Trademark(tm) Copyright (c).
|
90
|
+
html: <p>Registered® Trademark™ Copyright ©.</p>
|
91
|
+
---
|
92
|
+
name: acronyms
|
93
|
+
desc: Acronyms consist of three or more uppercase characters, followed immediately by words in parentheses.
|
94
|
+
in: ABC(Always Be Closing)
|
95
|
+
html: <p><acronym title="Always Be Closing"><span class="caps">ABC</span></acronym></p>
|
96
|
+
no_span_caps_html: <p><acronym title="Always Be Closing">ABC</acronym></p>
|
97
|
+
---
|
98
|
+
name: uppercase
|
99
|
+
desc: Uppercase words of three or more characters are enclosed with a special span element.
|
100
|
+
in: IBM or HAL
|
101
|
+
html: <p><span class="caps">IBM</span> or <span class="caps">HAL</span></p>
|
102
|
+
no_span_caps_html: <p>IBM or HAL</p>
|
103
|
+
---
|
104
|
+
name: emphasis
|
105
|
+
desc: Emphasis is added with _ underscores.
|
106
|
+
in: The _underlying_ cause.
|
107
|
+
html: <p>The <em>underlying</em> cause.</p>
|
108
|
+
---
|
109
|
+
name: strong text
|
110
|
+
desc: Strong text is indicated by * asterisks.
|
111
|
+
in: The *underlying* cause.
|
112
|
+
html: <p>The <strong>underlying</strong> cause.</p>
|
113
|
+
---
|
114
|
+
name: italic text
|
115
|
+
desc: em is a semantic tag, usually represented by browsers as italic text. To produce italic tags instead, use double underscores.
|
116
|
+
in: The __underlying__ cause.
|
117
|
+
html: <p>The <i>underlying</i> cause.</p>
|
118
|
+
---
|
119
|
+
name: bold text
|
120
|
+
desc: strong is a semantic tag, usually represented by browsers as bold text. To produce bold tags instead, use double asterisks.
|
121
|
+
in: The **underlying** cause.
|
122
|
+
html: <p>The <b>underlying</b> cause.</p>
|
123
|
+
---
|
124
|
+
name: citation
|
125
|
+
desc: Double question marks represent a citation, like the title of a book.
|
126
|
+
in: ??The Count of Monte Cristo??, by Dumas.
|
127
|
+
html: <p><cite>The Count of Monte Cristo</cite>, by Dumas.</p>
|
128
|
+
---
|
129
|
+
name: inserted and deleted text
|
130
|
+
desc: Inserted and deleted text is represented by + plus and - minus symbols.
|
131
|
+
in: Scratch -that-, replace with +this+.
|
132
|
+
html: <p>Scratch <del>that</del>, replace with <ins>this</ins>.</p>
|
133
|
+
---
|
134
|
+
name: subscript
|
135
|
+
desc: Subscript text is indicated by ~ tilde characters.
|
136
|
+
in: log ~2~ n
|
137
|
+
html: <p>log <sub>2</sub> n</p>
|
138
|
+
---
|
139
|
+
name: superscript
|
140
|
+
desc: Superscript text is indicated by ^ caret characters.
|
141
|
+
in: 2 ^x^
|
142
|
+
html: <p>2 <sup>x</sup></p>
|
143
|
+
---
|
144
|
+
name: span tag
|
145
|
+
desc: Percentage marks will enclose text with a XHTML span tag.
|
146
|
+
in: The %underlying% cause.
|
147
|
+
html: <p>The <span>underlying</span> cause.</p>
|
148
|
+
---
|
149
|
+
name: code
|
150
|
+
desc: To include a short snippet of code such as XHTML or Javascript, surround it with @ “at” symbols. XHTML significant characters within a code phrase will be escaped for display to the reader.
|
151
|
+
in: About the @<hr />@ tag.
|
152
|
+
html: <p>About the <code><hr /></code> tag.</p>
|
153
|
+
---
|
154
|
+
name: links
|
155
|
+
desc: Links are represented by double quotes and a colon.
|
156
|
+
in: '"link text":http://example.com/'
|
157
|
+
html: <p><a href="http://example.com/">link text</a></p>
|
158
|
+
---
|
159
|
+
name: local links
|
160
|
+
desc: The host name may be ommitted for local links.
|
161
|
+
in: '"link text":/example'
|
162
|
+
html: <p><a href="/example">link text</a></p>
|
163
|
+
---
|
164
|
+
name: link title
|
165
|
+
desc: A title may be placed in () parentheses.
|
166
|
+
in: '"link text(with title)":http://example.com/'
|
167
|
+
html: <p><a href="http://example.com/" title="with title">link text</a></p>
|
168
|
+
---
|
169
|
+
name: link alias
|
170
|
+
desc: For frequent linking to a single URL, you can specify a link alias with [] square brackets.
|
171
|
+
in: |-
|
172
|
+
Here's "a link":tstate, and
|
173
|
+
"another link":tstate to the same site.
|
174
|
+
|
175
|
+
[tstate]http://thresholdstate.com/
|
176
|
+
html: |-
|
177
|
+
<p>Here’s <a href="http://thresholdstate.com/">a link</a>, and<br />
|
178
|
+
<a href="http://thresholdstate.com/">another link</a> to the same site.</p>
|
179
|
+
---
|
180
|
+
name: image
|
181
|
+
desc: Use ! exclamation marks to insert an image tag.
|
182
|
+
in: "!/img.gif!"
|
183
|
+
html: <p><img src="/img.gif" alt="" /></p>
|
184
|
+
---
|
185
|
+
name: image 2
|
186
|
+
in: "!http://thresholdstate.com/img.gif!"
|
187
|
+
html: <p><img src="http://thresholdstate.com/img.gif" alt="" /></p>
|
188
|
+
---
|
189
|
+
name: image alt
|
190
|
+
desc: Use () parentheses to include “alt” text.
|
191
|
+
in: "!/img.gif(alt text)!"
|
192
|
+
html: <p><img src="/img.gif" title="alt text" alt="alt text" /></p>
|
193
|
+
---
|
194
|
+
name: image links
|
195
|
+
desc: Images may be combined with links by using an !image! in place of the link text.
|
196
|
+
in: "!/img.gif!:http://textpattern.com/"
|
197
|
+
html: <p><a href="http://textpattern.com/"><img src="/img.gif" alt="" /></a></p>
|
198
|
+
---
|
199
|
+
name: headers
|
200
|
+
desc: Headers are represented by h1., h2., … h6..
|
201
|
+
in: h1. Heading 1
|
202
|
+
html: <h1>Heading 1</h1>
|
203
|
+
---
|
204
|
+
name: headers 2
|
205
|
+
in: h2. Heading 2
|
206
|
+
html: <h2>Heading 2</h2>
|
207
|
+
---
|
208
|
+
name: headers 3
|
209
|
+
in: h6. Heading 6
|
210
|
+
html: <h6>Heading 6</h6>
|
211
|
+
---
|
212
|
+
name: paragraph text
|
213
|
+
desc: "Paragraph p text is represented by p.. This is the default block type: any paragraph without a block modifier will automatically be enclosed with p tags."
|
214
|
+
in: |-
|
215
|
+
p. A paragraph.
|
216
|
+
Continued.
|
217
|
+
|
218
|
+
Also a paragraph.
|
219
|
+
html: |-
|
220
|
+
<p>A paragraph.<br />
|
221
|
+
Continued.</p>
|
222
|
+
<p>Also a paragraph.</p>
|
223
|
+
---
|
224
|
+
name: block quote
|
225
|
+
desc: bq. indicates a quoted block of text.
|
226
|
+
in: |-
|
227
|
+
bq. A quotation.
|
228
|
+
Continued.
|
229
|
+
|
230
|
+
Regular paragraph.
|
231
|
+
html: |-
|
232
|
+
<blockquote>
|
233
|
+
<p>A quotation.<br />
|
234
|
+
Continued.</p>
|
235
|
+
</blockquote>
|
236
|
+
<p>Regular paragraph.</p>
|
237
|
+
---
|
238
|
+
name: block quote citation
|
239
|
+
desc: Block quotes may include a citation URL immediately following the period.
|
240
|
+
in: bq.:http://thresholdstate.com/ A cited quotation.
|
241
|
+
html: |-
|
242
|
+
<blockquote cite="http://thresholdstate.com/">
|
243
|
+
<p>A cited quotation.</p>
|
244
|
+
</blockquote>
|
245
|
+
---
|
246
|
+
name: footnotes
|
247
|
+
desc: Footnotes are represented by the fn1., fn2., … block modifiers.
|
248
|
+
in: |-
|
249
|
+
A footnote reference[1].
|
250
|
+
|
251
|
+
fn1. The footnote.
|
252
|
+
html: |-
|
253
|
+
<p>A footnote reference<sup class="footnote"><a href="#fn1">1</a></sup>.</p>
|
254
|
+
<p class="footnote" id="fn1"><sup>1</sup> The footnote.</p>
|
255
|
+
# html: |-
|
256
|
+
# <p>A footnote reference<sup class="footnote"><a href="#fn1216642796463b1223ae29d">1</a></sup>.</p>
|
257
|
+
# <p class="footnote" id="fn1216642796463b1223ae29d"><sup>1</sup> The footnote.</p>
|
258
|
+
---
|
259
|
+
name: block code
|
260
|
+
desc: Code such as XHTML, Javascript or PHP may be displayed using the bc. “block code” modifier. XHTML significant characters such as < and > will be escaped within code blocks – bc is used for displaying code to the reader, not for executing it.
|
261
|
+
note: Note that Textile will interpret any blank lines within the code as indicating the end of the code block. See Extended Blocks below for an explanation of how to display longer blocks of code.
|
262
|
+
in: |-
|
263
|
+
bc. <script>
|
264
|
+
// a Javascript example
|
265
|
+
alert("Hello World");
|
266
|
+
</script>
|
267
|
+
html: |-
|
268
|
+
<pre><code><script>
|
269
|
+
// a Javascript example
|
270
|
+
alert("Hello World");
|
271
|
+
</script></code></pre>
|
272
|
+
---
|
273
|
+
name: preformatted text
|
274
|
+
desc: Use the pre. block modifier for pre-formatted text. XHTML significant characters within the block will be escaped.
|
275
|
+
note: pre. is almost identical to bc., with the exception that <code>...</code> tags are not used within the <pre> block.
|
276
|
+
in: |-
|
277
|
+
pre. Pre-formatted
|
278
|
+
text
|
279
|
+
html: |-
|
280
|
+
<pre>Pre-formatted
|
281
|
+
text</pre>
|
282
|
+
---
|
283
|
+
name: notextile
|
284
|
+
desc: The notextile. block modifier applies no Textile processing at all to a block. Raw XHTML characters are passed through untouched, so this may be used to insert explicit XHTML markup, or execute Javascript or PHP code.
|
285
|
+
in: |-
|
286
|
+
notextile. <script type="text/javascript">
|
287
|
+
document.write("Hello World!");
|
288
|
+
</script>
|
289
|
+
<noscript>Your browser doesn't support Javascript</noscript>
|
290
|
+
html: |-
|
291
|
+
<script type="text/javascript">
|
292
|
+
document.write("Hello World!");
|
293
|
+
</script>
|
294
|
+
<noscript>Your browser doesn't support Javascript</noscript>
|
295
|
+
valid_html: false
|
296
|
+
---
|
297
|
+
name: class attribute
|
298
|
+
desc: CSS classes are specified with () parentheses.
|
299
|
+
in: p(myclass). My classy paragraph.
|
300
|
+
html: <p class="myclass">My classy paragraph.</p>
|
301
|
+
---
|
302
|
+
name: id attribute
|
303
|
+
desc: CSS IDs are specified with () parentheses.
|
304
|
+
in: p(#myid). My ID paragraph.
|
305
|
+
html: <p id="myid">My ID paragraph.</p>
|
306
|
+
---
|
307
|
+
name: style attribute
|
308
|
+
desc: CSS styles are specified with {} braces.
|
309
|
+
in: p{color:red}. Red rum.
|
310
|
+
html: <p style="color:red;">Red rum.</p>
|
311
|
+
---
|
312
|
+
name: lang attribute
|
313
|
+
desc: Languages are specified with [] brackets.
|
314
|
+
in: p[fr-fr]. En français.
|
315
|
+
html: <p lang="fr-fr">En français.</p>
|
316
|
+
---
|
317
|
+
name: phrase modifiers
|
318
|
+
desc: The same syntax may be applied to phrase modifiers.
|
319
|
+
in: A *(myclass)classy* phrase.
|
320
|
+
html: <p>A <strong class="myclass">classy</strong> phrase.</p>
|
321
|
+
---
|
322
|
+
name: phrase modifiers 2
|
323
|
+
in: An _(#myid2)ID_ phrase.
|
324
|
+
html: <p>An <em id="myid2">ID</em> phrase.</p>
|
325
|
+
---
|
326
|
+
name: phrase modifiers 3
|
327
|
+
in: The %{color:blue}blue% room.
|
328
|
+
html: <p>The <span style="color:blue;">blue</span> room.</p>
|
329
|
+
---
|
330
|
+
name: block and phrase attributes combined
|
331
|
+
desc: Block and phrase attributes may be combined.
|
332
|
+
in: p(myclass#myid3){color:green}[de-de]. A complex paragraph.
|
333
|
+
html: <p style="color:green;" class="myclass" lang="de-de" id="myid3">A complex paragraph.</p>
|
334
|
+
---
|
335
|
+
name: block and phrase attributes combined 2
|
336
|
+
in: A ??(myclass#myid4){color:green}[de-de]complex?? phrase.
|
337
|
+
html: <p>A <cite style="color:green;" class="myclass" lang="de-de" id="myid4">complex</cite> phrase.</p>
|
338
|
+
---
|
339
|
+
name: extended blocks
|
340
|
+
desc: Normally a block modifier covers a single block of text, and ends at the first blank line. To extend a block over multiple paragraphs that include blank lines, use a block modifier with two period marks instead of one. To close the extended block, use a different block modifier on the next paragraph.
|
341
|
+
in: |-
|
342
|
+
bq.. A quote.
|
343
|
+
|
344
|
+
The quote continued.
|
345
|
+
|
346
|
+
p. Back to paragraph text.
|
347
|
+
html: |-
|
348
|
+
<blockquote>
|
349
|
+
<p>A quote.</p>
|
350
|
+
<p>The quote continued.</p>
|
351
|
+
</blockquote>
|
352
|
+
<p>Back to paragraph text.</p>
|
353
|
+
---
|
354
|
+
name: extended block code
|
355
|
+
desc: Extended blocks are useful for displaying longer examples of code that contain blank lines.
|
356
|
+
in: |-
|
357
|
+
A PHP code example.
|
358
|
+
|
359
|
+
bc.. <?php
|
360
|
+
function hello() {
|
361
|
+
// display a hello message
|
362
|
+
|
363
|
+
print "Hello, World";
|
364
|
+
}
|
365
|
+
?>
|
366
|
+
|
367
|
+
p. Following paragraph.
|
368
|
+
html: |-
|
369
|
+
<p>A <span class="caps">PHP</span> code example.</p>
|
370
|
+
<pre><code><?php
|
371
|
+
function hello() {
|
372
|
+
// display a hello message</code>
|
373
|
+
|
374
|
+
<code>print "Hello, World";
|
375
|
+
}
|
376
|
+
?></code>
|
377
|
+
|
378
|
+
</pre>
|
379
|
+
<p>Following paragraph.</p>
|
380
|
+
---
|
381
|
+
name: extended block attributes
|
382
|
+
desc: Any block attributes on an extended block will be included on each following block.
|
383
|
+
in: |-
|
384
|
+
p(myclass).. A classy paragraph.
|
385
|
+
|
386
|
+
Another classy paragraph.
|
387
|
+
|
388
|
+
p. Not so classy.
|
389
|
+
html: |-
|
390
|
+
<p class="myclass">A classy paragraph.</p>
|
391
|
+
<p class="myclass">Another classy paragraph.</p>
|
392
|
+
<p>Not so classy.</p>
|
393
|
+
---
|
394
|
+
name: extended block quote attributes
|
395
|
+
desc: Attributes on bq.. extended blocks will be included on both the inner and outer blocks.
|
396
|
+
in: |-
|
397
|
+
bq(myclass).. Quote paragraph 1.
|
398
|
+
|
399
|
+
Paragraph 2.
|
400
|
+
html: |-
|
401
|
+
<blockquote class="myclass">
|
402
|
+
<p class="myclass">Quote paragraph 1.</p>
|
403
|
+
<p class="myclass">Paragraph 2.</p>
|
404
|
+
</blockquote>
|
405
|
+
---
|
406
|
+
name: extended block code attributes
|
407
|
+
desc: Attributes on bc.. extended blocks will be included on both the inner and outer blocks.
|
408
|
+
in: |-
|
409
|
+
bc(myclass).. Code block 1.
|
410
|
+
|
411
|
+
Code block 2.
|
412
|
+
html: |-
|
413
|
+
<pre class="myclass"><code class="myclass">Code block 1.</code>
|
414
|
+
|
415
|
+
<code class="myclass">Code block 2.</code></pre>
|
416
|
+
---
|
417
|
+
name: raw xhtml left in tact
|
418
|
+
desc: Raw XHTML tags are generally left untouched by Textile. Span tags that enclose only part of a block of text will be left intact, while the block itself is treated normally.
|
419
|
+
in: <b>bold</b> and <i>italic</i>, the hard way.
|
420
|
+
html: <p><b>bold</b> and <i>italic</i>, the hard way.</p>
|
421
|
+
---
|
422
|
+
name: paragraphs entirely raw xhtml
|
423
|
+
desc: Paragraphs that consist entirely of raw XHTML block tags will not be enclosed in <p>...</p> tags.
|
424
|
+
in: <div class="mydiv">My div</div>
|
425
|
+
html: <div class="mydiv">My div</div>
|
426
|
+
---
|
427
|
+
name: paragraphs with inline xhtml
|
428
|
+
desc: Paragraphs that consist only of inline XHTML tags, will be enclosed in <p>...</p> tags.
|
429
|
+
in: <img src="/img.gif" alt="image" />
|
430
|
+
html: <p><img src="/img.gif" alt="image" /></p>
|
431
|
+
---
|
432
|
+
name: paragraphs with inline xhtml 2
|
433
|
+
in: <span class="myspan">I'll make my own way.</span>
|
434
|
+
html: '<p><span class="myspan">I’ll make my own way.</span></p>'
|
435
|
+
---
|
436
|
+
name: paragraphs partly enclosed in xhtml block tags
|
437
|
+
desc: Paragraphs that are only partly enclosed in block tags will be enclosed in <p>...</p> tags.
|
438
|
+
in: <div>inside</div> and outside.
|
439
|
+
html: <div>inside</div> <p>and outside.</p>
|
440
|
+
# html: <p><div>inside</div> and outside.</p>
|
441
|
+
---
|
442
|
+
name: complex xhtml blocks
|
443
|
+
desc: Textile can’t always identify the beginning and end of long or complex blocks of XHTML. To prevent Textile from enclosing complex XHTML blocks in paragraph tags, either use a space at the beginning of each line...
|
444
|
+
in: " <div>\n <span>My div</span>\n </div>"
|
445
|
+
html: "<div>\n<span>My div</span>\n</div>"
|
446
|
+
---
|
447
|
+
name: complex xhtml blocks 2
|
448
|
+
desc: ...or a notexile.. extended block.
|
449
|
+
in: |-
|
450
|
+
notextile.. <div>
|
451
|
+
|
452
|
+
<span>My div</span>
|
453
|
+
|
454
|
+
</div>
|
455
|
+
html: |-
|
456
|
+
<div>
|
457
|
+
|
458
|
+
<span>My div</span>
|
459
|
+
|
460
|
+
</div>
|
461
|
+
---
|
462
|
+
name: complex xhtml blocks with inline formatting
|
463
|
+
desc: Textile will not wrap lines that start with a space in paragraph tags, but it should parse inline signatures
|
464
|
+
in: " <div>\n <span>My *div*</span>\n </div>"
|
465
|
+
html: "<div>\n<span>My <strong>div</strong></span>\n</div>"
|
466
|
+
---
|
467
|
+
name: explicit pre escapement
|
468
|
+
desc: The contents of explicit <pre>...</pre> tags are escaped for display.
|
469
|
+
in: |-
|
470
|
+
<pre>
|
471
|
+
A HTML <b>example</b>
|
472
|
+
</pre>
|
473
|
+
html: |-
|
474
|
+
<pre>
|
475
|
+
A HTML <b>example</b>
|
476
|
+
</pre>
|
477
|
+
note: This syntax is supported for backwards compatibility only, and doesn’t always work as expected. The block modifier pre. should be used instead.
|
478
|
+
---
|
479
|
+
name: explicit code escapement
|
480
|
+
desc: The contents of explicit <code>...</code> tags are escaped for display.
|
481
|
+
in: |-
|
482
|
+
<code>
|
483
|
+
Another HTML <b>example</b>
|
484
|
+
</code>
|
485
|
+
html: |-
|
486
|
+
<p><code>
|
487
|
+
Another HTML <b>example</b>
|
488
|
+
</code></p>
|
489
|
+
note: This syntax is supported for backwards compatibility only, and doesn’t always work as expected. The block modifier bc. should be used instead.
|
490
|
+
---
|
491
|
+
name: notextile tags
|
492
|
+
desc: Blocks enclosed by the pseudo tag <notextile>...</notextile> will be left untouched.
|
493
|
+
in: |-
|
494
|
+
<notextile>
|
495
|
+
p. Leave me alone
|
496
|
+
</notextile>
|
497
|
+
html: |-
|
498
|
+
p. Leave me alone
|
499
|
+
# html: |-
|
500
|
+
# <p>
|
501
|
+
# p. Leave me alone
|
502
|
+
# </p>
|
503
|
+
note: This syntax is supported for backwards compatibility only, and doesn’t always work as expected. The block modifier notextile. should be used instead.
|
504
|
+
valid_html: false
|
505
|
+
---
|
506
|
+
name: left aligned text
|
507
|
+
desc: Left alignment is specified with a < less than symbol.
|
508
|
+
in: p<. Left-aligned paragraph.
|
509
|
+
html: <p style="text-align:left;">Left-aligned paragraph.</p>
|
510
|
+
---
|
511
|
+
name: right aligned text
|
512
|
+
desc: Right alignment is specified with a > greater than symbol.
|
513
|
+
in: h3>. Right-aligned heading.
|
514
|
+
html: <h3 style="text-align:right;">Right-aligned heading.</h3>
|
515
|
+
---
|
516
|
+
name: justified text
|
517
|
+
desc: Use both <> symbols for justified text.
|
518
|
+
in: p<>. Justified paragraph.
|
519
|
+
html: <p style="text-align:justify;">Justified paragraph.</p>
|
520
|
+
---
|
521
|
+
name: centered text
|
522
|
+
desc: An = equals symbol represents centered text.
|
523
|
+
in: h3=. Centered heading.
|
524
|
+
html: <h3 style="text-align:center;">Centered heading.</h3>
|
525
|
+
---
|
526
|
+
name: padding
|
527
|
+
desc: Use empty ( and ) parentheses to add padding to blocks, in multiples of 1 em.
|
528
|
+
in: p(. Left pad 1em.
|
529
|
+
html: <p style="padding-left:1em;">Left pad 1em.</p>
|
530
|
+
---
|
531
|
+
name: padding 2
|
532
|
+
in: p)). Right pad 2em.
|
533
|
+
html: <p style="padding-right:2em;">Right pad 2em.</p>
|
534
|
+
---
|
535
|
+
name: padding 3
|
536
|
+
in: p(). Left and right pad 1em.
|
537
|
+
html: <p style="padding-left:1em;padding-right:1em;">Left and right pad 1em.</p>
|
538
|
+
---
|
539
|
+
name: numeric lists
|
540
|
+
desc: Numeric lists are represented by lines beginning with #.
|
541
|
+
in: |-
|
542
|
+
# Item one
|
543
|
+
# Item two
|
544
|
+
# Item three
|
545
|
+
html: |-
|
546
|
+
<ol>
|
547
|
+
<li>Item one</li>
|
548
|
+
<li>Item two</li>
|
549
|
+
<li>Item three</li>
|
550
|
+
</ol>
|
551
|
+
---
|
552
|
+
name: bulleted lists
|
553
|
+
desc: Bulleted lists are represented by lines beginning with *.
|
554
|
+
in: |-
|
555
|
+
* Item A
|
556
|
+
* Item B
|
557
|
+
* Item C
|
558
|
+
html: |-
|
559
|
+
<ul>
|
560
|
+
<li>Item A</li>
|
561
|
+
<li>Item B</li>
|
562
|
+
<li>Item C</li>
|
563
|
+
</ul>
|
564
|
+
---
|
565
|
+
name: list attributes
|
566
|
+
desc: Attributes applied to the first list item will apply to the list itself.
|
567
|
+
in: |-
|
568
|
+
*{color:red} Item one
|
569
|
+
* Item two
|
570
|
+
* Item three
|
571
|
+
html: |-
|
572
|
+
<ul style="color:red;">
|
573
|
+
<li>Item one</li>
|
574
|
+
<li>Item two</li>
|
575
|
+
<li>Item three</li>
|
576
|
+
</ul>
|
577
|
+
---
|
578
|
+
name: nested lists
|
579
|
+
desc: Use multiple # or * symbols to create nested lists.
|
580
|
+
in: |-
|
581
|
+
# Item one
|
582
|
+
## Item one-A
|
583
|
+
## Item one-B
|
584
|
+
### Item one-B-a
|
585
|
+
# Item two
|
586
|
+
html: |-
|
587
|
+
<ol>
|
588
|
+
<li>Item one
|
589
|
+
<ol>
|
590
|
+
<li>Item one-A</li>
|
591
|
+
<li>Item one-B
|
592
|
+
<ol>
|
593
|
+
<li>Item one-B-a</li>
|
594
|
+
</ol></li>
|
595
|
+
</ol></li>
|
596
|
+
<li>Item two</li>
|
597
|
+
</ol>
|
598
|
+
---
|
599
|
+
name: tables
|
600
|
+
desc: Tables can be constructed using | “pipe” symbols to separate cells.
|
601
|
+
in: |a|simple|table|
|
602
|
+
html: |-
|
603
|
+
<table>
|
604
|
+
<tr>
|
605
|
+
<td>a</td>
|
606
|
+
<td>simple</td>
|
607
|
+
<td>table</td>
|
608
|
+
</tr>
|
609
|
+
</table>
|
610
|
+
---
|
611
|
+
name: table heading cells
|
612
|
+
desc: Use _. to indicate table heading cells.
|
613
|
+
in: |-
|
614
|
+
|_. a|_. table|_. heading|
|
615
|
+
|a|table|row|
|
616
|
+
html: |-
|
617
|
+
<table>
|
618
|
+
<tr>
|
619
|
+
<th>a</th>
|
620
|
+
<th>table</th>
|
621
|
+
<th>heading</th>
|
622
|
+
</tr>
|
623
|
+
<tr>
|
624
|
+
<td>a</td>
|
625
|
+
<td>table</td>
|
626
|
+
<td>row</td>
|
627
|
+
</tr>
|
628
|
+
</table>
|
629
|
+
---
|
630
|
+
name: cell attributes
|
631
|
+
desc: Attributes may be applied separately to individual cells, rows, and entire tables. Cell attributes are placed within each cell.
|
632
|
+
in: |a|{color:red}. styled|cell|
|
633
|
+
html: |-
|
634
|
+
<table>
|
635
|
+
<tr>
|
636
|
+
<td>a</td>
|
637
|
+
<td style="color:red;">styled</td>
|
638
|
+
<td>cell</td>
|
639
|
+
</tr>
|
640
|
+
</table>
|
641
|
+
---
|
642
|
+
name: row attributes
|
643
|
+
desc: Row attributes are placed at the beginning of a row, followed by a dot and a space.
|
644
|
+
in: (rowclass). |a|classy|row|
|
645
|
+
html: |-
|
646
|
+
<table>
|
647
|
+
<tr class="rowclass">
|
648
|
+
<td>a</td>
|
649
|
+
<td>classy</td>
|
650
|
+
<td>row</td>
|
651
|
+
</tr>
|
652
|
+
</table>
|
653
|
+
---
|
654
|
+
name: table attributes
|
655
|
+
desc: Table attributes are specified by placing the special table. block modifier immediately before the table.
|
656
|
+
in: |-
|
657
|
+
table(tableclass).
|
658
|
+
|a|classy|table|
|
659
|
+
|a|classy|table|
|
660
|
+
html: |-
|
661
|
+
<table class="tableclass">
|
662
|
+
<tr>
|
663
|
+
<td>a</td>
|
664
|
+
<td>classy</td>
|
665
|
+
<td>table</td>
|
666
|
+
</tr>
|
667
|
+
<tr>
|
668
|
+
<td>a</td>
|
669
|
+
<td>classy</td>
|
670
|
+
<td>table</td>
|
671
|
+
</tr>
|
672
|
+
</table>
|
673
|
+
---
|
674
|
+
name: vertical alignment
|
675
|
+
desc: Special alignment symbols are available for vertical alignment within table cells.
|
676
|
+
in: |^. top alignment|
|
677
|
+
html: |-
|
678
|
+
<table>
|
679
|
+
<tr>
|
680
|
+
<td style="vertical-align:top;">top alignment</td>
|
681
|
+
</tr>
|
682
|
+
</table>
|
683
|
+
---
|
684
|
+
name: vertical alignment 2
|
685
|
+
in: |-
|
686
|
+
|-. middle alignment|
|
687
|
+
html: |-
|
688
|
+
<table>
|
689
|
+
<tr>
|
690
|
+
<td style="vertical-align:middle;">middle alignment</td>
|
691
|
+
</tr>
|
692
|
+
</table>
|
693
|
+
---
|
694
|
+
name: vertical alignment 3
|
695
|
+
in: |-
|
696
|
+
|~. bottom alignment|
|
697
|
+
html: |-
|
698
|
+
<table>
|
699
|
+
<tr>
|
700
|
+
<td style="vertical-align:bottom;">bottom alignment</td>
|
701
|
+
</tr>
|
702
|
+
</table>
|
703
|
+
---
|
704
|
+
name: column span
|
705
|
+
desc: Use a \ backslash to indicate a column span.
|
706
|
+
in: |-
|
707
|
+
|\2. spans two cols |
|
708
|
+
| col 1 | col 2 |
|
709
|
+
html: |-
|
710
|
+
<table>
|
711
|
+
<tr>
|
712
|
+
<td colspan="2">spans two cols </td>
|
713
|
+
</tr>
|
714
|
+
<tr>
|
715
|
+
<td> col 1 </td>
|
716
|
+
<td> col 2 </td>
|
717
|
+
</tr>
|
718
|
+
</table>
|
719
|
+
---
|
720
|
+
name: row span
|
721
|
+
desc: Use a / forward slash to indicate a row span.
|
722
|
+
in: |-
|
723
|
+
|/3. spans 3 rows | row a |
|
724
|
+
| row b |
|
725
|
+
| row c |
|
726
|
+
html: |-
|
727
|
+
<table>
|
728
|
+
<tr>
|
729
|
+
<td rowspan="3">spans 3 rows </td>
|
730
|
+
<td> row a </td>
|
731
|
+
</tr>
|
732
|
+
<tr>
|
733
|
+
<td> row b </td>
|
734
|
+
</tr>
|
735
|
+
<tr>
|
736
|
+
<td> row c </td>
|
737
|
+
</tr>
|
738
|
+
</table>
|
739
|
+
---
|
740
|
+
name: whitespace required
|
741
|
+
desc: Links, images and phrase modifiers normally require surrounding whitespace.
|
742
|
+
in: this*won't*work
|
743
|
+
html: <p>this*won’t*work</p>
|
744
|
+
---
|
745
|
+
name: modifier without whitespace
|
746
|
+
desc: To use these without whitespace, surround the modifier with [] square brackets.
|
747
|
+
in: this[*will*]work
|
748
|
+
html: <p>this<strong>will</strong>work</p>
|
749
|
+
---
|
750
|
+
name: modifier without whitespace 2
|
751
|
+
desc: This is particularly useful in conjunction with superscript and subscript.
|
752
|
+
in: 1[^st^], 2[^nd^], 3[^rd^].
|
753
|
+
html: <p>1<sup>st</sup>, 2<sup>nd</sup>, 3<sup>rd</sup>.</p>
|
754
|
+
---
|
755
|
+
name: modifier without whitespace 3
|
756
|
+
in: 2 log[~n~]
|
757
|
+
html: <p>2 log<sub>n</sub></p>
|
758
|
+
---
|
759
|
+
name: modifier without whitespace 4
|
760
|
+
desc: It can also be used to include links and images without surrounding whitespace.
|
761
|
+
in: |-
|
762
|
+
A close[!/img.gif!]image.
|
763
|
+
A tight["text":http://thresholdstate.com/]link.
|
764
|
+
A ["footnoted link":http://thresholdstate.com/][1].
|
765
|
+
html: |-
|
766
|
+
<p>A close<img src="/img.gif" alt="" />image.<br />
|
767
|
+
A tight<a href="http://thresholdstate.com/">text</a>link.<br />
|
768
|
+
A <a href="http://thresholdstate.com/">footnoted link</a><sup class="footnote"><a href="#fn1">1</a></sup>.</p>
|
769
|
+
# html: |-
|
770
|
+
# <p>A close<img src="/img.gif" alt="" />image.<br />
|
771
|
+
# A tight<a href="http://thresholdstate.com/">text</a>link.<br />
|
772
|
+
# A <a href="http://thresholdstate.com/">footnoted link</a><sup class="footnote"><a href="#fn1216642796463b1223ae29d">1</a></sup>.</p>
|