Alpine Linux:Markup syntax: Difference between revisions
Dubiousjim (talk | contribs) (→Headings: add TOC info) |
Dubiousjim (talk | contribs) m (→Headings: markup error) |
||
Line 101: | Line 101: | ||
<pre>{{Delete|Message.}}</ | <pre>{{Delete|Message.}}</pre> | ||
will produce: | will produce: | ||
{ | <center> | ||
{|style="width: 48em; padding:2px; margin:0; margin-bottom:10px; background-color:#f1f1de; border:1px solid #cc9; -moz-border-radius-bottomright: 0.5em; -moz-border-radius-bottomleft: 1em; border-radius-bottomright: 0.5em; border-radius-bottomleft: 1em; -webkit-border-bottom-right-radius: 0.5em; -webkit-border-bottom-left-radius: 1em;" | |||
|<div style="font-size: 1.5em; font-weight:bold; text-align:center;"> [[Image:Tango-user-trash-full.png|48px|left|link=]] This material is proposed for deletion ... </div><p style="text-align: center; font-size: 87%;">Message. | |||
([[{{TALKPAGENAME}}|Discuss]]) Make sure no other pages link here and check the page's history before deleting.</p> | |||
|}</center> | |||
<pre>{{Obsolete|Alternate message.}}</ | <pre>{{Obsolete|Alternate message.}}</pre> | ||
will produce: | will produce: | ||
{ | <center> | ||
{|style="width: 48em; padding:2px; margin:0; margin-bottom:10px; background-color:#f1f1de; border:1px solid #cc9; -moz-border-radius-bottomright: 0.5em; -moz-border-radius-bottomleft: 1em; border-radius-bottomright: 0.5em; border-radius-bottomleft: 1em; -webkit-border-bottom-right-radius: 0.5em; -webkit-border-bottom-left-radius: 1em;" | |||
|<div style="font-size: 1.5em; font-weight:bold; text-align:center;"> [[Image:Out_of_date_clock_icon.svg|54px|left|link=]] This material is obsolete ... </div><p style="text-align: center; font-size: 87%;">Alternate message. | |||
([[{{TALKPAGENAME}}|Discuss]])</p> | |||
|}</center> | |||
<pre>{{Merge|Page to merge with|Additional message.}}</pre> | <pre>{{Merge|Page to merge with|Additional message.}}</pre> |
Revision as of 07:07, 24 March 2012
Inline elements
- ''italic'' or use <i> or <em> or {font-style:italic} in a style attribute
- '''bold''' or use <b> or <strong> or {font-weight:bold} in a style attribute
- <small> or use {font-size:smaller} in a style attribute
- <big> or use {font-size:larger} in a style attribute (invalid in HTML5)
- <sup> or use {vertical-align:super} in a style attribute
- <sub> or use {vertical-align:sub} in a style attribute
- <font> is deprecated; use {font-size:10pt; color:red; font-family:"Courier"} in a style attribute
- <span style="color:gray">
- <span style="color:white; background:red">
- <u> or use <ins> or {text-decoration:underline} in a style attribute (<u> is valid in HTML5 but not HTML4/strict; <ins> can also be a block element)
<s>or use<del>or {text-decoration:line-through} in a style attribute (<s> is valid in HTML5 but not HTML4/strict; <del> can also be a block element)
<code>
uses {font-family:monospace;} (<tt> is invalid in HTML5)markup and → entities are still honored
- and and
and are not processed by this wiki
- <var>
- <cite>
- {{Hint|term|explanation}}
- {{Path|/a/path/name}}
- {{Key| Ctrl}}+{{Key| C}}
Links
Here is [[Wiki pagetitle|a wiki page]]: a wiki page. Text immediately suffixing the link will be incorporated into the link text; separate with <nowiki /> to suppress.
TODO: Pkg
Here is an Alpine Issue link {{Issue|279}}: #279. The issue's description can be included as an optional second argument.
Here is [http://www.example.org/ an external link]: an external link. If no link text is supplied: [1]. Omit brackets for http://www.example.org/ (use <nowiki> to suppress).
[mailto:info@example.org?Subject=URL%20Encoded%20Subject&body=Body%20Text info].
In Talk pages, -- ~~~~ gives a signature and timestamp: -- Dubiousjim 10:00, 4 March 2012 (UTC)
Headings
An article with 4 or more headings automatically creates a table of contents. You can force a table of contents (or fine-tune its placement) by inserting __TOC__. You can suppress the table of contents by inserting __NOTOC__.
Start headings at level 2, and don't skip levels.
== Heading2 ==
will produce:
Heading2
=== Heading3 ===
will produce:
Heading3
==== Heading4 ====
will produce:
Heading4
{{Delete|Message.}}
will produce:
This material is proposed for deletion ... Message. (Discuss) Make sure no other pages link here and check the page's history before deleting. |
{{Obsolete|Alternate message.}}
will produce:
This material is obsolete ... Alternate message. (Discuss) |
{{Merge|Page to merge with|Additional message.}}
will produce:
This material is proposed for merging ... It should be merged with Page to merge with. Additional message. (Discuss) |
{{Move|New page name|Reason.}}
will produce:
This page is proposed for moving ... It should be renamed to New page name. Reason. (Discuss) |
{{Draft|Alternate message.}}
will produce:
This material is work-in-progress ... Alternate message. (Last edited by Dubiousjim on 24 {{{03}}} 2012.) |
{{Expand|Alternate message.}}
will produce:
This material needs expanding ... Alternate message. |
Block elements
This material is work-in-progress ...
|
{{Cmd|a <var>command</var> to try}} --- essentially, this is block-level (which is ignored)
Contents of /path/file
<nowiki> converts → entities and collapses whitespace (even multiple \n
s),
but ignores all '''wiki''' and <span style="color:green">HTML</span> [[markup]].
HTML's <pre> uses {white-space:pre; font-family:monospace;} To wrap to screen width, use <pre style="white-space:pre-wrap">
In wiki, one leading space displays as block element, in monospace, doesn't collapse whitespace. Converts → entities and honors wiki and HTML markup. ? Can contain any inline element except: IMG OBJECT BIG SMALL SUP SUB --- essentially, this and <pre> are block-level (which is ignored), or a <code> snippet whereas {{Cat}} is mainly intended to display a whole file. A session script, with prompts and stdout, should be formatted like this (or with <pre>) instead of using {{Cmd}}.
In wiki, <pre> displays as block element, in monospace, doesn't collapse whitespace. Otherwise like <nowiki>: it converts → entities, but ignores '''wiki''' and <span style="color:green">HTML</span> [[markup]]. One leading space plus <nowiki> is same as <pre> (in this case, subsequent lines should not be space-prefixed; block will extend to closing </nowiki>)
- : Simply indented text (on left side only).
This is <blockquote>. Collapses whitespace, and indents on both sides.
- Here is a numbered list item.
- Doubly-numbered
- Here is a bulleted list item.
- Doubly-bulleted
Blank lines, or non-bulleted/numbered lines, end the lists.
;item : Body text
or {{Define|item|Body text}} produce:
- item
- Body text
Tables
This material is work-in-progress ...
|
{| border="1" style="width:75%; height:200px" <!-- align=right makes table float --> |+ The table's caption |- ! width=100px | columnlabel 1 ! columnlabel 2 !! columnlabel 3 |- ! rowlabel1 | Cell 1 || Cell 2 || Cell 3 |- style="height:100px; background:none" <!-- or style="background:transparent" --> | align=right style="width:200px" | Cell A | style="background:red; color:white" | Cell B | colspan=2 align=center | Cell C |- valign=top <!-- have to be applied to every row, default is valign=middle; or use style="vertical-align:top;" --> | rowspan=2 Cell D | ... |}
See also:
Images
This material is work-in-progress ...
|
[[File:Alpinelinux 01.png|right|thumb|100px|Caption text]] gives:
Options can appear in any order:
- Caption text defaults to filename; to wholly suppress, use
<span title=""></span>
- alt=text
- Size can be [width][xheight]px
- page=number, for PDF images
- rendered inline, Caption shows as hover text: frameless, and/or border
- rendered inline, on separate line: none
- Valign for inline images, defaults to middle: middle|baseline|sub|super|top|text-top|bottom|text-bottom
- Text flow can be stopped by placing {{Clear}} before the text that should start below the floating image
- link=URL|pagetitle|blank, only for inline images
- rendered floating, defaults to right align, Caption displayed below image: thumb, thumb=alternate filename, frame (ignores size options)
- rendered floating, defaults to thumb: left|right|center
To instead link to the file, you need to add a colon: File:Alpinelinux 01.png.
See also:
- http://meta.wikimedia.org/wiki/Help:Images_and_other_uploaded_files
- http://meta.wikimedia.org/wiki/Help:Image_page
- http://en.wikipedia.org/wiki/Wikipedia:Extended_image_syntax
- http://www.mediawiki.org/wiki/Help:Images
- http://www.mediawiki.org/wiki/Help:Managing_files
- http://meta.wikimedia.org/wiki/Help:Navigational_image
Other
Every page should be assigned at least one Category, by placing the following at the bottom of the page:
[[Category:Category name]]
To link to a Category page, without adding the linking page to the category: [[:Category:Not in this category]]
A redirect page should contain only:
#REDIRECT [[pagename]]
FIXME
Here is one line, followed by <br />
and another line.
Here is <!-- a comment -->.
HR like this
----
See also
- Wiki templates.
- http://www.mediawiki.org/wiki/Help:Formatting
- http://meta.wikimedia.org/wiki/Help:HTML_in_wikitext
- http://en.wikipedia.org/wiki/Help:HTML_in_wikitext
- http://en.wikipedia.org/wiki/Help:Wiki_markup
There may be small divergences, but in general, ours seems to be just a standard MediaWiki installation.