Commit 2ec0a22d55d35ffa120cb913655c639ee738fd8d

Daniel Stone 2012-07-13T00:10:23

Add Cyrillic and Greek to case-checking Evidently good to have on its own, but also fixes a regression from xkbcomp where we'd identify implicitly-typed Cyrillic keys as TWO_LEVEL rather than ALPHABETIC. Signed-off-by: Daniel Stone <daniel@fooishbar.org>

diff --git a/src/misc.c b/src/misc.c
index 07a675d..f809055 100644
--- a/src/misc.c
+++ b/src/misc.c
@@ -207,6 +207,24 @@ _XkbcKSCheckCase(xkb_keysym_t ks)
             (ks >= XKB_KEY_amacron && ks <= XKB_KEY_umacron))
             rtrn |= _XkbKSLower;
         break;
+    case 6: /* Cyrillic */
+        if ((ks >= XKB_KEY_Serbian_DJE && ks <= XKB_KEY_Serbian_DZE) ||
+            (ks >= XKB_KEY_Cyrillic_YU && ks <= XKB_KEY_Cyrillic_HARDSIGN))
+            rtrn |= _XkbKSUpper;
+        if ((ks >= XKB_KEY_Serbian_dje && ks <= XKB_KEY_Serbian_dze) ||
+            (ks >= XKB_KEY_Cyrillic_yu && ks <= XKB_KEY_Cyrillic_hardsign))
+            rtrn |= _XkbKSLower;
+        break;
+    case 7: /* Greek */
+        if ((ks >= XKB_KEY_Greek_ALPHAaccent &&
+             ks <= XKB_KEY_Greek_OMEGAaccent) ||
+            (ks >= XKB_KEY_Greek_ALPHA && ks <= XKB_KEY_Greek_OMEGA))
+            rtrn |= _XkbKSUpper;
+        if ((ks >= XKB_KEY_Greek_alphaaccent &&
+             ks <= XKB_KEY_Greek_omegaaccent) ||
+            (ks >= XKB_KEY_Greek_alpha && ks <= XKB_KEY_Greek_OMEGA))
+            rtrn |= _XkbKSLower;
+        break;
     case 18: /* latin 8 */
         if ((ks == XKB_KEY_Wcircumflex) ||
             (ks == XKB_KEY_Ycircumflex) ||