Template:Key press

From Official Kodi Wiki
Revision as of 16:22, 17 January 2009 by >[email protected] (robot Adding: de, eo, es, fr, hsb, hu, ja, ko, pt, ru)
Jump to navigation Jump to search
[edit] Template documentation
Emblem-important-yellow.png NOTICE: This is a documentation subpage for Template:Key press:
It contains usage information, categories and other content that is not part of the original template page.

The {{Key press}} template can be used to visually illustrate keystrokes. Typographically, it works best with examples that are separated from the normal flow of text, e.g. in table cells. It can also be used in lists (as on this page), but it may be a good idea to add an empty line between each list item, so the key borders won't overlap each other.

Example:

{{Key press|A}} produces A

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

Keystroke combinations

To illustrate keystroke combinations, just use extra parameters:

{{Key press|Alt|P}} produces Alt+P

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|Ctrl|Alt|Del}} produces Ctrl+Alt+Del

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

This template currently handles up to five (5) key name parameters; which should be more than enough to accomodate any possible simultaneous keystrokes.

When you feed several key names to this template, it adds a + with no surrounding whitespace. This means it can't line wrap, but when you show key combinations, for instance in a table, then that might cause overflow issues due to content being too wide for its container. The workaround in such instances is to manually build the key combination with spaces around the + so it can line wrap, like this:

{{Key press|Ctrl}} + {{Key press|Alt}} + {{Key press|Del}} produces Ctrl

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша + Alt

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша + Del

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

On the other hand, to illustrate Windows Alt codes, you might want to use separate templates with no intervening punctuation or whitespace. In most Windows systems in North America and Western Europe, for example, the plus–minus sign (±) can be entered by holding down the Alt key while entering 0177 (with the numeric keypad). This could be illustrated as follows:

{{Key press|Alt|0}}{{Key press|1}}{{Key press|7}}{{Key press|7}} produces Alt+0

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша1

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша7

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша7

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

Wikilinks

If there is an article about the key, you can wikilink the key's name just like any other wikitext, just like so:

{{Key press|[[wikipedia:Alt key|Alt]]}} produces Alt

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

When you are wikilinking the keys, please ensure that you are piping to the correct page (e.g. [[wikipedia:Control key|Ctrl]] instead of [[wikipedia:Ctrl]], which leads to a disambiguation page).

Wiki characters

Some wiki markup characters, like the pipe symbol, the semicolon and the equality sign, need to be entered using the {{!}}, {{;}} and {{=}} templates:

{{Key press|{{!}}}} produces |

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|{{;}}}} produces ;

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|{{=}}}} produces =

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша


Alternately, {{Key press|<nowiki>|</nowiki>}} is also an option.

Key symbols

Some key names have a fitting unicode character, and in those instances this template automatically adds such symbols to the following keys:

{{Key press|Caps Lock}} produces Caps Lock

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|Shift}} produces Shift

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|Enter}} produces Enter

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|Tab}} produces Tab

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|Backspace}} produces Backspace

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|Cmd}} produces Cmd

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|Opt}} produces Opt

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|Up}} produces Up

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|Down}} produces Down

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|Left}} produces Left

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|Right}} produces Right

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша


There are no characters for the Windows key and Menu key, so this template shows approximate characters for them in the following way:

{{Key press|Win}} produces Win

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|Menu}} produces Menu

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

Video games

Video game controllers often have specialized input labels that do not map quite as easily. The following are mappings for various game consoles and input features.

Directional input

The following should only be used when the input sequence uses something other than the primary input, or mixes input between directional devices.

{{Key press|l-down}} produces l-down

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|c-left}} produces c-left

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|r-up}} produces r-up

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

Stick specific diagonals are also supported:

{{Key press|l-nw}} produces l-nw

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|c-se}} produces c-se

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

{{Key press|r-ne}} produces r-ne

de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша

Technical details

This template calls {{Key press/core}}, which holds the code that otherwise would be repeated several times in {{Key press}}, thus simplifying the code.

See also

  • {{Button}} – produces a similar visual effect, but without the semantic markup, e.g. sample text


de:Vorlage:Taste es:Plantilla:Tecla eo:Ŝablono:Klavo fr:Modèle:Touche ko:틀:키눌림 hsb:Předłoha:Tasta hu:Sablon:Billentyű ja:Template:Keypress pt:Predefinição:Tecla ru:Шаблон:Клавиша