From ea63f0fae5c393ccf198aad0ae4dbda6d2a4391a Mon Sep 17 00:00:00 2001 From: marha Date: Fri, 24 Jul 2009 17:45:11 +0000 Subject: Added xkeyboard-config-1.6.tar.gz --- xorg-server/xkbdata.src/symbols/keypad | 100 +++++++++++++++++++++++---------- 1 file changed, 70 insertions(+), 30 deletions(-) (limited to 'xorg-server/xkbdata.src/symbols/keypad') diff --git a/xorg-server/xkbdata.src/symbols/keypad b/xorg-server/xkbdata.src/symbols/keypad index 9c56d0a82..fa2d72fbb 100644 --- a/xorg-server/xkbdata.src/symbols/keypad +++ b/xorg-server/xkbdata.src/symbols/keypad @@ -494,47 +494,87 @@ xkb_symbols "ossnumber_wang" { key { [ KP_Insert, KP_0, apostrophe, 0x1002195 ] }; // 0 ' ↕ }; -// ATM/phone-style hexadecimal numpad -// by Roland Kaufmann -// License: BSD -// Main numbers follows the traditions from ATMs and phones with -// numbers increasing downwards to the right. (It is easier to -// change the keyboard layout than to reprogram your local ATM; -// also cell-phones are becoming more common while calculators are -// becoming more rare). -// Third-level gives the letters used in hexadecimal numbers, or -// columns in small spreadsheets. Equal is added to start formulas -// (most numpads don't have their own equal key), comma as a list -// separator and colon to enter times and ranges. +// Standard base "pc" layout only contains cursor keys, and then gets +// augmented with the digits later. If you define your own layout for +// the numpad you can inherit the cursors, but you'll have to define +// the digits yourself. This module can be included in the rules to +// define math operators; these are the variants used in computer +// languages that are based on ASCII. NoSymbol doesn't mean that +// nothing is bound to the key but that no assignment is done here. +// srvr_ctrl(stdkeypad) and keypad(x11) declare the operator keys to +// be of type CTRL+ALT in order to assign server control events to +// them, but it uses the second level which is overwritten if we have +// more than one definition (shift state) for the key. Instead, here +// the commands are put at the fourth level. partial keypad_keys -xkb_symbols "phone_hex" { - // NumLock, Enter - include "keypad(core)" +xkb_symbols "ops" { + key { [ NoSymbol, slash, NoSymbol, XF86_Ungrab ] }; + key { [ NoSymbol, asterisk, NoSymbol, XF86_ClearGrab ] }; + key { [ NoSymbol, minus, NoSymbol, XF86_Prev_VMode ] }; + key { [ NoSymbol, plus, NoSymbol, XF86_Next_VMode ] }; + key { [ NoSymbol, equal ] }; +}; +// Hexadecimal Numpad, by Roland Kaufmann +// License: BSD (also covers variant with ATM digit order) +// Third-level gives the letters used in hexadecimal numbers, or +// columns in small spreadsheets. As a bonus, having 'e' available at +// the center of the keyboard makes it easy to enter floating point +// numbers in scientific notation. +// Equal is added to start formulas (most numpads on PCs don't have +// their own equal key), comma as a list separator (as most +// programming languages wants period as a decimal separator) and +// colon to enter times and ranges. Someone also may want to represent +// multiplication and division in prose using x and colon. +// Two first levels are specified as NoSymbol to not override any +// previous specification. Combine this with another keypad specifier, +// e.g. "legacy". +partial keypad_keys +xkb_symbols "hex" { key.type[Group1]="FOUR_LEVEL_MIXED_KEYPAD" ; - // None NumLock AltGr + // None NumLock AltGr // symbol row - key { [ KP_Divide, slash, parenleft ] }; - key { [ KP_Multiply, asterisk, parenright ] }; - key { [ KP_Subtract, minus, dollar ] }; + key { [ NoSymbol, NoSymbol, parenleft ] }; + key { [ NoSymbol, NoSymbol, parenright ] }; + key { [ NoSymbol, NoSymbol, dollar ] }; // upper row - key { [ KP_Home, KP_1, A ] }; - key { [ KP_Up, KP_2, B ] }; - key { [ KP_Prior, KP_3, C ] }; + key { [ NoSymbol, NoSymbol, a ] }; + key { [ NoSymbol, NoSymbol, b ] }; + key { [ NoSymbol, NoSymbol, c ] }; // home row - key { [ KP_Left, KP_4, D ] }; - key { [ KP_Begin, KP_5, E ] }; - key { [ KP_Right, KP_6, F ] }; - key { [ KP_Add, plus, comma ] }; + key { [ NoSymbol, NoSymbol, d ] }; + key { [ NoSymbol, NoSymbol, e ] }; + key { [ NoSymbol, NoSymbol, f ] }; + key { [ NoSymbol, NoSymbol, comma ] }; // lower row - key { [ KP_End, KP_7, equal ] }; - key { [ KP_Down, KP_8, x ] }; - key { [ KP_Next, KP_9, colon ] }; + key { [ NoSymbol, NoSymbol, equal ] }; + key { [ NoSymbol, NoSymbol, x ] }; + key { [ NoSymbol, NoSymbol, colon ] }; // decimal row - key { [ KP_Insert, KP_0, backslash ] }; + key { [ NoSymbol, NoSymbol, backslash ] }; +}; + +// Main numbers follows the traditions from ATMs and phones with +// numbers increasing downwards to the right. (It is easier to +// change the keyboard layout than to reprogram your local ATM; +// also cell-phones are becoming more common while calculators are +// becoming more rare). +// First level is left unspecified, so it may be combined with another +// layout, e.g. "legacy". +partial keypad_keys +xkb_symbols "atm" { + // upper row + key { [ NoSymbol, KP_1 ] }; + key { [ NoSymbol, KP_2 ] }; + key { [ NoSymbol, KP_3 ] }; + + // lower row + key { [ NoSymbol, KP_7 ] }; + key { [ NoSymbol, KP_8 ] }; + key { [ NoSymbol, KP_9 ] }; }; -- cgit v1.2.3