1Text::Textile(3) User Contributed Perl Documentation Text::Textile(3)
2
3
4
6 Text::Textile - A humane web text generator.
7
9 use Text::Textile qw(textile);
10 my $text = <<EOT;
11 h1. Heading
12
13 A _simple_ demonstration of Textile markup.
14
15 * One
16 * Two
17 * Three
18
19 "More information":http://www.textism.com/tools/textile is available.
20 EOT
21
22 # procedural usage
23 my $html = textile($text);
24 print $html;
25
26 # OOP usage
27 my $textile = new Text::Textile;
28 $html = $textile->process($text);
29 print $html;
30
32 Text::Textile is a Perl-based implementation of Dean Allen's Textile
33 syntax. Textile is shorthand for doing common formatting tasks.
34
36 new( [%options] )
37 Instantiates a new Text::Textile object. Optional options can be passed
38 to initialize the object. Attributes for the options key are the same
39 as the get/set method names documented here.
40
41 set( $attribute, $value )
42 Used to set Textile attributes. Attribute names are the same as the
43 get/set method names documented here.
44
45 get( $attribute )
46 Used to get Textile attributes. Attribute names are the same as the
47 get/set method names documented here.
48
49 disable_html( [$disable] )
50 Gets or sets the "disable html" control, which allows you to prevent
51 HTML tags from being used within the text processed. Any HTML tags
52 encountered will be removed if disable html is enabled. Default
53 behavior is to allow HTML.
54
55 flavor( [$flavor] )
56 Assigns the HTML flavor of output from Text::Textile. Currently these
57 are the valid choices: html, xhtml (behaves like "xhtml1"), xhtml1,
58 xhtml2. Default flavor is "xhtml1".
59
60 Note that the xhtml2 flavor support is experimental and incomplete (and
61 will remain that way until the XHTML 2.0 draft becomes a proper
62 recommendation).
63
64 css( [$css] )
65 Gets or sets the CSS support for Textile. If CSS is enabled, Textile
66 will emit CSS rules. You may pass a 1 or 0 to enable or disable CSS
67 behavior altogether. If you pass a hashref, you may assign the CSS
68 class names that are used by Text::Textile. The following key names for
69 such a hash are recognized:
70
71 class_align_right
72 defaults to "right"
73
74 class_align_left
75 defaults to "left"
76
77 class_align_center
78 defaults to "center"
79
80 class_align_top
81 defaults to "top"
82
83 class_align_bottom
84 defaults to "bottom"
85
86 class_align_middle
87 defaults to "middle"
88
89 class_align_justify
90 defaults to "justify"
91
92 class_caps
93 defaults to "caps"
94
95 class_footnote
96 defaults to "footnote"
97
98 id_footnote_prefix
99 defaults to "fn"
100
101 charset( [$charset] )
102 Gets or sets the character set targetted for publication. At this
103 time, Text::Textile only changes its behavior if the "utf-8" character
104 set is assigned.
105
106 Specifically, if utf-8 is requested, any special characters created by
107 Textile will be output as native utf-8 characters rather than HTML
108 entities.
109
110 docroot( [$path] )
111 Gets or sets the physical file path to root of document files. This
112 path is utilized when images are referenced and size calculations are
113 needed (the Image::Size module is used to read the image dimensions).
114
115 trim_spaces( [$trim] )
116 Gets or sets the "trim spaces" control flag. If enabled, this will
117 clear any lines that have only spaces on them (the newline itself will
118 remain).
119
120 preserve_spaces( [$preserve] )
121 Gets or sets the "preserve spaces" control flag. If enabled, this will
122 replace any double spaces within the paragraph data with the  
123 HTML entity (wide space). The default is 0. Spaces will pass through to
124 the browser unchanged and render as a single space. Note that this
125 setting has no effect on spaces within "<pre>", "<code>" or "<script>".
126
127 filter_param( [$data] )
128 Gets or sets a parameter that is passed to filters.
129
130 filters( [\%filters] )
131 Gets or sets a list of filters to make available for Text::Textile to
132 use. Returns a hash reference of the currently assigned filters.
133
134 char_encoding( [$encode] )
135 Gets or sets the character encoding logical flag. If character encoding
136 is enabled, the HTML::Entities package is used to encode special
137 characters. If character encoding is disabled, only "<", ">", """ and
138 "&" are encoded to HTML entities.
139
140 disable_encode_entities( $boolean )
141 Gets or sets the disable encode entities logical flag. If this value is
142 set to true no entities are encoded at all. This also supersedes the
143 "char_encoding" flag.
144
145 handle_quotes( [$handle] )
146 Gets or sets the "smart quoting" control flag. Returns the current
147 setting.
148
149 process( $str )
150 Alternative method for invoking the textile method.
151
152 textile( $str )
153 Can be called either procedurally or as a method. Transforms $str using
154 Textile markup rules.
155
156 format_paragraph( [$args] )
157 Processes a single paragraph. The following attributes are allowed:
158
159 text
160 The text to be processed.
161
162 format_inline( [%args] )
163 Processes an inline string (plaintext) for Textile syntax. The
164 following attributes are allowed:
165
166 text
167 The text to be processed.
168
169 format_macro( %args )
170 Responsible for processing a particular macro. Arguments passed
171 include:
172
173 pre open brace character
174
175 post
176 close brace character
177
178 macro
179 the macro to be executed
180
181 The return value from this method would be the replacement text for the
182 macro given. If the macro is not defined, it will return pre + macro +
183 post, thereby preserving the original macro string.
184
185 format_cite( %args )
186 Processes text for a citation tag. The following attributes are
187 allowed:
188
189 pre Any text that comes before the citation.
190
191 text
192 The text that is being cited.
193
194 cite
195 The URL of the citation.
196
197 post
198 Any text that follows the citation.
199
200 format_code( %args )
201 Processes '@...@' type blocks (code snippets). The following attributes
202 are allowed:
203
204 text
205 The text of the code itself.
206
207 lang
208 The language (programming language) for the code.
209
210 format_classstyle( $clsty, $class, $style )
211 Returns a string of tag attributes to accomodate the class, style and
212 symbols present in $clsty.
213
214 $clsty is checked for:
215
216 "{...}"
217 style rules. If present, they are appended to $style.
218
219 "(...#...)"
220 class and/or ID name declaration
221
222 "(" (one or more)
223 pad left characters
224
225 ")" (one or more)
226 pad right characters
227
228 "[ll]"
229 language declaration
230
231 The attribute string returned will contain any combination of class,
232 id, style and/or lang attributes.
233
234 format_tag( %args )
235 Constructs an HTML tag. Accepted arguments:
236
237 tag the tag to produce
238
239 text
240 the text to output inside the tag
241
242 pre text to produce before the tag
243
244 post
245 text to produce following the tag
246
247 clsty
248 class and/or style attributes that should be assigned to the tag.
249
250 format_list( %args )
251 Takes a Textile formatted list (numeric or bulleted) and returns the
252 markup for it. Text that is passed in requires substantial parsing, so
253 the format_list method is a little involved. But it should always
254 produce a proper ordered or unordered list. If it cannot (due to
255 misbalanced input), it will return the original text. Arguments
256 accepted:
257
258 text
259 The text to be processed.
260
261 format_block( %args )
262 Processes "==xxxxx==" type blocks for filters. A filter would follow
263 the open "==" sequence and is specified within pipe characters, like
264 so:
265
266 ==|filter|text to be filtered==
267
268 You may specify multiple filters in the filter portion of the string.
269 Simply comma delimit the filters you desire to execute. Filters are
270 defined using the filters method.
271
272 format_link( %args )
273 Takes the Textile link attributes and transforms them into a hyperlink.
274
275 format_url( %args )
276 Takes the given $url and transforms it appropriately.
277
278 format_span( %args )
279 format_image( %args )
280 Returns markup for the given image. $src is the location of the image,
281 $extra contains the optional height/width and/or alt text. $url is an
282 optional hyperlink for the image. $class holds the optional CSS class
283 attribute.
284
285 Arguments you may pass:
286
287 src The "src" (URL) for the image. This may be a local path, ideally
288 starting with a "/". Images can be located within the file system
289 if the docroot method is used to specify where the docroot resides.
290 If the image can be found, the image_size method is used to
291 determine the dimensions of the image.
292
293 extra
294 Additional parameters for the image. This would include alt text,
295 height/width specification or scaling instructions.
296
297 align
298 Alignment attribute.
299
300 pre Text to produce prior to the tag.
301
302 post
303 Text to produce following the tag.
304
305 link
306 Optional URL to connect with the image tag.
307
308 clsty
309 Class and/or style attributes.
310
311 format_table( %args )
312 Takes a Wiki-ish string of data and transforms it into a full table.
313
314 apply_filters( %args )
315 The following attributes are allowed:
316
317 text
318 The text to be processed.
319
320 filters
321 An array reference of filter names to run for the given text.
322
323 encode_html( $html, $can_double_encode )
324 Encodes input $html string, escaping characters as needed to HTML
325 entities. This relies on the HTML::Entities package for full effect. If
326 unavailable, encode_html_basic is used as a fallback technique. If the
327 "char_encoding" flag is set to false, encode_html_basic is used
328 exclusively.
329
330 decode_html( $html )
331 Decodes HTML entities in $html to their natural character equivelants.
332
333 encode_html_basic( $html, $can_double_encode )
334 Encodes the input $html string for the following characters: <, >, &
335 and ". If $can_double_encode is true, all ampersand characters are
336 escaped even if they already were. If $can_double_encode is false,
337 ampersands are only escaped when they aren't part of a HTML entity
338 already.
339
340 image_size( $file )
341 Returns the size for the image identified in $file. This method relies
342 upon the Image::Size Perl package. If unavailable, image_size will
343 return undef. Otherwise, the expected return value is a list of the
344 width and height (in that order), in pixels.
345
346 encode_url( $str )
347 Encodes the query portion of a URL, escaping characters as necessary.
348
349 mail_encode( $email )
350 Encodes the email address in $email for "mailto:" links.
351
352 process_quotes( $str )
353 Processes string, formatting plain quotes into curly quotes.
354
355 default_macros
356 Returns a hashref of macros that are assigned to be processed by
357 default within the format_inline method.
358
359 _halign( $alignment )
360 Returns the alignment keyword depending on the symbol passed.
361
362 "<>"
363 becomes "justify"
364
365 "<" becomes "left"
366
367 ">" becomes "right"
368
369 "=" becomes "center"
370
371 _valign( $alignment )
372 Returns the alignment keyword depending on the symbol passed.
373
374 "^" becomes "top"
375
376 "~" becomes "bottom"
377
378 "-" becomes "middle"
379
380 _imgalign( $alignment )
381 Returns the alignment keyword depending on the symbol passed. The
382 following alignment symbols are recognized, and given preference in the
383 order listed:
384
385 "^" becomes "top"
386
387 "~" becomes "bottom"
388
389 "-" becomes "middle"
390
391 "<" becomes "left"
392
393 ">" becomes "right"
394
395 _repl( \@arr, $str )
396 An internal routine that takes a string and appends it to an array. It
397 returns a marker that is used later to restore the preserved string.
398
399 _tokenize( $str )
400 An internal routine responsible for breaking up a string into
401 individual tag and plaintext elements.
402
403 _css_defaults
404 Sets the default CSS names for CSS controlled markup. This is an
405 internal function that should not be called directly.
406
407 _strip_borders( $pre, $post )
408 This utility routine will take "border" characters off of the given
409 $pre and $post strings if they match one of these conditions:
410
411 $pre starts with "[", $post ends with "]"
412 $pre starts with "{", $post ends with "}"
413
414 If neither condition is met, then the $pre and $post values are left
415 untouched.
416
418 Text::Textile processes text in units of blocks and lines. A block
419 might also be considered a paragraph, since blocks are separated from
420 one another by a blank line. Blocks can begin with a signature that
421 helps identify the rest of the block content. Block signatures include:
422
423 p A paragraph block. This is the default signature if no signature is
424 explicitly given. Paragraphs are formatted with all the inline
425 rules (see inline formatting) and each line receives the
426 appropriate markup rules for the flavor of HTML in use. For
427 example, newlines for XHTML content receive a "<br />" tag at the
428 end of the line (with the exception of the last line in the
429 paragraph). Paragraph blocks are enclosed in a "<p>" tag.
430
431 pre A pre-formatted block of text. Textile will not add any HTML tags
432 for individual lines. Whitespace is also preserved.
433
434 Note that within a "pre" block, < and > are translated into HTML
435 entities automatically.
436
437 bc A "bc" signature is short for "block code", which implies a
438 preformatted section like the "pre" block, but it also gets a
439 "<code>" tag (or for XHTML 2, a "<blockcode>" tag is used instead).
440
441 Note that within a "bc" block, < and > are translated into HTML
442 entities automatically.
443
444 table
445 For composing HTML tables. See the "TABLES" section for more
446 information.
447
448 bq A "bq" signature is short for "block quote". Paragraph text
449 formatting is applied to these blocks and they are enclosed in a
450 <blockquote> tag as well as <p> tags within.
451
452 h1, h2, h3, h4, h5, h6
453 Headline signatures that produce "<h1>", etc. tags. You can adjust
454 the relative output of these using the head_offset attribute.
455
456 clear
457 A "clear" signature is simply used to indicate that the next block
458 should emit a CSS style attribute that clears any floating
459 elements. The default behavior is to clear "both", but you can use
460 the left (<) or right (>) alignment characters to indicate which
461 side to clear.
462
463 dl A "dl" signature is short for "definition list". See the "LISTS"
464 section for more information.
465
466 fn A "fn" signature is short for "footnote". You add a number
467 following the "fn" keyword to number the footnote. Footnotes are
468 output as paragraph tags but are given a special CSS class name
469 which can be used to style them as you see fit.
470
471 All signatures should end with a period and be followed with a space.
472 Inbetween the signature and the period, you may use several parameters
473 to further customize the block. These include:
474
475 "{style rule}"
476 A CSS style rule. Style rules can span multiple lines.
477
478 "[ll]"
479 A language identifier (for a "lang" attribute).
480
481 "(class)" or "(#id)" or "(class#id)"
482 For CSS class and id attributes.
483
484 ">", "<", "=", "<>"
485 Modifier characters for alignment. Right-justification, left-
486 justification, centered, and full-justification.
487
488 "(" (one or more)
489 Adds padding on the left. 1em per "(" character is applied. When
490 combined with the align-left or align-right modifier, it makes the
491 block float.
492
493 ")" (one or more)
494 Adds padding on the right. 1em per ")" character is applied. When
495 combined with the align-left or align-right modifier, it makes the
496 block float.
497
498 "|filter|" or "|filter|filter|filter|"
499 A filter may be invoked to further format the text for this
500 signature. If one or more filters are identified, the text will be
501 processed first using the filters and then by Textile's own block
502 formatting rules.
503
504 Extended Blocks
505 Normally, a block ends with the first blank line encountered. However,
506 there are situations where you may want a block to continue for
507 multiple paragraphs of text. To cause a given block signature to stay
508 active, use two periods in your signature instead of one. This will
509 tell Textile to keep processing using that signature until it hits the
510 next signature is found.
511
512 For example:
513
514 bq.. This is paragraph one of a block quote.
515
516 This is paragraph two of a block quote.
517
518 p. Now we're back to a regular paragraph.
519
520 You can apply this technique to any signature (although for some it
521 doesn't make sense, like "h1" for example). This is especially useful
522 for "bc" blocks where your code may have many blank lines scattered
523 through it.
524
525 Escaping
526 Sometimes you want Textile to just get out of the way and let you put
527 some regular HTML markup in your document. You can disable Textile
528 formatting for a given block using the "==" escape mechanism:
529
530 p. Regular paragraph
531
532 ==
533 Escaped portion -- will not be formatted
534 by Textile at all
535 ==
536
537 p. Back to normal.
538
539 You can also use this technique within a Textile block, temporarily
540 disabling the inline formatting functions:
541
542 p. This is ==*a test*== of escaping.
543
544 Inline Formatting
545 Formatting within a block of text is covered by the "inline" formatting
546 rules. These operators must be placed up against text/punctuation to be
547 recognized. These include:
548
549 *"strong"*
550 Translates into <strong>strong</strong>.
551
552 "_emphasis_"
553 Translates into <em>emphasis</em>.
554
555 **"bold"**
556 Translates into <b>bold</b>.
557
558 "__italics__"
559 Translates into <i>italics</i>.
560
561 "++bigger++"
562 Translates into <big>bigger</big>.
563
564 "--smaller--"
565 Translates into: <small>smaller</small>.
566
567 "-deleted text-"
568 Translates into <del>deleted text</del>.
569
570 "+inserted text+"
571 Translates into <ins>inserted text</ins>.
572
573 "^superscript^"
574 Translates into <sup>superscript</sup>.
575
576 "~subscript~"
577 Translates into <sub>subscript</sub>.
578
579 "%span%"
580 Translates into <span>span</span>.
581
582 "@code@"
583 Translates into <code>code</code>. Note that within a "@...@"
584 section, < and > are translated into HTML entities automatically.
585
586 Inline formatting operators accept the following modifiers:
587
588 "{style rule}"
589 A CSS style rule.
590
591 "[ll]"
592 A language identifier (for a "lang" attribute).
593
594 "(class)" or "(#id)" or "(class#id)"
595 For CSS class and id attributes.
596
597 Examples
598
599 Textile is *way* cool.
600
601 Textile is *_way_* cool.
602
603 Now this won't work, because the formatting characters need whitespace
604 before and after to be properly recognized.
605
606 Textile is way c*oo*l.
607
608 However, you can supply braces or brackets to further clarify that you
609 want to format, so this would work:
610
611 Textile is way c[*oo*]l.
612
613 Footnotes
614 You can create footnotes like this:
615
616 And then he went on a long trip[1].
617
618 By specifying the brackets with a number inside, Textile will recognize
619 that as a footnote marker. It will replace that with a construct like
620 this:
621
622 And then he went on a long
623 trip<sup class="footnote"><a href="#fn1">1</a></sup>
624
625 To supply the content of the footnote, place it at the end of your
626 document using a "fn" block signature:
627
628 fn1. And there was much rejoicing.
629
630 Which creates a paragraph that looks like this:
631
632 <p class="footnote" id="fn1"><sup>1</sup> And there was
633 much rejoicing.</p>
634
635 Links
636 Textile defines a shorthand for formatting hyperlinks. The format
637 looks like this:
638
639 "Text to display":http://example.com
640
641 In addition to this, you can add "title" text to your link:
642
643 "Text to display (Title text)":http://example.com
644
645 The URL portion of the link supports relative paths as well as other
646 protocols like ftp, mailto, news, telnet, etc.
647
648 "E-mail me please":mailto:someone@example.com
649
650 You can also use single quotes instead of double-quotes if you prefer.
651 As with the inline formatting rules, a hyperlink must be surrounded by
652 whitespace to be recognized (an exception to this is common punctuation
653 which can reside at the end of the URL). If you have to place a URL
654 next to some other text, use the bracket or brace trick to do that:
655
656 You["gotta":http://example.com]seethis!
657
658 Textile supports an alternate way to compose links. You can optionally
659 create a lookup list of links and refer to them separately. To do this,
660 place one or more links in a block of it's own (it can be anywhere
661 within your document):
662
663 [excom]http://example.com
664 [exorg]http://example.org
665
666 For a list like this, the text in the square brackets is used to
667 uniquely identify the link given. To refer to that link, you would
668 specify it like this:
669
670 "Text to display":excom
671
672 Once you've defined your link lookup table, you can use the identifiers
673 any number of times.
674
675 Images
676 Images are identified by the following pattern:
677
678 !/path/to/image!
679
680 Image attributes may also be specified:
681
682 !/path/to/image 10x20!
683
684 Which will render an image 10 pixels wide and 20 pixels high. Another
685 way to indicate width and height:
686
687 !/path/to/image 10w 20h!
688
689 You may also redimension the image using a percentage.
690
691 !/path/to/image 20%x40%!
692
693 Which will render the image at 20% of it's regular width and 40% of
694 it's regular height.
695
696 Or specify one percentage to resize proprotionately:
697
698 !/path/to/image 20%!
699
700 Alt text can be given as well:
701
702 !/path/to/image (Alt text)!
703
704 The path of the image may refer to a locally hosted image or can be a
705 full URL.
706
707 You can also use the following modifiers after the opening "!"
708 character:
709
710 "<" Align the image to the left (causes the image to float if CSS
711 options are enabled).
712
713 ">" Align the image to the right (causes the image to float if CSS
714 options are enabled).
715
716 "-" (dash)
717 Aligns the image to the middle.
718
719 "^" Aligns the image to the top.
720
721 "~" (tilde)
722 Aligns the image to the bottom.
723
724 "{style rule}"
725 Applies a CSS style rule to the image.
726
727 "(class)" or "(#id)" or "(class#id)"
728 Applies a CSS class and/or id to the image.
729
730 "(" (one or more)
731 Pads 1em on the left for each "(" character.
732
733 ")" (one or more)
734 Pads 1em on the right for each ")" character.
735
736 Character Replacements
737 A few simple, common symbols are automatically replaced:
738
739 (c)
740 (r)
741 (tm)
742
743 In addition to these, there are a whole set of character macros that
744 are defined by default. All macros are enclosed in curly braces. These
745 include:
746
747 {c|} or {|c} cent sign
748 {L-} or {-L} pound sign
749 {Y=} or {=Y} yen sign
750
751 Many of these macros can be guessed. For example:
752
753 {A'} or {'A}
754 {a"} or {"a}
755 {1/4}
756 {*}
757 {:)}
758 {:(}
759
760 Lists
761 Textile also supports ordered and unordered lists. You simply place an
762 asterisk or pound sign, followed with a space at the start of your
763 lines.
764
765 Simple lists:
766
767 * one
768 * two
769 * three
770
771 Multi-level lists:
772
773 * one
774 ** one A
775 ** one B
776 *** one B1
777 * two
778 ** two A
779 ** two B
780 * three
781
782 Ordered lists:
783
784 # one
785 # two
786 # three
787
788 Styling lists:
789
790 (class#id)* one
791 * two
792 * three
793
794 The above sets the class and id attributes for the <ul> tag.
795
796 *(class#id) one
797 * two
798 * three
799
800 The above sets the class and id attributes for the first <li> tag.
801
802 Definition lists:
803
804 dl. textile:a cloth, especially one manufactured by weaving
805 or knitting; a fabric
806 format:the arrangement of data for storage or display.
807
808 Note that there is no space between the term and definition. The term
809 must be at the start of the line (or following the "dl" signature as
810 shown above).
811
812 Tables
813 Textile supports tables. Tables must be in their own block and must
814 have pipe characters delimiting the columns. An optional block
815 signature of "table" may be used, usually for applying style, class, id
816 or other options to the table element itself.
817
818 From the simple:
819
820 |a|b|c|
821 |1|2|3|
822
823 To the complex:
824
825 table(fig). {color:red}_|Top|Row|
826 {color:blue}|/2. Second|Row|
827 |_{color:green}. Last|
828
829 Modifiers can be specified for the table signature itself, for a table
830 row (prior to the first "|" character) and for any cell (following the
831 "|" for that cell). Note that for cells, a period followed with a space
832 must be placed after any modifiers to distinguish the modifier from the
833 cell content.
834
835 Modifiers allowed are:
836
837 "{style rule}"
838 A CSS style rule.
839
840 "(class)" or "(#id)" or "(class#id)"
841 A CSS class and/or id attribute.
842
843 "(" (one or more)
844 Adds 1em of padding to the left for each "(" character.
845
846 ")" (one or more)
847 Adds 1em of padding to the right for each ")" character.
848
849 "<" Aligns to the left (floats to left for tables if combined with the
850 ")" modifier).
851
852 ">" Aligns to the right (floats to right for tables if combined with
853 the "(" modifier).
854
855 "=" Aligns to center (sets left, right margins to "auto" for tables).
856
857 "<>"
858 For cells only. Justifies text.
859
860 "^" For rows and cells only. Aligns to the top.
861
862 "~" (tilde)
863 For rows and cells only. Aligns to the bottom.
864
865 "_" (underscore)
866 Can be applied to a table row or cell to indicate a header row or
867 cell.
868
869 "\2" or "\3" or "\4", etc.
870 Used within cells to indicate a colspan of 2, 3, 4, etc. columns.
871 When you see "\", think "push forward".
872
873 "/2" or "/3" or "/4", etc.
874 Used within cells to indicate a rowspan or 2, 3, 4, etc. rows.
875 When you see "/", think "push downward".
876
877 When a cell is identified as a header cell and an alignment is
878 specified, that becomes the default alignment for cells below it. You
879 can always override this behavior by specifying an alignment for one of
880 the lower cells.
881
882 CSS Notes
883 When CSS is enabled (and it is by default), CSS class names are
884 automatically applied in certain situations.
885
886 Aligning a block or span or other element to left, right, etc.
887 "left" for left justified, "right" for right justified, "center"
888 for centered text, "justify" for full-justified text.
889
890 Aligning an image to the top or bottom
891 "top" for top alignment, "bottom" for bottom alignment, "middle"
892 for middle alignment.
893
894 Footnotes
895 "footnote" is applied to the paragraph tag for the footnote text
896 itself. An id of "fn" plus the footnote number is placed on the
897 paragraph for the footnote as well. For the footnote superscript
898 tag, a class of "footnote" is used.
899
900 Capped text
901 For a series of characters that are uppercased, a span is placed
902 around them with a class of "caps".
903
904 Miscellaneous
905 Textile tries to do it's very best to ensure proper XHTML syntax. It
906 will even attempt to fix errors you may introduce writing in HTML
907 yourself. Unescaped "&" characters within URLs will be properly
908 escaped. Singlet tags such as br, img and hr are checked for the "/"
909 terminator (and it's added if necessary). The best way to make sure you
910 produce valid XHTML with Textile is to not use any HTML markup at all--
911 use the Textile syntax and let it produce the markup for you.
912
914 Text::Textile is hosted at github.
915
916 Source: <http://github.com/bradchoate/text-textile/tree/master>
917
918 Bugs: <http://github.com/bradchoate/text-textile/issues>
919
921 Copyright 2005-2009 Brad Choate, brad@bradchoate.com.
922
923 This program is free software; you can redistribute it and/or modify it
924 under the terms of either:
925
926 · the GNU General Public License as published by the Free Software
927 Foundation; either version 1, or (at your option) any later
928 version, or
929
930 · the Artistic License version 2.0.
931
932 Text::Textile is an adaptation of Textile, developed by Dean Allen of
933 Textism.com.
934
935
936
937perl v5.32.0 2020-07-28 Text::Textile(3)