%META:TOPICINFO{author="ProjectContributor" date="1765530849" format="1.1" version="1"}%
---+ Editing Shorthand
%STARTINCLUDE%
%TABLE{}%
<table class="foswikiTable" border="1" cellpadding="3">
<tr>
<th width="50%" class="foswikiFirstCol">
 Formatting Command:
</th>
<th width="25%">
 You write:
</th>
<th width="25%">
 You get:
</th>
</tr>
<tr valign="top">
<td>
 *Paragraphs:* %BR%
 Blank lines will create new paragraphs.
</td><td>
<verbatim>
1st paragraph

2nd paragraph
</verbatim>
</td><td>

1st paragraph

2nd paragraph
</td>
</tr>
<tr valign="top">
<td>
 *Headings:* %BR%
Three or more dashes at the beginning of a line, followed by plus signs and the heading text. One plus creates a top level heading, two pluses a second level heading, etc. The maximum heading depth is 6.

You can create a table of contents with the [[VarTOC][%<nop>TOC%]] macro. If you want to *exclude* a heading from the TOC, put =!!= after the =---+=.

%X% Empty headings are allowed, but won't appear in the table of contents.

See the =&lt;ho&gt;= tag below for how to adjust heading levels dynamically.

</td><td>
<verbatim class="tml">
---++ Sushi
---+++ Maguro
---+++!! Not in TOC
</verbatim>
</td><td>

<nop><h2>Sushi</h2>
<nop><h3>Maguro</h3>
<nop><h3>Not in TOC</h3>
</td>
</tr>
<tr valign="top">
<td>
 *Bold Text:* %BR%
 Words get shown in *bold* by enclosing them in =*= asterisks.
</td><td>
<verbatim class="tml">
*Bold*
</verbatim>
</td><td>

*Bold*
</td>
</tr>
<tr valign="top">
<td>
 *Italic Text:* %BR%
 Words get shown in _italic_ by enclosing them in =_= underscores.
</td><td>
<verbatim class="tml">
_Italic_
</verbatim>
</td><td>

_Italic_
</td>
</tr>
<tr valign="top">
<td>
 *Bold Italic:* %BR%
 Words get shown in __bold italic__ by enclosing them in =__= double-underscores.
</td><td>
<verbatim class="tml">
__Bold italic__
</verbatim>
</td><td>

__Bold italic__
</td>
</tr>
<tr valign="top">
<td>
 *Fixed Font:* %BR%
 Words get shown in =fixed font= by enclosing them in =<nop>=<nop>= equal signs.
</td><td>
<verbatim class="tml">
=Fixed font=
</verbatim>
</td><td>

=Fixed font=

</td>
</tr>
<tr valign="top">
<td>
 *Bold Fixed Font:* %BR%
 Words get shown in ==bold fixed font== by enclosing them in <sticky><code><b>==</b></code></sticky> double equal signs.
</td><td>
<verbatim class="tml">
==Bold fixed==
</verbatim>
</td><td>

==Bold fixed==
</td>
</tr>
<tr valign="top">
<td>
%T% You can follow the closing bold, italic, or other (=* _ __ = ===) indicator
with normal punctuation, such as commas and full stops.

%X% Make sure there is no space between the text and the indicators.
</td><td>
<verbatim class="tml">
_This works_,
_this does not _
</verbatim>
</td><td>

_This works_,%BR%
_this does not _
</td>
</tr>
<tr valign="top">
<td>
 *Separator (Horizontal Rule):* %BR%
Three or more three dashes at the beginning of a line..
</td><td>
<verbatim class="tml">
---
</verbatim>
</td><td>

-------
</td>
</tr>
<tr valign="top">
<td>
 *Bulleted List:* %BR%
Multiple of three spaces, an asterisk, and another space.%BR% %BR%
%H% For all the list types, you can break a list item over several lines by indenting lines after the first one by *at least 3 spaces*.
</td><td>
<verbatim class="tml">
   * level 1
      * level 2
   * back on 1
   * A bullet
     broken over
     three lines
   * last bullet
</verbatim>
</td><td>

   * level 1
      * level 2
   * back on 1
   * A bullet
     broken over
     three lines
   * last bullet
</td>
</tr>
<tr valign="top">
<td>
*Numbered List:* %BR%
Multiple of three spaces, a type character, a dot, and another space. Several types are available besides a number:
| *Type* | *Generated Style* | *Sample Sequence* |
| 1. | Arabic numerals | 1, 2, 3, 4... |
| A. | Uppercase letters | A, B, C, D... |
| a. | Lowercase letters | a, b, c, d... |
| I. | Uppercase Roman Numerals | I, II, III, IV... |
| i. | Lowercase Roman Numerals | i, ii, iii, iv... |
%X% Note that while type characters =A=, =a=, =I= and =i= must be entered exactly as specified, numbers can be any single digit 0-9. It is recommended for future compatibility that only the number 1 be used for numbered type lists.
</td><td>
<verbatim class="tml">
   1 Sushi
   1 Dim Sum
   1 Fondue

   A. Sushi
   A. Dim Sum
   A. Fondue

   i. Sushi
   i. Dim Sum
   i. Fondue
</verbatim>
</td><td>

   1 Sushi
   1 Dim Sum
   1 Fondue

   A. Sushi
   A. Dim Sum
   A. Fondue

   i. Sushi
   i. Dim Sum
   i. Fondue
</td>
</tr>
<tr valign="top">
<td>
 *Definition List:* %BR%
 Three spaces, a dollar sign, the term, a colon, a space, followed by the definition.
</td><td>
<verbatim class="tml">
   $ Sushi: Japan
   $ Dim Sum: S.F.
</verbatim>
</td><td>

   $ Sushi: Japan
   $ Dim Sum: S.F.
</td>
</tr>
<tr valign="top">
<td>
 *Definition List:* (deprecated) %BR%
 Three spaces, the term (a single word, no spaces), a colon, a space, followed by the definition.
</td><td>
<verbatim class="tml">
   Sushi: Japan
   Dim-Sum: S.F.
</verbatim>
</td><td>

   Sushi: Japan
   Dim-Sum: S.F.
</td>
</tr>
<tr valign="top">
<td>
 *Indented Text:* %BR%
Three spaces, a colon, a space, followed by the paragraph. 
   * Continue a paragraph by indenting the line with 3 spaces.
   * Create deeper levels of indentation by using multiples of 3 spaces.
</td><td>
<verbatim class="tml">
   : Indented line
   Continued
   : New paragraph
      : 2nd level indent
</verbatim>
</td><td>

   : Indented line
   Continued
   : New paragraph
      : 2nd level indent
</td>
</tr>
<tr valign="top">
<td>
 *Table:* %BR%
Each row of the table is a line containing of one or more cells. Each cell starts and ends with a vertical bar '|'. Any spaces at the beginning of a line are ignored.
   : =| <nop>*bold*<nop> |= header cell with text in asterisks
   : =|   center-aligned   |= cell with at least two, and equal number of spaces on either side
   : =|      right-aligned |= cell with more spaces on the left
   : =| 2 colspan ||= and multi-span columns with multiple <tt>|</tt>'s right next to each other
   : =|^|= cell with caret indicating follow-up row of multi-span rows
   * You can split rows over multiple lines by putting a backslash ='\'= at the end of each line
   * Contents of table cells wrap automatically as determined by the browser
   * Use =%<nop>VBAR%= or =&amp;#124;= to add =&#124;= characters in tables.
   * Use =%<nop>CARET%= or =&amp;#94;= to add =&#94;= characters in tables.
%T% The %SYSTEMWEB%.TablePlugin provides the =|^|= multiple-span row functionality and additional rendering features
</td><td>
<verbatim class="tml">
| *L* | *C* | *R* |
| A2 |  B2  |  C2 |
  | A3 |  B3  |  C3 |
| multi span |||
| A5-7 |  5  |  5 |
|^| six | six |
|^| seven | seven |
| split\
  | over\
  | 3 lines |
| A9 |  B9  |  C9 |
| %CARET% | B10 |%VBAR%|
| &#94; | B11 |&#124;|
</verbatim>
</td><td>

| *L* | *C* | *R* |
| A2 |  B2  |  C2 |
  | A3 |  B3  |  C3 |
| multi span |||
| A5-7 |  5  |  5 |
|^| six | six |
|^| seven | seven |
| split\
  | over\
  | 3 lines |
| A9 |  B9  |  C9 |
| %CARET% | B10 |%VBAR%|
| &#94; | B11 |&#124;|
</td>
</tr>
<tr valign="top">
<td>
 *<nop>WikiWord Links:* %BR%
 <nop>CapitalizedWordsStuckTogether (or WikiWords) will produce a link automatically if preceded by whitespace or parenthesis.
   * %T% If you want to link to a topic in a different web write =Otherweb.TopicName=.
   * To link to a topic in a subweb write =Otherweb.Subweb.TopicName=.
   * %H% The link label excludes the name of the web, e.g. only the topic name is shown. As an exception, the name of the web is shown for the <nop>%HOMETOPIC% topic.
%X% Dots ='.'= are used to separate webs and subwebs from topic names and therefore cannot be used in topic names.

It's generally a good idea to use the [[%SYSTEMWEB%.Macros][macros]] %<nop>SYSTEMWEB%, %<nop>SANDBOXWEB%, %<nop>HOMEWEB% and %<nop>USERSWEB% instead of %SYSTEMWEB%, %SANDBOXWEB%, %HOMEWEB% and %USERSWEB%.

To prevent a word from linking, prefix it with the exclaimation mark (!) or &lt;nop&gt;
</td><td>
<verbatim class="tml">
%STATISTICSTOPIC%

%SANDBOXWEB%.WebNotify

%SANDBOXWEB%.%HOMETOPIC%

%SANDBOXWEB%.Subweb.TopicName
</verbatim>
</td><td>

%STATISTICSTOPIC%

%SANDBOXWEB%.WebNotify

%SANDBOXWEB%.%HOMETOPIC%

<a href="#MyAnchor" title="simulated link">TopicName</a>
</td>
</tr>
<tr valign="top">
<td>
 *<nop>Acronym  Links:* %BR%
 <nop>Words that are all capitals will produce a link automatically _only_ if the topic already exists!. 
</td><td>
<verbatim class="tml">
ACRONYM

%SYSTEMWEB%.ACRONYM
</verbatim>
</td><td>

ACRONYM

%SYSTEMWEB%.ACRONYM
</td>
</tr>
<tr valign="top">
<td>
 *Anchors:* %BR%
 You can define a reference inside a topic (called an anchor name) and link to that. To *define* an anchor write =#AnchorName= at the beginning of a line. The anchor name must be a WikiWord of no more than 32 characters. To *link to* an anchor name use the =[<nop>[MyTopic#MyAnchor]]= syntax. You can omit the topic name if you want to link within the same topic.
</td><td>
<verbatim class="tml">
[[WikiWord#NotThere]]

[[#MyAnchor][Jump]]

#MyAnchor To here
</verbatim>
</td><td>

[[WikiWord#NotThere]]

[[#MyAnchor][Jump]]

#MyAnchor To here
</td>
</tr>
<tr valign="top">
<td>
#HeRe
#SquareBrackets
 *Forced Links:* %BR%
 You can create a forced internal link by enclosing words in double square brackets.
%BR% 
Text within the brackets may contain optional spaces; the topic name is formed by capitalizing the initial letter and by removing the spaces; for example, =[<nop>[wiki word]]= links to topic WikiWord.  You can also refer to a different web and use anchors.
%BR%
%T% To "escape" double square brackets that would otherwise make a link, prefix the leading left square bracket with an exclamation point.
</td><td>
<pre class="tml">
[[wiki syntax]]

[[%USERSWEB%.Wiki groups]]

escaped:
![[wiki syntax]]
</pre>
</td><td>

[[wiki syntax]]

[[%USERSWEB%.Wiki groups]]

escaped:
![[wiki syntax]]
</td>
</tr>
<tr valign="top">
<td>
 *Renamed Links:* %BR%
 You can create a link where you specify the link text and the URL separately using nested square brackets =[<nop>[reference][text]]=. Internal link references (e.g. WikiWord) and URLs (e.g. https://foswiki.org/) are both supported.
The rules described under *Forced Links* apply for internal link references.
 %BR% %T% Anchor names can be added as well, to create a link to a specific place in a topic.
</td><td>
<verbatim class="tml">
[[WikiWord][wiki word]]

[[http://gnu.org][GNU]]
</verbatim>
</td><td>

[[WikiWord][wiki word]]

[[http://gnu.org][GNU]]
</td>
</tr>
<tr valign="top">
<td>
*Automatic links:* %BR%
Typed-in URLs are linked automatically. Most standard protocols are supported; if yours is missing, it can be added by the site administrator.

URLs for images are automatically inserted inline.

Email addresses are also linked automatically,  see further details below.

%T% automatic linking of URLs and email addresses is _not_ blocked by the =noautolink= setting.
</td>
<td>
<verbatim>
   * file://foswiki.org
   * ftp://foswiki.org
   * http://foswiki.org
   * https://foswiki.org
   * mailto:example@foswiki.org
   * news://foswiki.org
   * nntp://foswiki.org
   * telnet://foswiki.org
   * name@foswiki.org
   * %PUBURL%/%SYSTEMWEB%/ProjectLogos/foswiki-logo-icon.png
</verbatim>
</td>
<td>
   * file://foswiki.org
   * ftp://foswiki.org
   * http://foswiki.org
   * https://foswiki.org
   * mailto:example@foswiki.org
   * news://foswiki.org
   * nntp://foswiki.org
   * telnet://foswiki.org
   * name@foswiki.org
   * %PUBURL%/%SYSTEMWEB%/ProjectLogos/foswiki-logo-icon.png
</td>
</tr>
<tr valign="top">
<td>
 *Prevent an Automatic Link:* %BR%
 Prevent a WikiWord, URL, email address or image from being linked by prepending it with an exclamation point (!) or =&lt;nop&gt;= tag.

%T% Note that you can use the &lt;nop&gt; tag, but _any_ leading markup directly adjacent to a wikiword will prevent automatic linking because the word is no longer space delimitied.
</td><td>
<verbatim class="tml">
!SunOS

<nop>SomeWiki

<b>SomeWiki</b>

=SomeWiki=

<b>https://foswiki.org</b>

_%PUBURL%/%SYSTEMWEB%/ProjectLogos/foswiki-logo-icon.png_
</verbatim>
</td><td>

!SunOS

<nop>SomeWiki

<b>SomeWiki</b>

=SomeWiki=

<b>https://foswiki.org</b>

_%PUBURL%/%SYSTEMWEB%/ProjectLogos/foswiki-logo-icon.png_
</td>
</tr>
<tr valign="top">
<td>
 *Disable Automatic Linking:* %BR%
 You can disable automatic linking of WikiWords by surrounding text with =&lt;noautolink&gt;= and =&lt;/noautolink&gt;= tags.%BR%
%H% You can also turn off WikiWord auto-linking with the NOAUTOLINK [[%SYSTEMWEB%.PreferenceSettings][preference setting]].

The =noautolink= feature _only_ applies to !WikiWords.  It does not stop linking of URLs, or email addresses.
</td><td>
<verbatim class="tml">
 <noautolink>
 RedHat & SuSE
 </noautolink>
</verbatim>
</td><td>

 <noautolink>
 RedHat & SuSE
 </noautolink>
</td>
</tr>
<tr valign="top">
<td>
*Mailto Links:* %BR%
E-mail addresses are linked automatically. To create e-mail links that have more descriptive link text, specify subject lines or message bodies, or omit the e-mail address, you can write =[<nop>[mailto:user@domain][descriptive text]]=.

%X% automatic linking of email addresses is _not_ blocked by =&lt;noautolink&gt;=, Escape with a ! to prevent auto linking.
</td><td>
<verbatim class="tml">
a@b.com

[[mailto:a@b.com][Mail]]

[[mailto:?subject=Hi][Hi]]

!a@b.com
</verbatim>
</td><td>

a@b.com

[[mailto:a@b.com]\
[Mail]]

[[mailto:?subject=Hi][Hi]]

!a@b.com
</td>
</tr>
<tr valign="top">
<td>
*Special characters:* %BR%
Some characters are reserved for use by TML
   * Display them in your output by using the HTML entities. 
   * Use HTML entities to display characters that are not supported by your site character set (e.g. special mathematical symbols). There's a complete list of named entities in [[http://en.wikipedia.org/wiki/List_of_XML_and_HTML_character_entity_references][Wikipedia]]
   * Use numerical entities to display any unicode character (e.g. Chinese script).
</td>
<td>
<verbatim>
&lt; &gt; &amp; &alefsym; &#x4eb9;

A <nop>!= B &#33;= C

<nop>!here, !here
</verbatim>
</td>
<td>
&lt; &gt; &amp; &alefsym; &#x4eb9;

A <nop>!= B &#33;= C

<nop>!here, !here
</td>
</tr>
<tr valign="top">
<td>
*Escapes* %BR%
Escapes are used to prevent a "default action" from occuring.  They are used in many places when composing topics and writing Foswiki macros.
   $ ==!==: The exclamation point will block expansion of macros, prevents automatic linking of WikiWords, email addresses, URLs, and ![[explicit links]].
      * To expand a macro, but escape any wikiword it expands into, use the &lt;nop&gt; tag.
      * To prevent Foswiki from treating ! as an escape,  escape it with =&lt;nop&gt;=, or use the =&amp;#33;= entity
   $ ==\==: The backslash is used to prevent normal interpretation of a character, allowing inclusion of quotes inside a quoted string.  It can also be used to \
continue a line (escapes the "newline"). When used as a "continue" it must be the very last character prior to the newline.
   $ ==&lt;nop&gt;==: The =nop= (no operation) is used to prevent linking of !WikiWords, email addresses, URLs,  but _not_ Macros or ![[explicit links]]
</td>
<td>
<verbatim class="tml">
!WikiWord %BR%
!%TOPIC% %BR%
<nop>%TOPIC% %BR%
<nop>%WIKIWEBMASTER% %BR%
<nop>!%TOPIC% %BR%
!here &#33;here <nop>!here %BR%
%TOP\
IC%

</verbatim>
</td>
<td>
%BR%
!WikiWord %BR%
!%TOPIC% %BR%
<nop>%TOPIC% %BR%
<nop>%WIKIWEBMASTER% %BR%
<nop>!%TOPIC% %BR%
!here &#33;here <nop>!here %BR%
%TOP\
IC%
</td>
<tr valign="top">
<td>
*Controlling how content is rendered:* %BR%
There are 3 ways to control how your topic content is rendered. This is done with three HTML or
pseudo-HTML tags: =&lt;literal&gt;, &lt;verbatim&gt;= and &lt;pre&gt;  They
control whether or not: 
   * Wiki markup (TML) is rendered
   * Macros (ex: <tt>%<nop>TOPIC%</tt>) are expanded
   * HTML is rendered
   * White space preserved
   * Auto linking of !WikiWords and Email addresses occurs
These are explained in more details in the next sections, but are summarized to the right:
</td>
<td colspan="2">
<table>
<tr><td></td><td>TML</td><td>HTML</td><td>Macros</td><td>White%BR%Space</td><td> Auto Link%BR%WikiWord</td><td>Auto Link%BR%Email</td></tr>
<tr><td> =&lt;verbatim&gt;= </td><td>%X%</td><td>%X%</td><td>%X%</td><td>%Y%</td><td>%X%</td><td>%X%</td></tr>
<tr><td> =&lt;literal&gt;= </td><td>%X%</td><td>%Y%</td><td>%Y%</td><td>%X%</td><td>%X%</td><td>%X%</td></tr>
<tr><td> =&lt;pre&gt;= </td><td>%X%</td><td>%Y%</td><td>%Y%</td><td>%Y%</td><td>%X%</td><td>%X%</td></tr>
<tr><td> =&lt;noautolink&gt;= </td><td>%Y%</td><td>%Y%</td><td>%Y%</td><td>%X%</td><td>%X%</td><td>%Y%</td></tr>
</table>
</td>
</tr>
<tr>
<td>
 *Literal content:* %BR%
 Foswiki generates HTML code from TML shorthand.
 *Experts* surround anything that must be output literally in the HTML code, without the application of
 shorthand rules, with =&lt;literal&gt;..&lt;/literal&gt;= tags.
 %BR% %X% Any HTML
 within literal tags *must* be well formed i.e. all tags must be properly closed before
 the end of the literal block.
 %BR% %I% Macros are expanded within literal blocks.
</td><td>
<pre>
&lt;literal&gt;
| Not | A | Table |
&lt;/literal&gt;
</pre>
</td>
<td>
<literal>
| Not | A | Table |
</literal>
</td>
</tr>
<tr valign="top">
<td>
 *Verbatim (Literal) Text:* %BR%
 Surround code excerpts and other formatted text with =&lt;verbatim&gt;= and =&lt;/verbatim&gt;= tags.%BR% %BR%
%T% =verbatim= tags disable HTML code. Use =&lt;pre&gt;= and =&lt;/pre&gt;= tags instead if you want the HTML code within the tags to be interpreted.%BR% %BR%
%X% Preferences settings (* Set NAME = value) are set within verbatim tags.
</td><td>
<verbatim>
<verbatim>
class CatAnimal {
  void purr() {
    <code here>
  }
}
</verbatim>
</verbatim>
</td><td>
<verbatim>
class CatAnimal {
  void purr() {
    <code here>
  }
}
</verbatim>
</td>
</tr>
<tr valign="top">
<td>
 *Verbatim (Literal) Code Highlighting:* %BR%
 Surround code excerpts and other formatted text e.g. with =&lt;verbatim class="bash"&gt;= and =&lt;/verbatim&gt;= tags.%BR% %BR%
%I% This type of code highlighting is based on Chili - the jQuery code highlighter plugin. Please find supported class attributes in %BASEWEB%.JQueryChili.%BR% %BR%
%T% =verbatim= tags disable HTML code. Use =&lt;pre class="bash"&gt;= and =&lt;/pre&gt;= tags instead if you want the HTML code within the tags to be interpreted.%BR% %BR%
%X% Preferences settings (* Set NAME = value) are set within verbatim tags.
</td><td>
<verbatim>
<verbatim class="bash">
#!/bin/bash
while [ -n "$(ls . ~/ \
~/pub* /var/www 2>/dev/null \
| fgrep foswiki )" ] ; do
 clear
 printf "\nFoswiki rules!\n"
 sleep 10
 clear
 printf "\nFoswiki still rules!\n"
 sleep 10
done; exit 0
</verbatim>
</verbatim>
</td><td>
<verbatim class="bash">
#!/bin/bash
while [ -n "$(ls . ~/ \
~/pub* /var/www 2>/dev/null \
| fgrep foswiki )" ] ; do
 clear
 printf "\nFoswiki rules!\n"
 sleep 10
 clear
 printf "\nFoswiki still rules!\n"
 sleep 10
done; exit 0

</verbatim>
</td>
</tr>
<tr>
<td>
 *Protected content:* %BR%
 *Experts* protect text from mangling by WYSIWYG editors using
 =&lt;sticky&gt;..&lt;/sticky&gt;= tags. Sticky tags don't have any effect on normal
 topic display; they are only relevant when content has to be
 protected from a WYSIWYG editor (usually because it isn't well-formed HTML, or because it
 is HTML that WYSIWYG would normally filter out or modify). Protected
 content appears as plain text in the WYSIWYG editor.
 %BR% %X% Any HTML within sticky tags *must* be well formed
 i.e. all tags must be properly closed before
 the end of the sticky block. 
 %BR% %I% Macros are expanded within sticky blocks.
</td><td>
<verbatim class="tml">
<sticky>
<div>
This div 
%RED%is%ENDCOLOR%
required
</div>
</sticky>
</verbatim>
</td>
<td>
<sticky>
<div>
This div
%RED%is%ENDCOLOR%
required
</div>
</sticky>
</td>
</tr>
<tr>
<td>
 *Adjust heading levels:* %BR%
 You can adjust heading levels for headings generated using =---+= markup and also HTML =&lt;h&gt;= tags using the =&lt;ho&gt;= tag.<br />The =%<nop>INCLUDE= and =%<nop>SEARCH= macros also have a =headingoffset= parameter to do this for you in included content.<br />Heading levels are limited to the range 1..6 *after* any offset is applied.
</td><td>
<pre>
---++ offset is 0
&lt;ho off="1"&gt;
---++ H2 becomes H3
&lt;ho off="-1"&gt;
---++ offset was 1, so offset is now 0
</pre>
</td>
<td>
---++!! offset is 0
<ho off="1">
---++!! H2 becomes H3
<ho off="-1">
---++!! offset was 1, so offset is now 0
</td>
</tr>
</table>

%STOPINCLUDE%
---
*Related Topics:* TopicMarkupLanguage, UsingHTML, WYSIWYG

%META:PREFERENCE{name="NATSKIN_SIDEBAR" title="NATSKIN_SIDEBAR" type="Local" value="off"}%
