What Character Does Enter Key Generate On A Keyboard

Posted on by

Apr 07, 2020  USING ALT CODES ON LAPTOP WITHOUT NUM LOCK. Almost all the Spanish accent words require the combination of numeric key or the alt keys. However since your laptop does not have that option you may use the character map. Special characters are characters that cannot be found on your keyboard. These characters include advanced mathematical. Here’s what you need to enter in your AutoHotkey script to create a shortcut for your special character. This will let you press Alt+ the character of your choice to enter a special character. Substitute yourhotkey with the character you want to use as your shortcut, and yourspecialcharacter with the special character you want to input. I'm trying to figure an easy way to generate certain control characters such as NUL and EOF from the keyboard for testing purposes. Does anyone know how to do it? This is possible on Windows/DOS by turning the Num Lock key on, and then holding down the ALT key while you enter the numeric code from the keypad.

With ordinary rules, you can match any key that produces a character. However, sometimes you may want to match other keys, for example Backspace, or Ctrl- or Alt-combinations. In order to match keys like these you need to use virtual keys.

Every key on the keyboard is identified by a virtual key code. Virtual keys are identified by square brackets [ ] containing a combination of zero or more shift-key codes and a virtual key code.

Using virtual keys

Virtual keys are used in the key section of a rule. Virtual keys are not valid in the context of a rule, as the context consists solely of characters. As virtual keys can only be output on a few platforms, they should not be used in the output section of a rule.

A typical use of virtual keys is to make rules to recognise non-character keys, such as Backspace or Tab; for example:

Virtual keys are also commonly used to recognise Ctrl or Alt key combinations, like this:

While Keyman virtual keys are closely related to the Windows virtual keys, there are differences, and the two cannot be used completely interchangeably. Most of the following discussion relates to physical keyboards.

The key codes refer to the actual key at the given position on a standard US-English keyboard. When used with a non US-English keyboard driver (selected through Control Panel/Keyboards), differences can arise, and this use is not recommended.

The Right-Alt key has traditionally been used on European keyboards as an additional shift state, usually known as AltGr. The end user of Keyman keyboards can select an option to emulate Right-Alt with Ctrl+Alt, as Right-Alt is not available on many notebook keyboards. Thus, it is wise to avoid using Ctrl+Alt combinations and Right-Alt combinations in the same keyboard.

Additionally, it is useful to keep in mind that when this emulation is active, it is not possible to recognise the Ctrl+Right Alt combination, as this is overridden by Ctrl+Alt (producing Right-Alt). This can have ramifications in keyboards such as German, which makes use of the Ctrl+AltGr combination.

Key

Virtual Keys vs Virtual Character Keys: Keyman 6.0 introduced a new feature known as mnemonic layouts. This feature requires that the 'white' alphabet/numeric/punctuation keys in the primary section of the keyboard are referenced by the character on the key cap rather than the key position (as with non-mnemonic layouts). However, all other keys on the keyboard should be referenced as normal.

It is important to remember that you can choose any character that appears on a given keycap, not just the unshifted character. For instance, if you use ['A'], you will be matching the unshifted A key; you must still explicitly state the shift state for the key.

Reference

The general format for a virtual character key is:

where 'c' is any character on the keyboard. This can include characters on European keyboards.

The general format for a virtual key is:

The possible shift codes are:

Shift KeyCode
Either shift keySHIFT
Either control keyCTRL
Left control keyLCTRL
Right control key (not found on all keyboards)RCTRL
Either alt keyALT
Left alt keyLALT
Right alt key or AltGr on European keyboards (not found on all keyboards)RALT
Caps Lock onCAPS
Caps Lock offNCAPS

Using Right Alt / AltGr

A caveat for using RALT: When using many European keyboards, Windows internally translates the RALT (or AltGr) key to LCTRL+RALT. Keyman also includes an option to treat CTRL+ALT in the same manner as RALT (this is useful for notebook keyboards that do not have a RALT or AltGr key. Both of these 'features' mean that you should avoid using more than one of the following shift combinations in the same keyboard:

Shift Code
RALT
CTRL ALT
CTRL RALT
LCTRL ALT
LCTRL RALT

Caps Lock

If neither CAPS or NCAPS is specified, then the CAPS LOCK key is ignored. This means that if you do have a rule that uses CAPS, you should make sure that no other rule references that key without NCAPS or CAPS specified. In the following example, the [CAPS K_A] rule will never be matched, because the [K_A] rule does not take CAPS LOCK into account:

Instead, you should use:

Caps lock is also controlled by Caps lock stores.

Common virtual key codes

What Character Does Enter Key Generate On A Keyboard Download

The following table lists all of the common virtual key codes:

Key CodeKey NameKey CodeKey Name
K_SPACEK_oE2102nd Key (European)
K_AAK_BKSPBackspace
K_BBK_TABTab
K_CCK_ENTEREnter
K_DDK_ESCEscape
K_EEK_LEFTLeft Arrow
K_FFK_UPUp Arrow
K_GGK_RIGHTRight Arrow
K_HHK_DOWNDown Arrow
K_IIK_PGUPPage Up
K_JJK_PGDNPage Down
K_KKK_HOMEHome
K_LLK_ENDEnd
K_MMK_INSInsert
K_NNK_DELDelete
K_OOK_F1F1
K_PPK_F2F2
K_QQK_F3F3
K_RRK_F4F4
K_SSK_F5F5
K_TTK_F6F6
K_UUK_F7F7
K_VVK_F8F8
K_WWK_F9F9
K_XXK_F10F10
K_YYK_F11F11
K_ZZK_F12F12
K_11K_KP5Key Pad 5 (Numlock off)
K_22K_NP0Number Pad 0
K_33K_NP1Number Pad 1
K_44K_NP2Number Pad 2
K_55K_NP3Number Pad 3
K_66K_NP4Number Pad 4
K_77K_NP5Number Pad 5
K_88K_NP6Number Pad 6
K_99K_NP7Number Pad 7
K_00K_NP8Number Pad 8
K_BKQUOTE`K_NP9Number Pad 9
K_HYPHEN-K_NPSTARNumber Pad *
K_EQUAL=K_NPPLUSNumber Pad +
K_LBRKT[K_NPMINUSNumber Pad -
K_RBRKT]K_NPDOTNumber Pad .
K_BKSLASHK_NPSLASHNumber Pad /
K_COLON;
K_QUOTE'
K_COMMA,
K_PERIOD.
K_SLASH/

The following table lists all of the less common virtual key codes:

Key CodeKey NameKey CodeKey Name
K_SELSelectK_?96Unknown Key 96
K_PRINTPrintK_?97Unknown Key 97
K_EXECExecuteK_?98Unknown Key 98
K_HELPHelpK_?99Unknown Key 99
K_SEPARATORSeparatorK_?9AUnknown Key 9A
K_F13F13K_?9BUnknown Key 9B
K_F14F14K_?9CUnknown Key 9C
K_F15F15K_?9DUnknown Key 9D
K_F16F16K_?9EUnknown Key 9E
K_F17F17K_?9FUnknown Key 9F
K_F18F18K_?A0Unknown Key A0
K_F19F19K_?A1Unknown Key A1
K_F20F20K_?A2Unknown Key A2
K_F21F21K_?A3Unknown Key A3
K_F22F22K_?A4Unknown Key A4
K_F23F23K_?A5Unknown Key A5
K_F24F24K_?A6Unknown Key A6
K_KANJI?15Kanji Key #1K_?A7Unknown Key A7
K_KANJI?16Kanji Key #2K_?A8Unknown Key A8
K_KANJI?17Kanji Key #3K_?A9Unknown Key A9
K_KANJI?18Kanji Key #4K_?AAUnknown Key AA
K_KANJI?19Kanji Key #5K_?ABUnknown Key AB
K_KANJI?1CKanji Key #6K_?ACUnknown Key AC
K_KANJI?1DKanji Key #7K_?ADUnknown Key AD
K_KANJI?1EKanji Key #8K_?AEUnknown Key AE
K_KANJI?1FKanji Key #9K_?AFUnknown Key AF
K_oE0OEM Key E0K_?B0Unknown Key B0
K_oE1OEM Key E1K_?B1Unknown Key B1
K_oE3OEM Key E3K_?B2Unknown Key B2
K_oE4OEM Key E4K_?B3Unknown Key B3
K_oE6OEM Key E6K_?B4Unknown Key B4
K_oE9OEM Key E9K_?B5Unknown Key B5
K_oEAOEM Key EAK_?B6Unknown Key B6
K_oEBOEM Key EBK_?B7Unknown Key B7
K_oECOEM Key ECK_?B8Unknown Key B8
K_oEDOEM Key EDK_?B9Unknown Key B9
K_oEEOEM Key EEK_?C1Unknown Key C1
K_oEFOEM Key EFK_?C2Unknown Key C2
K_oF0OEM Key F0K_?C3Unknown Key C3
K_oF1OEM Key F1K_?C4Unknown Key C4
K_oF2OEM Key F2K_?C5Unknown Key C5
K_oF3OEM Key F3K_?C6Unknown Key C6
K_oF4OEM Key F4K_?C7Unknown Key C7
K_oF5OEM Key F5K_?C8Unknown Key C8
K_?00Unknown Key 00K_?C9Unknown Key C9
K_?05 or K_NPENTERNumber Pad ENTERK_?CAUnknown Key CA
K_?06Unknown Key 06K_?CBUnknown Key CB
K_?07Unknown Key 07K_?CCUnknown Key CC
K_?0AUnknown Key 0AK_?CDUnknown Key CD
K_?0BUnknown Key 0BK_?CEUnknown Key CE
K_?0EUnknown Key 0EK_?CFUnknown Key CF
K_?0FUnknown Key 0FK_?D0Unknown Key D0
K_?1AUnknown Key 1AK_?D1Unknown Key D1
K_?3AUnknown Key 3AK_?D2Unknown Key D2
K_?3BUnknown Key 3BK_?D3Unknown Key D3
K_?3CUnknown Key 3CK_?D4Unknown Key D4
K_?3DUnknown Key 3DK_?D5Unknown Key D5
K_?3EUnknown Key 3EK_?D6Unknown Key D6
K_?3FUnknown Key 3FK_?D7Unknown Key D7
K_?40Unknown Key 40K_?D8Unknown Key D8
K_?5BUnknown Key 5BK_?D9Unknown Key D9
K_?5CUnknown Key 5CK_?DAUnknown Key DA
K_?5DUnknown Key 5DK_oDFUnknown Key DF
K_?5EUnknown Key 5EK_?E5Unknown Key E5
K_?5FUnknown Key 5FK_?E7Unknown Key E7
K_?88Unknown Key 88K_?E8Unknown Key E8
K_?89Unknown Key 89K_?F6Unknown Key F6
K_?8AUnknown Key 8AK_?F7Unknown Key F7
K_?8BUnknown Key 8BK_?F8Unknown Key F8
K_?8CUnknown Key 8CK_?F9Unknown Key F9
K_?8DUnknown Key 8DK_?FAUnknown Key FA
K_?8EUnknown Key 8EK_?FBUnknown Key FB
K_?8FUnknown Key 8FK_?FCUnknown Key FC
K_?92Unknown Key 92K_?FDUnknown Key FD
K_?94Unknown Key 94K_?FEUnknown Key FE
K_?95Unknown Key 95K_?FFUnknown Key FF

The following table lists all of the reserved virtual key codes that will not be recognised even if they are on your keyboard, although they are included in Keyman for completeness:

Key CodeKey Name
K_SHIFTShift
K_CONTROLControl
K_ALTAlt
K_CAPSCaps Lock
K_NUMLOCKNum Lock
K_SCROLLScroll Lock
K_LBUTTONLeft Mouse Button
K_MBUTTONMiddle Mouse Button
K_RBUTTONRight Mouse Button
K_CANCELCtrl+Break
K_PAUSEPause
K_PRTSCNPrint Screen

Examples

Virtual keys should not be used in the output as they will only work on Windows applications and are not portable.

Virtual keys and touch layouts

Touch layouts do not have physical keyboards, so the concept of virtual keys is in some ways less relevant. However, for compatibility and ease of reference, Keyman maintains a mapping between the US English virtual key codes and the characters emitted by these keys. If a touch key is given one of these virtual keys (e.g. K_A), then the corresponding US English character (a) will be emitted, if no rule is provided to override that.

Each touch key must be given an identifying key code which is unique to the key layer. Key codes by and large correspond to the virtual key codes used when creating a keyboard program for a desktop keyboard, and should start with K_, for keys mapped to standard Keyman virtual key names, e.g. K_HYPHEN, and T_ or U_ for user-defined names, e.g. T_ZZZ. If keyboard rules exist matching the key code in context, then the output from the key will be determined by the processing of those rules. It is usually best to include explicit rules to manage the output from each key, but if no rules matching the key code are included in the keyboard program, and the key code matches the pattern U_xxxx (where xxxx is a 4-digit uppercase hex string), then the Unicode character U+xxxx will be output. The key code is always required, and a default code will usually be generated automatically by Keyman Developer 9.

  • K_xxxx is used for a standard Keyman Desktop key name, e.g. K_W, K_ENTER. You cannot make up your own K_xxxx names. Many of the K_ ids have overloaded output behaviour, for instance, if no rule is matched for K_W, Keyman will output 'w' when it is touched. The standard key names are listed above. Typically, you would use only the 'common' virtual key codes.

  • T_xxxx is used for any user defined names, e.g. T_SCHWA. If you wanted to use it, T_ENTER would also be valid. If no rule matches it, the key will have no output behaviour.

  • U_#### is used as a shortcut for a key that will output that single Unicode value, if no rule matches it. This is similar to the overloaded behaviour for K_ ids. Thus #### must be a valid hexadecimal value. E.g. U_0259 would generate a schwa if no rule matches. It is still valid to have a rule such as + [U_0259] > ...

Any key can be used to switch keyboard layers (see below), but the following layer-switching key codes have been added for switching to some commonly used secondary layers:

IdentifierValue
K_NUMERALS261
K_SYMBOLS262
K_CURRENCIES263
K_SHIFTED264
K_ALTGR265

On your Android phone, you’re not limited to typing only the symbols you see on the alphabetic keyboard. Most Android phones feature alternative character keyboards. To access these special keyboards, tap the symbol or numeric key, such as the ?1J key.

The number and variety of special character keyboards varies from phone to phone. At least one symbol keyboard is available, though you may find multiple symbol keyboards, special numeric keypads, and even emoji keyboards. Here, four different symbol keyboards are shown.

To switch keyboards, locate the special symbols, illustrated here. Tap a symbol to view an alternative character set. Though these symbols and the keyboards vary, nearly all Android phones use the ABC key to return to the standard, alpha keyboard.

Numeric Key

Some special symbols are available quickly from the alpha keyboard. These symbols include accented letters and other common characters. The secret is to long-press a key, such as the A key, shown here.

After you long-press, drag your finger upward to choose a character from the pop-up palette. If you choose the wrong character, tap the Delete key on the onscreen keyboard to erase the mistyped symbol.

  • Some onscreen keyboards show tiny symbols next to the letters and numbers. If so, you can long-press that key to access the symbol, similar to the technique illustrated.
  • Emojis are tiny images that express words or concepts, such as those shown on the bottom right in the first figure above. The variety of emojis is almost endless; choose another palette from the top of the keyboard.
  • Emoticons predate emojis. They use characters to create faces or other expressions. Unlike emojis, emoticons appear identical on every smartphone; emojis may look subtly different and not every phone sports the same variety.

What Character Does Enter Key Generate On A Keyboard Computer

Emoticon is a portmanteau of emotion and icon. Emoji is a Japanese term that means “picture character.”