Difference between revisions of "Help:Formatting"
(Created page with "__NOEDITSECTION__{{Help Nav}}You can format your text using the formatting toolbar or wiki markup. Wiki markup can be thought of as a simplified ve...") |
m |
||
(3 intermediate revisions by one other user not shown) | |||
Line 3: | Line 3: | ||
== Text Formatting == | == Text Formatting == | ||
− | { | + | {| class="wikitable" width="80%" |
+ | ! Description !! You type !! You get | ||
+ | |- | ||
+ | ! colspan="3" style="background:#ABE" | character (inline) formatting – ''applies anywhere'' | ||
+ | |- | ||
+ | |Italic text | ||
+ | | <code><nowiki>''italic''</nowiki></code> | ||
+ | |''italic'' | ||
+ | |- | ||
+ | | Bold text | ||
+ | | <code><nowiki>'''bold'''</nowiki></code> | ||
+ | |'''bold''' | ||
+ | |- | ||
+ | | Bold and italic | ||
+ | | <code><nowiki>'''''bold & italic'''''</nowiki></code> | ||
+ | |'''''bold & italic''''' | ||
+ | |- | ||
+ | |Ignore wiki markup | ||
+ | | <code><nowiki><nowiki>no ''markup''</nowiki></nowiki></code> | ||
+ | |<nowiki>no ''markup''</nowiki> | ||
+ | |- | ||
+ | ! colspan="3" style="background:#ABE" | section formatting – ''only at the beginning of the line'' | ||
+ | |- | ||
+ | |Preformatted text | ||
+ | | | ||
+ | <pre> | ||
+ | preformatted text is done with | ||
+ | a '''space''' at the | ||
+ | ''beginning'' of the line | ||
+ | </pre> | ||
+ | This way of preformatting only applies to section formatting, and character formatting markups are still effective. | ||
+ | | | ||
+ | preformatted text is done with | ||
+ | a '''space''' at the | ||
+ | ''beginning'' of the line | ||
+ | |} | ||
+ | |||
==Organizing== | ==Organizing== | ||
===Headers & Lines=== | ===Headers & Lines=== | ||
− | { | + | {| class="wikitable" width="80%" |
+ | ! Description !! You type !! You get | ||
+ | |- | ||
+ | ! colspan="3" style="background:#ABE" | section formatting – ''only at the beginning of the line (with no leading spaces)'' | ||
+ | |- | ||
+ | |Headings of different levels | ||
+ | | <pre>=level 1= | ||
+ | ==level 2== | ||
+ | ===level 3=== | ||
+ | ====level 4==== | ||
+ | =====level 5===== | ||
+ | ======level 6======</pre> | ||
+ | Level 1 is normally set aside for the article title. An article with 4 or more headings automatically creates a [[wikipedia:Wikipedia:Section#Table of contents (TOC)|table of contents]]. | ||
+ | |||
+ | |<!-- hack to prevent TOC viewing for h1 - h6 elements: their style is hardcopied here --> | ||
+ | <div style="font-size: 188%; margin: 0; padding-top: .5em; padding-bottom: .17em; border-bottom: 1px solid #aaa">Level 1</div> | ||
+ | <div style="font-size: 150%; margin: 0; padding-top: .5em; padding-bottom: .17em; border-bottom: 1px solid #aaa">Level 2</div> | ||
+ | <div style="font-size: 132%; font-weight: bold">Level 3</div><!-- | ||
+ | --><b>Level 4</b><!-- | ||
+ | --><div style="font-size: 86%; font-weight: bold">Level 5</div><!-- | ||
+ | --><b style="font-size: 80%">Level 6</b> | ||
+ | |- | ||
+ | |Horizontal rule | ||
+ | | <code>----</code> | ||
+ | | | ||
+ | ---- | ||
+ | |} | ||
===Lists=== | ===Lists=== | ||
− | { | + | {| class="wikitable" width="80%" |
+ | ! Description !! You type !! You get | ||
+ | |- | ||
+ | ! colspan="3" style="background:#ABE" | section formatting – ''only at the beginning of the line (with no leading spaces)'' | ||
+ | |- | ||
+ | |Bullet list | ||
+ | | | ||
+ | <pre> | ||
+ | * one | ||
+ | * two | ||
+ | * three | ||
+ | ** three point one | ||
+ | ** three point two | ||
+ | </pre> | ||
+ | Inserting a blank line will end the first list and start another. | ||
+ | | | ||
+ | * one | ||
+ | * two | ||
+ | * three | ||
+ | ** three point one | ||
+ | ** three point two | ||
+ | |- | ||
+ | |Numbered list | ||
+ | | | ||
+ | <pre> | ||
+ | # one | ||
+ | # two<br />spanning more lines<br />doesn't break numbering | ||
+ | # three | ||
+ | ## three point one | ||
+ | ## three point two | ||
+ | </pre> | ||
+ | | | ||
+ | # one | ||
+ | # two<br />spanning more lines<br />doesn't break numbering | ||
+ | # three | ||
+ | ## three point one | ||
+ | ## three point two | ||
+ | |- | ||
+ | |Definition list | ||
+ | |<pre> | ||
+ | ;item 1 | ||
+ | : definition 1 | ||
+ | ;item 2 | ||
+ | : definition 2-1 | ||
+ | : definition 2-2 | ||
+ | </pre> | ||
+ | | | ||
+ | ;item 1 | ||
+ | : definition 1 | ||
+ | ;item 2 | ||
+ | : definition 2-1 | ||
+ | : definition 2-2 | ||
+ | |- | ||
+ | | Adopting definition list to indent text | ||
+ | | | ||
+ | <pre>: Single indent | ||
+ | :: Double indent | ||
+ | ::::: Multiple indent</pre> | ||
+ | This workaround may be controversial from the viewpoint of accessibility. | ||
+ | | | ||
+ | : Single indent | ||
+ | :: Double indent | ||
+ | ::::: Multiple indent | ||
+ | |- | ||
+ | | Mixture of different types of list | ||
+ | | | ||
+ | <pre> | ||
+ | # one | ||
+ | # two | ||
+ | #* two point one | ||
+ | #* two point two | ||
+ | # three | ||
+ | #; three item one | ||
+ | #: three def one | ||
+ | # four | ||
+ | #: four def one | ||
+ | #: this rather looks like the continuation of # four | ||
+ | #: and thus often used instead of <br /> | ||
+ | # five | ||
+ | ## five sub 1 | ||
+ | ### five sub 1 sub 1 | ||
+ | ## five sub 2 | ||
+ | |||
+ | ;item 1 | ||
+ | :* definition 1-1 | ||
+ | :* definition 1-2 | ||
+ | : | ||
+ | ;item 2 | ||
+ | :# definition 2-1 | ||
+ | :# definition 2-2 | ||
+ | </pre> | ||
+ | The usage of <code>#:</code> and <code>*:</code> for breaking a line within an item may also be controversial. | ||
+ | | | ||
+ | # one | ||
+ | # two | ||
+ | #* two point one | ||
+ | #* two point two | ||
+ | # three | ||
+ | #; three item one | ||
+ | #: three def one | ||
+ | # four | ||
+ | #: four def one | ||
+ | #: this rather looks like the continuation of <code># four</code> | ||
+ | #: often used instead of <code><br /></code> | ||
+ | # five | ||
+ | ## five sub 1 | ||
+ | ### five sub 1 sub 1 | ||
+ | ## five sub 2 | ||
+ | ;item 1 | ||
+ | :* definition 1-1 | ||
+ | :* definition 1-2 | ||
+ | : | ||
+ | ;item 2 | ||
+ | :# definition 2-1 | ||
+ | :# definition 2-2 | ||
+ | |} | ||
+ | |||
+ | For even more on list, check out [http://en.wikipedia.org/wiki/Help:List Wikipedia's List Help article]. | ||
+ | |||
===Signatures=== | ===Signatures=== | ||
− | { | + | You should always sign your comments, though signatures can be inserted anywhere on a wiki page. |
+ | {| class="wikitable" width="80%" | ||
+ | ! Description !! You type !! You get | ||
+ | |- | ||
+ | ! colspan="3" style="background:#ABE" | character (inline) formatting – ''applies anywhere'' | ||
+ | |- | ||
+ | | Signature || <nowiki>Three tildes for just a signature, ~~~</nowiki> || Three tildes for just a signature, [[User:CynthiaNg|Cynthia (UBC LSIT)]] | ||
+ | |- | ||
+ | | Signature with Date and Time || <nowiki>Four tildes for your signature with date and time, ~~~~</nowiki> || Four tildes for your signature with date and time, [[User:CynthiaNg|Cynthia (UBC LSIT)]] 22:27, 26 May 2010 (UTC) | ||
+ | |- | ||
+ | | Only Date and Time || <nowiki>Five tildes for date and time only, ~~~~~</nowiki> || Five tildes for date and time only, 22:27, 26 May 2010 (UTC) | ||
+ | |} | ||
+ | *Note: Once you save, the signature and date/time are automatically created. The next time someone edits, it no longer show the tildes. | ||
+ | |||
==Links== | ==Links== | ||
Line 24: | Line 217: | ||
== Paragraphs == | == Paragraphs == | ||
− | + | MediaWiki ignores single line breaks. To start a new paragraph, leave an empty line. You can force a line break within a paragraph with the HTML tags <code><br /></code>. | |
== HTML Formatting == | == HTML Formatting == | ||
− | { | + | Some [[wikipedia:HTML|HTML]] tags are allowed in MediaWiki, for example <code><code></code>, <code><div></code>, <code><nowiki><span></nowiki></code> and <code><nowiki><font></nowiki></code>. These apply anywhere you insert them. |
+ | |||
+ | {| class="wikitable" width="80%" | ||
+ | !Description | ||
+ | !You type | ||
+ | !You get | ||
+ | |- | ||
+ | | Underscore | ||
+ | | <code><nowiki><u>underscore</u></nowiki></code> | ||
+ | |<u>underscore</u> | ||
+ | |- | ||
+ | | Strikethrough | ||
+ | | <code><del>Strikethrough</del></code> or <code><s>Strikethrough</s></code> | ||
+ | |<del>Strikethrough</del> | ||
+ | |- style="white-space:nowrap" | ||
+ | |Fixed width text | ||
+ | | <code><tt>Fixed width text</tt></code> or <code><code>source code</code></code> | ||
+ | | <tt>Fixed width text</tt> or <code>source code</code> | ||
+ | |- | ||
+ | |Blockquotes | ||
+ | | <code> | ||
+ | text text text text text text text text text text text text | ||
+ | text text text text text text text text text text text text | ||
+ | <blockquote> quote quote quote quote quote quote </blockquote> | ||
+ | text text text text text text text text text text text text | ||
+ | </code> | ||
+ | | text text text text text text text text text text text text text text text text text text text text text text text text <blockquote> quote quote quote quote quote quote </blockquote> text text text text text text text text text text text text | ||
+ | |- | ||
+ | | Typewriter font | ||
+ | | <pre>Puts text in a <tt>typewriter | ||
+ | font</tt>. The same font is | ||
+ | generally used for <code> | ||
+ | computer code</code>.</pre> | ||
+ | | Puts the text in a <tt>typewriter | ||
+ | font</tt>. The same font is | ||
+ | generally used for <code> | ||
+ | computer code</code>. | ||
+ | |- | ||
+ | | Superscripts and Subscripts | ||
+ | | <pre>X<sup>2</sup>, H<sub>2</sub>O</pre> | ||
+ | |X<sup>2</sup>, H<sub>2</sub>O | ||
+ | |- | ||
+ | | Centered text | ||
+ | | <pre><center>Centered text</center> | ||
+ | * Please note the American spelling of "center".</pre> | ||
+ | | <center>Centered text</center> | ||
+ | |- | ||
+ | | Comment | ||
+ | | <code><!-- This is a comment --></code> | ||
+ | Text can only be viewed in the edit window. | ||
+ | | | ||
+ | <!-- This is a real invisible comment --> | ||
+ | |- | ||
+ | | Completely preformatted text | ||
+ | | | ||
+ | <code><nowiki><pre>this way, all markups are '''ignored'''</pre></nowiki></code> | ||
+ | | | ||
+ | <pre> this way, all markups are '''ignored'''.</pre> | ||
+ | |- | ||
+ | |'''Customized''' preformatted text | ||
+ | | | ||
+ | <code><nowiki><pre style="CSS text">this way, all markups are '''ignored''' | ||
+ | and formatted with a CSS text</pre></nowiki></code> | ||
+ | | | ||
+ | <pre style="CSS text">this way, all markups are '''ignored''' | ||
+ | and formatted with a CSS text</pre> | ||
+ | |} | ||
== Mathematical formulas == | == Mathematical formulas == | ||
− | {{ | + | MediaWiki allows you to use LaTeX to insert mathematical formulae by typing in <nowiki><math>Formula here</math></nowiki>. Included here are a couple of examples and commonly used functions and expressions. |
+ | {| class="wikitable" width="80%" | ||
+ | ! !! What you type !! What it looks like | ||
+ | |- | ||
+ | | Superscript || <nowiki><math> a^2 </math></nowiki> || <math>a^2</math> | ||
+ | |- | ||
+ | | Subscript || <nowiki><math> a_3 </math></nowiki> || <math>a_3</math> | ||
+ | |- | ||
+ | | Grouping || <nowiki><math> a_{x,y} </math></nowiki> || <math>a_{x,y}</math> | ||
+ | |- | ||
+ | | Combination || <nowiki><math> a_3^2 or {a_3}^2 </math></nowiki> || <math>a_3^2</math> or <math>{a_3}^2</math> | ||
+ | |- | ||
+ | | Root || <nowiki><math> ([n] is optional) \sqrt[n]{x} </math></nowiki> || <math>\sqrt[n]{x}</math> | ||
+ | |- | ||
+ | | Fraction || <nowiki><math> \frac{3}{4}=0.75 or (small) \tfrac{1}{3}=0.\bar{3} </math></nowiki> || <math>\frac{3}{4}=0.75</math> or (small) <math>\tfrac{1}{3}=0.\bar{3}</math> | ||
+ | |- | ||
+ | | More Complex Example | ||
+ | |<nowiki><math> \sum_{n=0}^\infty \frac{x^n}{n!} </math></nowiki> | ||
+ | | <math>\sum_{n=0}^\infty \frac{x^n}{n!}</math> | ||
+ | |} | ||
+ | |||
+ | See [http://meta.wikimedia.org/wiki/Help:Displaying_a_formula WikiMedia's Help on Displaying a Formula] for a full article on using TeX to display formulae. Beginning at Section 3 (Functions, symbols, special characters) is a comprehensive list of all the symbols. | ||
+ | |||
==Footnotes== | ==Footnotes== | ||
− | { | + | You can add footnotes to sentences using |
+ | the ''ref'' tag -- this is especially good | ||
+ | for citing a source. | ||
+ | |||
+ | {| class="wikitable" width="80%" | ||
+ | !width="1000"|What it looks like | ||
+ | !width="500"|What you type | ||
+ | |- | ||
+ | |There are over six billion people in the world.<ref>CIA World Factbook, 2006.</ref> | ||
+ | References: <references/> | ||
+ | |||
+ | |<nowiki>There are over six billion people in the | ||
+ | world.<ref>CIA World Factbook, 2006.</ref> | ||
+ | |||
+ | References: <references/></nowiki> | ||
+ | |} | ||
+ | |||
<noinclude> | <noinclude> | ||
==See Also== | ==See Also== | ||
− | *[[Help:Editing|Editing the | + | *[[Help:Editing|Editing the Kumu Wiki]] |
*[[Help:Formatting_Toolbar | Using the formatting toolbar]] | *[[Help:Formatting_Toolbar | Using the formatting toolbar]] | ||
*[[Help:Links|Adding Links]] | *[[Help:Links|Adding Links]] | ||
− | *[[Help:Adding_Media|Adding Media to the | + | *[[Help:Adding_Media|Adding Media to the Kumu Wiki]] |
*[[Help:Tables|Table Formatting]] | *[[Help:Tables|Table Formatting]] | ||
*[[Help:Footnotes and References|Adding Footnotes and References]] | *[[Help:Footnotes and References|Adding Footnotes and References]] | ||
[[Category:Help]] | [[Category:Help]] | ||
</noinclude> | </noinclude> |
Latest revision as of 08:27, 16 September 2014
You can format your text using the formatting toolbar or wiki markup. Wiki markup can be thought of as a simplified version of html and it consists of normal characters like asterisks, single quotes or equation marks which have a special function in the wiki. For example, to format a word in italic, you include it in two single quotes like ''this''
.
Text Formatting
Description | You type | You get |
---|---|---|
character (inline) formatting – applies anywhere | ||
Italic text | ''italic''
|
italic |
Bold text | '''bold'''
|
bold |
Bold and italic | '''''bold & italic'''''
|
bold & italic |
Ignore wiki markup | <nowiki>no ''markup''</nowiki>
|
no ''markup'' |
section formatting – only at the beginning of the line | ||
Preformatted text |
preformatted text is done with a '''space''' at the ''beginning'' of the line This way of preformatting only applies to section formatting, and character formatting markups are still effective. |
preformatted text is done with a space at the beginning of the line |
Organizing
Headers & Lines
Description | You type | You get |
---|---|---|
section formatting – only at the beginning of the line (with no leading spaces) | ||
Headings of different levels | =level 1= ==level 2== ===level 3=== ====level 4==== =====level 5===== ======level 6====== Level 1 is normally set aside for the article title. An article with 4 or more headings automatically creates a table of contents. |
Level 1
Level 2
Level 3 Level 4Level 5 Level 6
|
Horizontal rule | ----
|
|
Lists
Description | You type | You get |
---|---|---|
section formatting – only at the beginning of the line (with no leading spaces) | ||
Bullet list |
* one * two * three ** three point one ** three point two Inserting a blank line will end the first list and start another. |
|
Numbered list |
# one # two<br />spanning more lines<br />doesn't break numbering # three ## three point one ## three point two |
|
Definition list | ;item 1 : definition 1 ;item 2 : definition 2-1 : definition 2-2 |
|
Adopting definition list to indent text |
: Single indent :: Double indent ::::: Multiple indent This workaround may be controversial from the viewpoint of accessibility. |
|
Mixture of different types of list |
# one # two #* two point one #* two point two # three #; three item one #: three def one # four #: four def one #: this rather looks like the continuation of # four #: and thus often used instead of <br /> # five ## five sub 1 ### five sub 1 sub 1 ## five sub 2 ;item 1 :* definition 1-1 :* definition 1-2 : ;item 2 :# definition 2-1 :# definition 2-2 The usage of |
|
For even more on list, check out Wikipedia's List Help article.
Signatures
You should always sign your comments, though signatures can be inserted anywhere on a wiki page.
Description | You type | You get |
---|---|---|
character (inline) formatting – applies anywhere | ||
Signature | Three tildes for just a signature, ~~~ | Three tildes for just a signature, Cynthia (UBC LSIT) |
Signature with Date and Time | Four tildes for your signature with date and time, ~~~~ | Four tildes for your signature with date and time, Cynthia (UBC LSIT) 22:27, 26 May 2010 (UTC) |
Only Date and Time | Five tildes for date and time only, ~~~~~ | Five tildes for date and time only, 22:27, 26 May 2010 (UTC) |
- Note: Once you save, the signature and date/time are automatically created. The next time someone edits, it no longer show the tildes.
Links
- Please see Help:Links for detailed information on creating hyperlinks
Paragraphs
MediaWiki ignores single line breaks. To start a new paragraph, leave an empty line. You can force a line break within a paragraph with the HTML tags <br />
.
HTML Formatting
Some HTML tags are allowed in MediaWiki, for example <code>
, <div>
, <span>
and <font>
. These apply anywhere you insert them.
Description | You type | You get |
---|---|---|
Underscore | <u>underscore</u>
|
underscore |
Strikethrough | <del>Strikethrough</del> or <s>Strikethrough</s>
|
|
Fixed width text | <tt>Fixed width text</tt> or <code>source code</code>
|
Fixed width text or source code
|
Blockquotes |
|
text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text |
Typewriter font | Puts text in a <tt>typewriter font</tt>. The same font is generally used for <code> computer code</code>. |
Puts the text in a typewriter
font. The same font is
generally used for |
Superscripts and Subscripts | X<sup>2</sup>, H<sub>2</sub>O |
X2, H2O |
Centered text | <center>Centered text</center> * Please note the American spelling of "center". |
|
Comment | <!-- This is a comment -->
Text can only be viewed in the edit window. |
|
Completely preformatted text |
|
this way, all markups are '''ignored'''. |
Customized preformatted text |
|
this way, all markups are '''ignored''' and formatted with a CSS text |
Mathematical formulas
MediaWiki allows you to use LaTeX to insert mathematical formulae by typing in <math>Formula here</math>. Included here are a couple of examples and commonly used functions and expressions.
What you type | What it looks like | |
---|---|---|
Superscript | <math> a^2 </math> | |
Subscript | <math> a_3 </math> | |
Grouping | <math> a_{x,y} </math> | |
Combination | <math> a_3^2 or {a_3}^2 </math> | or |
Root | <math> ([n] is optional) \sqrt[n]{x} </math> | |
Fraction | <math> \frac{3}{4}=0.75 or (small) \tfrac{1}{3}=0.\bar{3} </math> | or (small) |
More Complex Example | <math> \sum_{n=0}^\infty \frac{x^n}{n!} </math> |
See WikiMedia's Help on Displaying a Formula for a full article on using TeX to display formulae. Beginning at Section 3 (Functions, symbols, special characters) is a comprehensive list of all the symbols.
Footnotes
You can add footnotes to sentences using the ref tag -- this is especially good for citing a source.
What it looks like | What you type |
---|---|
There are over six billion people in the world.[1]
References:
|
There are over six billion people in the world.<ref>CIA World Factbook, 2006.</ref> References: <references/> |