FormatRule


Text Formatting Rules

@contents

The input text of PukiWikiis usually shown in the same way as it was entered. However, you can use the following rules to enhance your texts. The use of HTML tags is forbidden. Instead, special characters can be used to format text. Formatting rules usually apply to a certain part of the text. Such a part of a text is called a text Element.

#elements?Elements

First of all, let's describe the "world" of PukiWiki. PukiWikitreats text as a set of Elements. An empty line indicates the end of an Element. Elements can contain other Elements. Such contained Elements are called "Child Elements". The element which contains "Child Elements" is called a "Parent Element".

Example:These two lines:

~This is a paragraph. It is the parent element which contains an emphasized text element.
''This is emphasized text, which is the child element of the paragraph element.''
Will be formatted like this:

This is a paragraph. It is the parent element which contains an emphasized text element.*This is emphasized text, which is the child element of the paragraph element.*

There are two kinds of elements in PukiWiki: "Block Elements", and "Inline Elements".Block Elements, as the name suggests, consist of a whole block of text. Inline Elementsonly consist of a part of a text block. In essence, the difference between Block Elements and Inline Elements is as follows:

Next, we'll decribe the two different kinds of elements in detail.

#block?Block Elements

#paragraph?Paragraph

Inline Elements

PukiWikiassumes that each new Block is the beginning of a new paragraph, unless you instruct it to format the text differently, by using the formatting codes of other Block Elements.

~Inline Elements

A line that starts with "~" indicates the beginning of a new paragraph. "~" also enables you escape the special characters (~、-、+、:、>、|、#、//) that are normally used as "Formatting Characters". Normally, these characters indicate the beginning of another kind of Element. Thus, the only way to put the special characters as a normal text at the beginning of a Paragraph is by putting a "~" in front of them.

#quotation?Quotation

>Inline Element

A ">" character indicates the beginning of Quotation. Quotation has 3 indentation levels, indicated by: ">", ">>", and ">>>".

#lists?List

-Inline Element

At the beginning of a line,"-" indicates the beginning of an Unordered List. Unordered lists have three levels, namely:"-", "--", and "---".

+Inline Element

At the beginning of a line, "+" indicates the beginning of Numbered List. Numbered List has three levels namely:"+", "++", and "+++".

:Item|Item's Definition

Definition List is a line starting with ":" and seperated by "|" in the middle. There are three indentation levels for Definition List: ":", "::", and ":::".

You may omit the Item or the Definition. You may give mutiple definitions to an item by writing a sequence of Definition List and ommiting the Item after the first one.

#preformed?Preformatted Texts

"White Space" at the beginning of a line indicates the beginning of Preformatted Text. Line breaks are not automatically inserted in Prefomatted Text.

#table?Table

|Inline Element|Inline Element|

Inline Elements that are separated by "|", will be formatted as a Table. Remember that there needs to be a "|" character as well before the first Element of the table.

AAABBBCCCDDD

#csv?CSV Style Table

,Inline Element,Inline Element,…

Inline Elements that are separated by ","(comma), will be formatted as a Table. Note that you must write "," before the first Element of the CSV Style Table.

,aaaaaaaaa,bbbbbbb,ccccccc,left , center , right,==,<-- colspan, test

#headline?Heading

*Inline Element

A line that starts wit an "" character becomes a Heading Element. There are three levels of heading Elements, namely: "", "*",and "**".

#contents?Table of Contents

#contents

"#contents" at the beginning of the line creates Table of Contents based on the Headings. Generally, "#contents" are written on the top part of the page.

#align?LEFT-CENTERED-RIGHT

LEFT:Inline Element
CENTER:Inline Element
RIGHT:Inline Element

Writing "LEFT:", "CENTER:", or "RIGHT:" at the beginning of the line aligns the Inline Element.

#ref?Embedding Files and Images

#ref(file name)
#ref(URL of the file)

You can attach a file by writing #ref(file name) at the beginning of a line.You can place a hypertext link by writing #ref(URL of the file) at the beginning of a line.If the file attached or linked is an image, the image is displayed.

#form?Form

#comment

"#comment" at the beginning of the line embeds a form to post comments.

#pcomment

"#pcomment" at the beginning of the line embeds a form to post comments. Unlike "#comment", posted comments are recorded on a seperate page. Also, responses to a comment is displayed as tree structure.

#article

"#article" at the beginning of the line embeds a simple forum.

#vote(Option1,Option2,...)

"#vote" at the beginning of the line embeds a simple form for voting.

#inline?Inline Elements

#string?Strings

Strings

Strings are an Inline Element.

#linefeed?Line Breaks

Inline Element~

Writing "~" at the end of the line inserts End of Line a line break. End of Line is a line break within a Block Element.

&br;

Writing &br; breaks the line. Unlike "~" at the end of the line, Line Break may be used within the Item of Definition List, Item of a Table, or in the parameter of Block Elements starting with "#".

#emphasis?Emphasis

''Inline Element''

Enclosing Inline Element with '' puts emphasis on the element (Bold font).

'''Inline Element'''

Enclosing Inline Element with ''' puts emphasis on the element (Italics).

#size?Font Size

&size(Size){Inline Elements};

&size defines the size of characters. The size must be given in pixel unit(px).

#color?Font Color

&color(color){Inline Element};

&color defines the color of any Inline Element.

#delete?Deletion Line

%%Inline Element%%

Enclosed with %(semicolons), the Inline Element has a line through the middle of the text.

#note?Footnote

((Inline Elemnet))

Enclosed with (( and ))(double parenthesis), the Inline Element becomes the footnote and the link to it is placed.

#ref2?Embedding Files and Images

&ref(Attached Filename);
&ref(URL of File);

You can attach a file by writing &(file name) at any place in paragraph. You can also place a hypertext link by writing #ref(URL of the file) . If the file attached or linked is an image, the image is displayed.

#anchor?Anchor

&aname(Anchor Name);

&aname makes the anchor for Hyperlink. Place a certain place where you want to set the target of Hyperlink.

#counter?Counter

&counter;
&counter(option);

&counter shows the number of access to the current page.

#online?Online Viewer

&online;

&online shows the number of current accessors.

#version?Version

&version;

&version shows the version of current running PukiWiki.current version = / deprecated plugin:"version" param: body: /