Syntax highlighting using Mediawiki formatting: Difference between revisions
Content added Content deleted
m (→{{header|Phix}}: inlined the command_line() call) |
m (replaced task sub-headings) |
||
Line 1: | Line 1: | ||
{{draft task}} |
{{draft task}} |
||
;Introduction: |
|||
When formatting a page for display, Mediawiki allows the page to include bold and italic text by placing the bold/italic text within paired repeated-single quote characters - 3 single quotes for bold and 2 for italic, 5 for bold italic.<br> |
When formatting a page for display, Mediawiki allows the page to include bold and italic text by placing the bold/italic text within paired repeated-single quote characters - 3 single quotes for bold and 2 for italic, 5 for bold italic.<br> |
||
Line 21: | Line 21: | ||
* less-than (<) to &lt; |
* less-than (<) to &lt; |
||
* greater-than (>) to &gt; |
* greater-than (>) to &gt; |
||
<br> |
|||
If your language doesn't have keywords/reserved words or comments, use your judgement on what to highlight in bold or italic : ) |
If your language doesn't have keywords/reserved words or comments, use your judgement on what to highlight in bold or italic : ) |
||
;Presenting your source: |
|||
Instead of showing your source within syntaxhighlight tags and having a separate output block, just show the source that would be output from your program when given its own source to process.<br> |
Instead of showing your source within syntaxhighlight tags and having a separate output block, just show the source that would be output from your program when given its own source to process.<br> |
||
I.e., don't use syntaxhighlight tags. |
I.e., don't use syntaxhighlight tags. |
||
;See also: |
|||
[https://www.mediawiki.org/wiki/Help:Formatting https://www.mediawiki.org/wiki/Help:Formatting] |
[https://www.mediawiki.org/wiki/Help:Formatting https://www.mediawiki.org/wiki/Help:Formatting] |