Difference between revisions of "Template:Shortcut"
From Audacity Wiki
(New template from manual wiki.) |
(Restore 36577 now that we have string functions.) |
||
(3 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
− | <noinclude>{{ | + | <noinclude> |
+ | An example here: {{shortcut|CTRL + A}}. The idea is to represent shortcuts. This has a box round it just as kbrd does, but the colour is purple rather than white. If we want different colours we can, e.g. {{shortcut|CTRL + A|d5c9e6}} gives the old darker purple we used to have before we added the box. The feature now also supports showing the Mac symbol for command. | ||
+ | ==More Examples== | ||
− | ''' | + | '''Standard example''' |
+ | {{code| <nowiki>{{shortcut|Ctrl + Alt + Z}}</nowiki>}} | ||
+ | {{shortcut|Ctrl + Alt + Z}} | ||
− | |||
− | + | '''Example using Cmd''' | |
− | + | {{code| <nowiki>{{shortcut|Cmd + Z}}</nowiki>}} | |
− | + | {{shortcut|Cmd + Z}} | |
− | |||
− | |||
− | |||
− | ''''' | + | '''If the text is empty, then the format box is omitted too.''' |
+ | {{code| <nowiki>ABC{{shortcut|}}DEF</nowiki>}} | ||
+ | ABC{{shortcut|}}DEF | ||
− | ''' | + | '''Example with a different colour.''' |
+ | {{code| <nowiki>{{shortcut|Ctrl + Alt + Z|a0c0a0}}</nowiki>}} | ||
+ | {{shortcut|Ctrl + Alt + Z|d0f0d0}} | ||
− | |||
− | + | </noinclude><includeonly>{{#if:{{{1|}}}|<span class="kbrd" style="background-color: #{{{2|d0d0f8}}}">{{#replace:{{{1}}}|Cmd|⌘}}</span>|}}</includeonly> | |
− | |||
− | |||
− | |||
− | |||
− | {{ | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− |
Latest revision as of 15:55, 12 September 2018
An example here: CTRL + A. The idea is to represent shortcuts. This has a box round it just as kbrd does, but the colour is purple rather than white. If we want different colours we can, e.g. CTRL + A gives the old darker purple we used to have before we added the box. The feature now also supports showing the Mac symbol for command.
More Examples
Standard example
{{shortcut|Ctrl + Alt + Z}} |
Ctrl + Alt + Z
Example using Cmd
{{shortcut|Cmd + Z}} |
⌘ + Z
If the text is empty, then the format box is omitted too.
ABC{{shortcut|}}DEF |
ABCDEF
Example with a different colour.
{{shortcut|Ctrl + Alt + Z|a0c0a0}} |
Ctrl + Alt + Z