Template:Monzo: Difference between revisions
Jump to navigation
Jump to search
m Wikipedia has an article on code point and we can link directly |
Simply call Template: Ket to do the rendering |
||
Line 1: | Line 1: | ||
<includeonly> | <includeonly>{{#if: {{{legend|}}} | [[monzo]]: }}{{ket| {{{1|0}}} }}</includeonly><noinclude> | ||
This template eases | This '''monzo''' template eases typing [[monzo]]s: it puts ket notation (<code>[</code> and <code>⟩</code>) around its arguments (it also removes surrounding spaces), and you may optionally include a legend. | ||
== Usage example == | == Usage example == | ||
; You type | ; You type | ||
: <code><nowiki>{{monzo| -19 12 }}</nowiki></code> | : <code><nowiki>{{monzo| -19 12 }}</nowiki></code> | ||
: <code><nowiki>{{monzo| | : <code><nowiki>{{monzo|legend=1| -19 12 }}</nowiki></code> | ||
:'''Tip''': adding spaces improves readability of the wiki markup. | |||
; You get (rendered) | ; You get (rendered) | ||
: | : {{{{PAGENAME}}| -19 12 }} | ||
: {{{{PAGENAME}}|legend=1| -19 12 }} | |||
== Technical | == Technical note == | ||
[[ | This template calls [[Template: Ket]] to render the brackets. | ||
== See also == | == See also == | ||
* [[Template:Val]] | * [[Template: Val]] | ||
* [[Template: | * [[Template: Ket]] | ||
[[Category:Templates]] | [[Category:Templates]] |
Revision as of 09:44, 25 May 2023
This monzo template eases typing monzos: it puts ket notation ([
and ⟩
) around its arguments (it also removes surrounding spaces), and you may optionally include a legend.
Usage example
- You type
{{monzo| -19 12 }}
{{monzo|legend=1| -19 12 }}
- Tip: adding spaces improves readability of the wiki markup.
- You get (rendered)
- [-19 12⟩
- monzo: [-19 12⟩
Technical note
This template calls Template: Ket to render the brackets.