HOME

TheInfoList



OR:

On
personal computer A personal computer (PC) is a multi-purpose microcomputer whose size, capabilities, and price make it feasible for individual use. Personal computers are intended to be operated directly by an end user, rather than by a computer expert or tec ...
s with numeric keypads that use
Microsoft Microsoft Corporation is an American multinational technology corporation producing computer software, consumer electronics, personal computers, and related services headquartered at the Microsoft Redmond campus located in Redmond, Washin ...
operating system An operating system (OS) is system software that manages computer hardware, software resources, and provides common services for computer programs. Time-sharing operating systems schedule tasks for efficient use of the system and may also i ...
s, such as
Windows Windows is a group of several proprietary graphical operating system families developed and marketed by Microsoft. Each family caters to a certain sector of the computing industry. For example, Windows NT for consumers, Windows Server for ser ...
, many
characters Character or Characters may refer to: Arts, entertainment, and media Literature * ''Character'' (novel), a 1936 Dutch novel by Ferdinand Bordewijk * ''Characters'' (Theophrastus), a classical Greek set of character sketches attributed to The ...
that do not have a dedicated key combination on the
keyboard Keyboard may refer to: Text input * Keyboard, part of a typewriter * Computer keyboard ** Keyboard layout, the software control of computer keyboards and their mapping ** Keyboard technology, computer keyboard hardware and firmware Music * Musi ...
may nevertheless be entered using the Alt code (the Alt numpad input method). This is done by pressing and holding the key, then typing a number on the keyboard's
numeric keypad A numeric keypad, number pad, numpad, or ten key, is the palm-sized, usually-17-key section of a standard computer keyboard, usually on the far right. It provides calculator-style efficiency for entering numbers. The idea of a 10-key nu ...
that identifies the character and then releasing .


History and description


MS DOS

On
IBM PC compatible IBM PC compatible computers are similar to the original IBM Personal Computer, IBM PC, IBM Personal Computer XT, XT, and IBM Personal Computer/AT, AT, all from computer giant IBM, that are able to use the same software and expansion cards. Such ...
personal computer A personal computer (PC) is a multi-purpose microcomputer whose size, capabilities, and price make it feasible for individual use. Personal computers are intended to be operated directly by an end user, rather than by a computer expert or tec ...
s from the 1980s, the BIOS allowed the user to hold down the key and type a decimal number on the keypad. It would place the corresponding code into the keyboard buffer so that it would look (almost) as if the code had been entered by a single keystroke. Applications reading keystrokes from the BIOS would behave according to what action they associate with that code. Some would interpret the code as a command, but often it would be interpreted as a code to be placed on the screen at the location of the cursor, thus displaying the corresponding 8-bit character from the current code page. On the original IBM PC this was CP437. In most cases typing a number greater than 255 produced the character associated with the
remainder In mathematics, the remainder is the amount "left over" after performing some computation. In arithmetic, the remainder is the integer "left over" after dividing one integer by another to produce an integer quotient ( integer division). In algeb ...
after the number is divided by 256. Some Eastern European, Arabic and Asian computers used other hardware code pages, and MS-DOS was able to switch between them at runtime with commands like KEYB, CHCP or
MODE Mode ( la, modus meaning "manner, tune, measure, due measure, rhythm, melody") may refer to: Arts and entertainment * '' MO''D''E (magazine)'', a defunct U.S. women's fashion magazine * ''Mode'' magazine, a fictional fashion magazine which is ...
. This causes the Alt combinations to produce different characters (as well as changing the display of any previously-entered text in the same manner). A common choice in locales using variants of the Latin alphabet was
CP850 Code page 850 (CCSID 850) (also known as CP 850, IBM 00850, OEM 850, DOS Latin 1) is a code page used under DOS and Psion's EPOC16 operating systems in Western Europe. Depending on the country setting and system configuration, code page 850 is ...
, which provided more Latin character variants. (There were, however, many more code pages; for a more complete list, see '' code page''). PC keyboards designed for non-English use included other methods of inserting these characters, such as national
keyboard layout A keyboard layout is any specific physical, visual or functional arrangement of the keys, legends, or key-meaning associations (respectively) of a computer keyboard, mobile phone, or other computer-controlled typographic keyboard. is the actua ...
s, the
AltGr key AltGr (also Alt Graph) is a modifier key found on many computer keyboards (rather than a second Alt key found on US keyboards). It is primarily used to type characters that are not widely used in the territory where sold, such as foreign cur ...
or
dead key A dead key is a special kind of modifier key on a mechanical typewriter, or computer keyboard, that is typically used to attach a specific diacritic to a base letter. The dead key does not generate a (complete) character by itself, but modifies t ...
s, but the Alt key was the only method of inserting some characters and the only method that was the same on all machines, so it remained very popular. This input method is emulated by many pieces of software (such as later versions of MS-DOS and Windows) that do not use the BIOS keyboard decoding. In the ASCII standard, the numbers 0-31 and 127 are assigned to control characters, but MS DOS did not interpret the numbers this way. For instance,
code point In character encoding terminology, a code point, codepoint or code position is a numerical value that maps to a specific character. Code points usually represent a single grapheme—usually a letter, digit, punctuation mark, or whitespace—but ...
7 is assigned to BEL. However with some applications, may yield a bullet character (code point 7 on code page 437), but in others would treat this input as identical to (which on a terminal produces a control character with a value of 7).


Windows

The Alt codes had become so well known and memorized by users that Microsoft decided to preserve them, even though it used a new and different set of code pages for
Windows Windows is a group of several proprietary graphical operating system families developed and marketed by Microsoft. Each family caters to a certain sector of the computing industry. For example, Windows NT for consumers, Windows Server for ser ...
, such as
CP1252 Windows-1252 or CP-1252 (code page 1252) is a single-byte character encoding of the Latin alphabet, used by default in the legacy components of Microsoft Windows for English and many European languages including Spanish, French, and German. It i ...
. The old code pages were called OEM code pages; the new ones are called
Windows code pages Windows code pages are sets of characters or code pages (known as character encodings in other operating systems) used in Microsoft Windows from the 1980s and 1990s. Windows code pages were gradually superseded when Unicode was implemented in Wind ...
, The familiar Alt+number combinations produced codes from the OEM code page (for example, CP437 in the United States), matching the results from
MS-DOS MS-DOS ( ; acronym for Microsoft Disk Operating System, also known as Microsoft DOS) is an operating system for x86-based personal computers mostly developed by Microsoft. Collectively, MS-DOS, its rebranding as IBM PC DOS, and a few ope ...
. But prefixing a leading zero (0) to the number (usually meaning 4 digits) produced the character specified by the newer Windows code page, allowing them to be typed as well. For instance, the combination + would result in (Latin letter u with acute accent) which is at 163 in the OEM code page of CP437 or CP850, while + yields the character (symbol for the
pound sterling Sterling (abbreviation: stg; Other spelling styles, such as STG and Stg, are also seen. ISO code: GBP) is the currency of the United Kingdom and nine of its associated territories. The pound ( sign: £) is the main unit of sterling, and ...
) which is at 163 in CP1252. The numbers 0 –31 and 127 are control characters in the Windows code pages. Typing these numbers with a leading zero is ignored. Before Unicode was introduced, most Windows software could only create text using the repertoire of characters available in a single code page. Characters that did not exist in that page (such as a line-drawing graphic from the OEM page when the software was using the Windows code page) could not be inserted, and either were ignored or produced an unexpected character. Modern software uses Unicode, which assigns numbers (
code point In character encoding terminology, a code point, codepoint or code position is a numerical value that maps to a specific character. Code points usually represent a single grapheme—usually a letter, digit, punctuation mark, or whitespace—but ...
s) to all the characters in all the code pages. The software has access to the
glyphs A glyph () is any kind of purposeful mark. In typography, a glyph is "the specific shape, design, or representation of a character". It is a particular graphical representation, in a particular typeface, of an element of written language. A g ...
corresponding to all the code points in the supported fonts, so it can produce the character specified by any Alt code less than 256 whether zero-prefixed or non-zero-prefixed.


Transition to Unicode

When Windows later transitioned to Unicode, there was a desire to extend the Alt codes to allow entry of any Unicode code point. Numbers greater or equal to 256 pick the corresponding Unicode code point (lower numbers continue to pick characters from the OEM or ANSI code pages, but if 0 is prefixed the ANSI code page greatly resembles the first 256 characters of Unicode). Some applications ( RichEdit-based) like Word 2010,
Wordpad WordPad is the basic word processor that has been included with almost all versions of Microsoft Windows from Windows 95 onwards. It is more advanced than Windows Notepad, and simpler than Microsoft Word and Microsoft Works (last updated in 2007 ...
, and
PSPad PSPad editor is a freeware text editor and source editor intended for use by programmers. First released in 2001, this software is produced by a single Czech developer, Jan Fiala, for the Windows platform. PSPad has many software development-ori ...
operate this way. Other Windows applications, including
Notepad A notebook (also known as a notepad, writing pad, drawing pad, or legal pad) is a book or stack of paper pages that are often ruled and used for purposes such as note-taking, journaling or other writing, drawing, or scrapbooking. History ...
, Chrome,
Firefox Mozilla Firefox, or simply Firefox, is a free and open-source web browser developed by the Mozilla Foundation and its subsidiary, the Mozilla Corporation. It uses the Gecko rendering engine to display web pages, which implements current ...
, and
Microsoft Edge Microsoft Edge is a proprietary, cross-platform web browser created by Microsoft. It was first released in 2015 as part of Windows 10 and Xbox One and later ported to other platforms as a fork of Google's Chromium open-source project: Android ...
interpret all numbers greater than 255 modulo 256. Because most Unicode documentation and the
Character Map Character Map is a utility included with Microsoft Windows operating systems and is used to view the characters in any installed font, to check what keyboard input ( Alt code) is used to enter those characters, and to copy characters to the cli ...
accessory show the code points in hex, not decimal, a variation of Alt codes was developed to allow the numbers to be typed in hex (using the main keyboard for –). To enable it, a user must set or create a string type () value called EnableHexNumpad in the
registry Registry may refer to: Computing * Container registry, an operating-system-level virtualization registry * Domain name registry, a database of top-level internet domain names * Local Internet registry * Metadata registry, information system for re ...
key HKEY_CURRENT_USER\Control Panel\Input Method, assign the value data 1 to it, and then reboot or log out/in. A leading then indicates hex input, for example will produce  (e with
caron A caron (), háček or haček (, or ; plural ''háčeks'' or ''háčky'') also known as a hachek, wedge, check, kvačica, strešica, mäkčeň, varnelė, inverted circumflex, inverted hat, flying bird, inverted chevron, is a diacritic mark ( ...
). Many applications, including Word, Wordpad,
Excel ExCeL London (an abbreviation for Exhibition Centre London) is an exhibition centre, international convention centre and former hospital in the Custom House area of Newham, East London. It is situated on a site on the northern quay of the ...
, and
LibreOffice LibreOffice () is a free and open-source office productivity software suite, a project of The Document Foundation (TDF). It was forked in 2010 from OpenOffice.org, an open-sourced version of the earlier StarOffice. The LibreOffice suite co ...
, support a simpler method: typing the hex digits first (inserting them into the document) and then typing to change them into the matching Unicode character.


Problems

If is disabled, attempting an Alt code may cause unexpected results in some applications, due to the controls used on the same key. For example, can be taken as , causing a web browser to go back one page. Many laptops do not have a separate numeric keypad, but some may provide
numpad A numeric keypad, number pad, numpad, or ten key, is the palm-sized, usually-17-key section of a standard computer keyboard, usually on the far right. It provides calculator-style efficiency for entering numbers. The idea of a 10-key n ...
input by holding a modifier key (typically labelled "Fn"); thus one must press and hold both and keys while entering the character code. One limitation of the Alt code feature is that the key and the numpad keys being used to enter the code must both be on the same keyboard device. Users with keyboards that lack a numpad (e.g. tenkeyless designs) cannot use a separate numpad device to enter Alt codes while holding the key on their main keyboard.


Other operating systems

The Alt key method does not work on
ChromeOS ChromeOS, sometimes stylized as chromeOS and formerly styled as Chrome OS, is a Linux-based operating system designed by Google. It is derived from the open-source ChromiumOS and uses the Google Chrome web browser as its principal user interfa ...
,
macOS macOS (; previously OS X and originally Mac OS X) is a Unix operating system developed and marketed by Apple Inc. since 2001. It is the primary operating system for Apple's Mac computers. Within the market of desktop and lapt ...
, Linux or other
operating system An operating system (OS) is system software that manages computer hardware, software resources, and provides common services for computer programs. Time-sharing operating systems schedule tasks for efficient use of the system and may also i ...
s and there is no readily-accessible evidence of interest in replicating it, due to its including the 1980s IBM PC character encoding as part of its definition. However, numeric entry of Unicode characters is possible in most Unix or Unix-like OSs by typing , (release) then the hex number, then the space bar or enter key. For example, * for the registered trademark symbol , type ; * for the no entry sign , type


Alternatives

Alternative systems exist for users to make characters without selecting them by number, for example using a popup window that lets a user choose the desired character by clicking on it. Examples include the Windows
Character Map Character Map is a utility included with Microsoft Windows operating systems and is used to view the characters in any installed font, to check what keyboard input ( Alt code) is used to enter those characters, and to copy characters to the cli ...
or the Insert Character facility in MsOffice. See
Unicode input Unicode input is the insertion of a specific Unicode character on a computer by a user; it is a common way to input characters not directly supported by a physical keyboard. Unicode characters can be produced either by selecting them from a di ...
for more.


List of codes


See also

* Combining character * Compose key for other operating systems *
Keyboard layout A keyboard layout is any specific physical, visual or functional arrangement of the keys, legends, or key-meaning associations (respectively) of a computer keyboard, mobile phone, or other computer-controlled typographic keyboard. is the actua ...
*
List of Unicode characters As of Unicode version 15.0, there are 149,186 characters with code points, covering 161 modern and historical scripts, as well as multiple symbol sets. This article includes the 1062 characters in the Multilingual European Character Set 2 (ME ...
*
Numeric character reference A numeric character reference (NCR) is a common markup construct used in SGML and SGML-derived markup languages such as HTML and XML. It consists of a short sequence of characters that, in turn, represents a single character. Since WebSgml, XML ...


Notes


References

{{Reflist Character encoding Computer keyboards Input methods de:Alt (Taste)#Alt-Code