diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-10-10 21:36:35 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-10-10 21:36:35 (GMT) |
commit | e02fdc0c1df829ee25edf15d6b88728cadd60947 (patch) | |
tree | f613746d26732b512b404de432cfc1e93796549f /generic | |
parent | 38ecedd3a179ee02c2541a6d4bf8d7b6348b4943 (diff) | |
download | tk-e02fdc0c1df829ee25edf15d6b88728cadd60947.zip tk-e02fdc0c1df829ee25edf15d6b88728cadd60947.tar.gz tk-e02fdc0c1df829ee25edf15d6b88728cadd60947.tar.bz2 |
Add deprecate Key-names to ks_names.h, and make sure that deprecated Keynames are translated back to their non-deprecated names.
This is how X11 does it, our emulation should do it the same way.
Added test-case demonstrating this with Eth -> ETH.
Diffstat (limited to 'generic')
-rw-r--r-- | generic/ks_names.h | 77 | ||||
-rw-r--r-- | generic/tkBind.c | 4 |
2 files changed, 78 insertions, 3 deletions
diff --git a/generic/ks_names.h b/generic/ks_names.h index 9f49130..665af5d 100644 --- a/generic/ks_names.h +++ b/generic/ks_names.h @@ -23,13 +23,31 @@ { "Delete", 0xFFFF }, { "Multi_key", 0xFF20 }, { "Kanji", 0xFF21 }, +{ "Muhenkan", 0xFF22 }, +{ "Henkan_Mode", 0xFF23 }, +{ "Henkan", 0xFF23 }, +{ "Romaji", 0xFF24 }, +{ "Hiragana", 0xFF25 }, +{ "Katakana", 0xFF26 }, +{ "Hiragana_Katakana", 0xFF27 }, +{ "Zenkaku", 0xFF28 }, +{ "Hankaku", 0xFF29 }, +{ "Zenkaku_Hankaku", 0xFF2A }, +{ "Touroku", 0xFF2B }, +{ "Massyo", 0xFF2C }, +{ "Kana_Lock", 0xFF2D }, +{ "Kana_Shift", 0xFF2E }, +{ "Eisu_Shift", 0xFF2F }, +{ "Eisu_toggle", 0xFF30 }, { "Home", 0xFF50 }, { "Left", 0xFF51 }, { "Up", 0xFF52 }, { "Right", 0xFF53 }, { "Down", 0xFF54 }, { "Prior", 0xFF55 }, +{ "Page_Up", 0xFF55 }, { "Next", 0xFF56 }, +{ "Page_Down", 0xFF56 }, { "End", 0xFF57 }, { "Begin", 0xFF58 }, { "Win_L", 0xFF5B }, @@ -56,6 +74,19 @@ { "KP_F2", 0xFF92 }, { "KP_F3", 0xFF93 }, { "KP_F4", 0xFF94 }, +{ "KP_Home", 0xFF95 }, +{ "KP_Left", 0xFF96 }, +{ "KP_Up", 0xFF97 }, +{ "KP_Right", 0xFF98 }, +{ "KP_Down", 0xFF99 }, +{ "KP_Prior", 0xFF9A }, +{ "KP_Page_Up", 0xFF9A }, +{ "KP_Next", 0xFF9B }, +{ "KP_Page_Down", 0xFF9B }, +{ "KP_End", 0xFF9C }, +{ "KP_Begin", 0xFF9D }, +{ "KP_Insert", 0xFF9E }, +{ "KP_Delete", 0xFF9F }, { "KP_Equal", 0xFFBD }, { "KP_Multiply", 0xFFAA }, { "KP_Add", 0xFFAB }, @@ -155,6 +186,7 @@ { "percent", 0x025 }, { "ampersand", 0x026 }, { "quoteright", 0x027 }, +{ "apostrophe", 0x027 }, { "parenleft", 0x028 }, { "parenright", 0x029 }, { "asterisk", 0x02a }, @@ -212,6 +244,7 @@ { "asciicircum", 0x05e }, { "underscore", 0x05f }, { "quoteleft", 0x060 }, +{ "grave", 0x060 }, { "a", 0x061 }, { "b", 0x062 }, { "c", 0x063 }, @@ -291,6 +324,7 @@ { "Icircumflex", 0x0ce }, { "Idiaeresis", 0x0cf }, { "Eth", 0x0d0 }, +{ "ETH", 0x0d0 }, { "Ntilde", 0x0d1 }, { "Ograve", 0x0d2 }, { "Oacute", 0x0d3 }, @@ -305,6 +339,7 @@ { "Udiaeresis", 0x0dc }, { "Yacute", 0x0dd }, { "Thorn", 0x0de }, +{ "THORN", 0x0de }, { "ssharp", 0x0df }, { "agrave", 0x0e0 }, { "aacute", 0x0e1 }, @@ -364,11 +399,13 @@ { "zabovedot", 0x1bf }, { "Racute", 0x1c0 }, { "Abreve", 0x1c3 }, +{ "Lacute", 0x1c5 }, { "Cacute", 0x1c6 }, { "Ccaron", 0x1c8 }, { "Eogonek", 0x1ca }, { "Ecaron", 0x1cc }, { "Dcaron", 0x1cf }, +{ "Dstroke", 0x1d0 }, { "Nacute", 0x1d1 }, { "Ncaron", 0x1d2 }, { "Odoubleacute", 0x1d5 }, @@ -378,11 +415,13 @@ { "Tcedilla", 0x1de }, { "racute", 0x1e0 }, { "abreve", 0x1e3 }, +{ "lacute", 0x1e5 }, { "cacute", 0x1e6 }, { "ccaron", 0x1e8 }, { "eogonek", 0x1ea }, { "ecaron", 0x1ec }, { "dcaron", 0x1ef }, +{ "dstroke", 0x1f0 }, { "nacute", 0x1f1 }, { "ncaron", 0x1f2 }, { "odoubleacute", 0x1f5 }, @@ -414,6 +453,7 @@ { "ubreve", 0x2fd }, { "scircumflex", 0x2fe }, { "kappa", 0x3a2 }, +{ "kra", 0x3a2 }, { "Rcedilla", 0x3a3 }, { "Itilde", 0x3a5 }, { "Lcedilla", 0x3a6 }, @@ -425,6 +465,7 @@ { "lcedilla", 0x3b6 }, { "emacron", 0x3ba }, { "gacute", 0x3bb }, +{ "gcedilla", 0x3bb }, { "tslash", 0x3bc }, { "ENG", 0x3bd }, { "eng", 0x3bf }, @@ -454,6 +495,7 @@ { "kana_closingbracket", 0x4a3 }, { "kana_comma", 0x4a4 }, { "kana_middledot", 0x4a5 }, +{ "kana_conjunctive", 0x4a5 }, { "kana_WO", 0x4a6 }, { "kana_a", 0x4a7 }, { "kana_i", 0x4a8 }, @@ -464,6 +506,7 @@ { "kana_yu", 0x4ad }, { "kana_yo", 0x4ae }, { "kana_tu", 0x4af }, +{ "kana_tsu", 0x4af }, { "prolongedsound", 0x4b0 }, { "kana_A", 0x4b1 }, { "kana_I", 0x4b2 }, @@ -482,7 +525,9 @@ { "kana_SO", 0x4bf }, { "kana_TA", 0x4c0 }, { "kana_TI", 0x4c1 }, +{ "kana_CHI", 0x4c1 }, { "kana_TU", 0x4c2 }, +{ "kana_TSU", 0x4c2 }, { "kana_TE", 0x4c3 }, { "kana_TO", 0x4c4 }, { "kana_NA", 0x4c5 }, @@ -493,6 +538,7 @@ { "kana_HA", 0x4ca }, { "kana_HI", 0x4cb }, { "kana_HU", 0x4cc }, +{ "kana_FU", 0x4cc }, { "kana_HE", 0x4cd }, { "kana_HO", 0x4ce }, { "kana_MA", 0x4cf }, @@ -550,6 +596,7 @@ { "Arabic_meem", 0x5e5 }, { "Arabic_noon", 0x5e6 }, { "Arabic_heh", 0x5e7 }, +{ "Arabic_ha", 0x5e7 }, { "Arabic_waw", 0x5e8 }, { "Arabic_alefmaksura", 0x5e9 }, { "Arabic_yeh", 0x5ea }, @@ -566,31 +613,45 @@ { "Macedonia_gje", 0x6a2 }, { "Cyrillic_io", 0x6a3 }, { "Ukranian_je", 0x6a4 }, +{ "Ukrainian_ie", 0x6a4 }, { "Macedonia_dse", 0x6a5 }, { "Ukranian_i", 0x6a6 }, +{ "Ukrainian_i", 0x6a6 }, { "Ukranian_yi", 0x6a7 }, +{ "Ukrainian_yi", 0x6a7 }, { "Serbian_je", 0x6a8 }, +{ "Cyrillic_je", 0x6a8 }, { "Serbian_lje", 0x6a9 }, +{ "Cyrillic_lje", 0x6a9 }, { "Serbian_nje", 0x6aa }, +{ "Cyrillic_nje", 0x6aa }, { "Serbian_tshe", 0x6ab }, { "Macedonia_kje", 0x6ac }, { "Byelorussian_shortu", 0x6ae }, { "Serbian_dze", 0x6af }, +{ "Cyrillic_dzhe", 0x6af }, { "numerosign", 0x6b0 }, { "Serbian_DJE", 0x6b1 }, { "Macedonia_GJE", 0x6b2 }, { "Cyrillic_IO", 0x6b3 }, { "Ukranian_JE", 0x6b4 }, +{ "Ukrainian_IE", 0x6b4 }, { "Macedonia_DSE", 0x6b5 }, { "Ukranian_I", 0x6b6 }, +{ "Ukrainian_I", 0x6b6 }, { "Ukranian_YI", 0x6b7 }, +{ "Ukrainian_YI", 0x6b7 }, { "Serbian_JE", 0x6b8 }, +{ "Cyrillic_JE", 0x6b8 }, { "Serbian_LJE", 0x6b9 }, +{ "Cyrillic_LJE", 0x6b9 }, { "Serbian_NJE", 0x6ba }, +{ "Cyrillic_NJE", 0x6ba }, { "Serbian_TSHE", 0x6bb }, { "Macedonia_KJE", 0x6bc }, { "Byelorussian_SHORTU", 0x6be }, { "Serbian_DZE", 0x6bf }, +{ "Cyrillic_DZHE", 0x6bf }, { "Cyrillic_yu", 0x6c0 }, { "Cyrillic_a", 0x6c1 }, { "Cyrillic_be", 0x6c2 }, @@ -666,6 +727,8 @@ { "Greek_UPSILONdieresis", 0x7a9 }, { "Greek_UPSILONaccentdieresis", 0x7aa }, { "Greek_OMEGAaccent", 0x7ab }, +{ "Greek_accentdieresis", 0x7ae }, +{ "Greek_horizbar", 0x7af }, { "Greek_alphaaccent", 0x7b1 }, { "Greek_epsilonaccent", 0x7b2 }, { "Greek_etaaccent", 0x7b3 }, @@ -687,6 +750,7 @@ { "Greek_THETA", 0x7c8 }, { "Greek_IOTA", 0x7c9 }, { "Greek_KAPPA", 0x7ca }, +{ "Greek_LAMDA", 0x7cb }, { "Greek_LAMBDA", 0x7cb }, { "Greek_MU", 0x7cc }, { "Greek_NU", 0x7cd }, @@ -711,6 +775,7 @@ { "Greek_theta", 0x7e8 }, { "Greek_iota", 0x7e9 }, { "Greek_kappa", 0x7ea }, +{ "Greek_lamda", 0x7eb }, { "Greek_lambda", 0x7eb }, { "Greek_mu", 0x7ec }, { "Greek_nu", 0x7ed }, @@ -902,15 +967,22 @@ { "leftshoe", 0xbda }, { "lefttack", 0xbdc }, { "righttack", 0xbfc }, +{ "hebrew_doublelowline", 0xcdf }, { "hebrew_aleph", 0xce0 }, { "hebrew_beth", 0xce1 }, +{ "hebrew_bet", 0xce1 }, { "hebrew_gimmel", 0xce2 }, +{ "hebrew_gimel", 0xce2 }, { "hebrew_daleth", 0xce3 }, +{ "hebrew_dalet", 0xce3 }, { "hebrew_he", 0xce4 }, { "hebrew_waw", 0xce5 }, { "hebrew_zayin", 0xce6 }, +{ "hebrew_zain", 0xce6 }, { "hebrew_het", 0xce7 }, +{ "hebrew_chet", 0xce7 }, { "hebrew_teth", 0xce8 }, +{ "hebrew_tet", 0xce8 }, { "hebrew_yod", 0xce9 }, { "hebrew_finalkaph", 0xcea }, { "hebrew_kaph", 0xceb }, @@ -920,15 +992,20 @@ { "hebrew_finalnun", 0xcef }, { "hebrew_nun", 0xcf0 }, { "hebrew_samekh", 0xcf1 }, +{ "hebrew_samech", 0xcf1 }, { "hebrew_ayin", 0xcf2 }, { "hebrew_finalpe", 0xcf3 }, { "hebrew_pe", 0xcf4 }, { "hebrew_finalzadi", 0xcf5 }, +{ "hebrew_finalzade", 0xcf5 }, { "hebrew_zadi", 0xcf6 }, +{ "hebrew_zade", 0xcf6 }, { "hebrew_kuf", 0xcf7 }, +{ "hebrew_qoph", 0xcf7 }, { "hebrew_resh", 0xcf8 }, { "hebrew_shin", 0xcf9 }, { "hebrew_taf", 0xcfa }, +{ "hebrew_taw", 0xcfa }, { "Hebrew_switch", 0xFF7E }, { "XF86AudioLowerVolume", 0x1008FF11 }, { "XF86AudioMute", 0x1008FF12 }, diff --git a/generic/tkBind.c b/generic/tkBind.c index f65d2ee..f9cf8cc 100644 --- a/generic/tkBind.c +++ b/generic/tkBind.c @@ -1322,9 +1322,7 @@ TkBindInit( hPtr = Tcl_CreateHashEntry(&keySymTable, kPtr->name, &newEntry); Tcl_SetHashValue(hPtr, kPtr->value); hPtr = Tcl_CreateHashEntry(&nameTable, (char *) kPtr->value, &newEntry); - if (newEntry) { - Tcl_SetHashValue(hPtr, kPtr->name); - } + Tcl_SetHashValue(hPtr, kPtr->name); } #endif /* REDO_KEYSYM_LOOKUP */ |