Template:Sagittal: Difference between revisions

From Xenharmonic Wiki
Jump to navigation Jump to search
Dave Keenan (talk | contribs)
Corrected escaped pipe from "\p" to <nowiki>"{{pipe}}"</nowiki>. Corrected the default case so it will return the unrecognised sagitype code
ArrowHead294 (talk | contribs)
mNo edit summary
Line 1: Line 1:
<includeonly><span class="bravura" style="font-size:{{{size|250%}}}; line-height:{{{height|16px}}}; vertical-align:-0.3em">{{#switch:
<includeonly><span class="bravura" style="font-size: {{{size|250%}}}; line-height: {{{height|16px}}}; vertical-align: -0.3em;">{{#switch:
   {{#replace:
   {{#replace:
     {{#replace:
     {{#replace:
Line 287: Line 287:
The '''Sagittal''' template converts a sagitype code (the pictorial ASCII code for sagittal) into a sagittal symbol in the BravuraText font.
The '''Sagittal''' template converts a sagitype code (the pictorial ASCII code for sagittal) into a sagittal symbol in the BravuraText font.


== Usage notes ==
{{documentation}}
This template accepts one unnamed argument and two named arguments:
# Text in the form of sagitype, representing a sagittal or related symbol.
# (optional) '''size =''' a CSS font-size value; defaults to "250%".
# (optional) '''height =''' a CSS line-height value; defaults to "16px".
 
'''Note:''' Pipe characters (<code>&#124;</code>) do not need to be escaped.
 
==Examples==
 
<nowiki>{{sagittal| /| }}</nowiki> → <span class="bravura" style="font-size:250%; line-height:16px; vertical-align:-0.3em;">&#xE302;</span>
 
<nowiki>{{sagittal| !) }}</nowiki> → <span class="bravura" style="font-size:250%; line-height:16px; vertical-align:-0.3em;">&#xE305;</span>
 
== See also ==
* [[Sagittal notation]]
* [[Sagitype]]
* [[Template:Bravura]]


[[Category:Font templates]]
[[Category:Font templates]]
</noinclude>

Revision as of 04:16, 6 October 2024

The Sagittal template converts a sagitype code (the pictorial ASCII code for sagittal) into a sagittal symbol in the BravuraText font.

Template documentation[view] [edit] [history] [purge]

The Sagittal template converts a sagitype code (the pictorial ASCII code for sagittal) into a sagittal symbol in the BravuraText font.

Usage notes

This template accepts one unnamed argument and two named arguments:

  1. Text in the form of sagitype, representing a sagittal or related symbol.
  2. (optional) size = a CSS font-size value; defaults to "250%".
  3. (optional) height = a CSS line-height value; defaults to "16px".

Notes:

  • Pipe characters (|) do not need to be escaped.
  • Short-sagitype (single-character codes for common sagittals) is not yet supported.

Examples

You type You get
{{sagittal| /| }}
{{sagittal| !) }}

See also