3,860
edits
(-) |
(-) |
||
| Line 53: | Line 53: | ||
====Adding a space using this template==== | ====Adding a space using this template==== | ||
;<big>4. {{tlf|sp}} inside function</big> | ;<big>4. {{tlf|sp}} inside function</big> | ||
If you use this template to add a space before the optional string (i.e. {{samp|<nowiki>{{sp}}</nowiki>and Latin}}), you will get the correct output both when leaving out {{para|latin}}, and when it's invoked. | |||
{| class="wikitable" style="background-color: white;" | {| class="wikitable" style="background-color: white;" | ||
! Template code !! "{{samp|latin}}" invoked !! Output | ! Template code !! "{{samp|latin}}" invoked !! Output | ||
| Line 62: | Line 62: | ||
|} | |} | ||
===Limitations=== | |||
;<big>Wiki pre-formatting markup</big> | |||
Any string or group of strings indented by a single space character will be pre-formatted and displayed in a box. | |||
;Example | |||
If you enter the code: | |||
<code><span style="color: #ffffff; background-color: #0095dd;"> </span>This text is pre-formatted.</code> | |||
the output will be: | |||
This text is pre-formatted. | |||
By using this template, you can override this function, but to no avail. Any inserted leading space characters from {{tlf|sp}} will simply be trimmed, leaving any text looking normal and aligned firmly to the left. | |||
;Example | |||
If you write: | |||
<code><span style="color: #ffffff; background-color: #0095dd;"><nowiki>{{sp}}</nowiki></span>This text is pre-formatted.</code> | |||
the output will simply be: | |||
 This text is pre-formatted. | |||
<!-- | |||
==See also== | ==See also== | ||
* {{tl|nbsp}}: Inserts (up to 25) non-breaking space characters. | * {{tl|nbsp}}: Inserts (up to 25) non-breaking space characters. | ||
* {{tl|space}}: Inserts any one of a number of different space characters. | * {{tl|space}}: Inserts any one of a number of different space characters. | ||
--> | |||
edits