Template:Sagittal: Difference between revisions

From Xenharmonic Wiki
Jump to navigation Jump to search
Dave Keenan (talk | contribs)
Bracketed the trailing hair-space (U+200A) (that I added in the last update) with word-joiners (U+2060) to make the hair-space non-breaking
Dave Keenan (talk | contribs)
Added codes for SMuFL noteheads with note-names inside them; whole-note, half-note and black.
 
(6 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<includeonly><span class="bravura" style="font-size: {{{size|250%}}}; line-height: {{{height|16px}}}; vertical-align: -0.3em; {{#switch:
<includeonly>{{#ifeq:
  {{#replace:
    {{#replace:
      {{{1|}}}¦{{{2|⌫}}}¦{{{3|⌫}}}¦{{{4|⌫}}} |
      ¦⌫ | }} |
    {{pipe}} | ¦ }} |
  (¦\ |
  <span style="display: inline-block; transform: translateY(9px) scaleY(-1);"><span class="bravura" style="font-size: {{{size|250%}}}; line-height: {{{height|16px}}}; vertical-align: -0.255em; display: inline-block; transform: translateY(0.22em);">&#xE30F;</span></span> |
  <span class="bravura" style="font-size: {{{size|250%}}}; line-height: {{{height|16px}}}; vertical-align: -0.3em; {{#switch:
   {{#replace:
   {{#replace:
     {{#replace:
     {{#replace:
Line 13: Line 21:
   bb    = ">&#xE264; |
   bb    = ">&#xE264; |
   t    |
   t    |
   >    = ">&#xE282; |
   >    = display: inline-block; transform: translateY(-.017em);">&#xE282; |
   d    |
   d    |
   <    = ">&#xE284; |
   <    = ">&#xE284; |
   t#    |
   t#    |
   >#    = ">&#xE283; |
   >#    = display: inline-block; transform: translateY(.01em);">&#xE283; |
   db    |
   db    |
   <b    = ">&#xE285; |
   <b    = ">&#xE285; |
Line 36: Line 44:
   (¦)    = ">&#xE30C; |
   (¦)    = ">&#xE30C; |
   (!)    = ">&#xE30D; |
   (!)    = ">&#xE30D; |
   (¦\    = display: inline-block; transform: scaleY(-1);">&#xE30F; |
   (¦\    = ">&#xE30E; |
   (!/    = ">&#xE30F; |
   (!/    = ">&#xE30F; |
   )¦¦(  = ">&#xE310; |
   )¦¦(  = ">&#xE310; |
Line 279: Line 287:
///¦    = ">&#xE41C; |
///¦    = ">&#xE41C; |
\\\!    = ">&#xE41D; |
\\\!    = ">&#xE41D; |
ntAwh    = ">&#xE169; |
ntBwh    = ">&#xE16C; |
ntCwh    = ">&#xE16F; |
ntDwh    = ">&#xE172; |
ntEwh    = ">&#xE175; |
ntFwh    = ">&#xE178; |
ntGwh    = ">&#xE17B; |
ntAhf    = ">&#xE180; |
ntBhf    = ">&#xE183; |
ntChf    = ">&#xE186; |
ntDhf    = ">&#xE189; |
ntEhf    = ">&#xE18C; |
ntFhf    = ">&#xE18F; |
ntGhf    = ">&#xE192; |
ntAbl    = ">&#xE197; |
ntBbl    = ">&#xE19A; |
ntCbl    = ">&#xE19D; |
ntDbl    = ">&#xE1A0; |
ntEbl    = ">&#xE1A3; |
ntFbl    = ">&#xE1A6; |
ntGbl    = ">&#xE1A9; |
">{{#replace:
">{{#replace:
     {{#replace:
     {{#replace:
Line 284: Line 313:
       ¦⌫ | }} |
       ¦⌫ | }} |
     ¦ | {{pipe}} }}
     ¦ | {{pipe}} }}
}}</span>&#x2060;&#x200A;&#x2060;</includeonly><noinclude>
}}</span>}}{{nbhsp}}</includeonly><noinclude>
The '''Sagittal''' template converts a sagitype code (the pictorial ASCII code for sagittal) into a sagittal symbol in the BravuraText font.
 
{{documentation}}
{{documentation}}


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

Latest revision as of 07:48, 11 April 2025

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