Template:Keypress/doc
From FORwiki
(Difference between revisions)
(Created page with '{{Documentation subpage}} <!-- PLEASE ADD CATEGORIES AND INTERWIKIS AT THE BOTTOM OF THIS PAGE. --> This is the {{tl|keypress}} template. It can be used to illustrate keystroke...') |
|||
Line 10: | Line 10: | ||
If there is an article about the key you can wikilink the key's name like any other wiki text. Like this: | If there is an article about the key you can wikilink the key's name like any other wiki text. Like this: | ||
- | :<code><nowiki>{{keypress| | + | :<code><nowiki>{{keypress|Alt}}</nowiki></code> produces {{keypress|Alt}} |
To illustrate keystroke combinations, just use extra parameters: | To illustrate keystroke combinations, just use extra parameters: | ||
- | :<code><nowiki>{{keypress|[[Alt key|Alt]]|P}}</nowiki></code> produces {{keypress| | + | :<code><nowiki>{{keypress|[[Alt key|Alt]]|P}}</nowiki></code> produces {{keypress|Alt|P}} |
- | :<code><nowiki>{{keypress|[[Ctrl]]|Alt|Del}}</nowiki></code> produces {{keypress| | + | :<code><nowiki>{{keypress|[[Ctrl]]|Alt|Del}}</nowiki></code> produces {{keypress|Ctrl|Alt|Del}} |
=== Key symbols === | === Key symbols === | ||
Line 31: | Line 31: | ||
:<code><nowiki>{{keypress|↓}}</nowiki></code> produces {{keypress|↓}} | :<code><nowiki>{{keypress|↓}}</nowiki></code> produces {{keypress|↓}} | ||
:<code><nowiki>{{keypress|→}}</nowiki></code> produces {{keypress|→}} | :<code><nowiki>{{keypress|→}}</nowiki></code> produces {{keypress|→}} | ||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- |
Revision as of 12:15, 10 October 2009
This is the {{keypress}} template.
It can be used to illustrate keystrokes.
Example:
{{keypress|A}}
produces A
If there is an article about the key you can wikilink the key's name like any other wiki text. Like this:
{{keypress|Alt}}
produces Alt
To illustrate keystroke combinations, just use extra parameters:
{{keypress|[[Alt key|Alt]]|P}}
produces Alt
+P
{{keypress|[[Ctrl]]|Alt|Del}}
produces Ctrl
+Alt+Del
Key symbols
Some key names have a fitting unicode character. This template automatically adds such "icons" to the following key names:
{{keypress|Shift}}
produces ⇧ Shift
{{keypress|Enter}}
produces ↵ Enter
{{keypress|Cmd}}
produces ⌘ Cmd
{{keypress|Opt}}
produces ⌥ Opt
{{keypress|Tab}}
produces Tab ⇆
{{keypress|Backspace}}
produces ← Backspace
This template has no special handling for the arrow key symbols. But here is how we usually code the arrow keys, so you can copy and paste the code for them:
{{keypress|←}}
produces ←
{{keypress|↑}}
produces ↑
{{keypress|↓}}
produces ↓
{{keypress|→}}
produces →