summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--NEWS13
-rw-r--r--src/keysym.c4
-rw-r--r--src/keysym.h6
-rw-r--r--xkbcommon.map6
-rw-r--r--xkbcommon/xkbcommon.h20
5 files changed, 41 insertions, 8 deletions
diff --git a/NEWS b/NEWS
index abe9fd7..15859ae 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,16 @@
+libxkbcommon 0.8.0 - UNRELEASED
+
+- Add xkb_keysym_to_{upper,lower} to perform case-conversion directly on
+ keysyms. This is useful in some odd cases, but working with the Unicode
+ representations should be preferred when possible.
+
+- Added Unicode conversion rules for the signifblank and permille keysyms.
+
+- New API:
+ xkb_keysym_to_upper()
+ xkb_keysym_to_lower()
+
+==================
libxkbcommon 0.7.2 - 2017-08-04
==================
diff --git a/src/keysym.c b/src/keysym.c
index 9e7b4fb..6d06de0 100644
--- a/src/keysym.c
+++ b/src/keysym.c
@@ -264,7 +264,7 @@ xkb_keysym_is_upper(xkb_keysym_t ks)
return (ks == upper ? true : false);
}
-xkb_keysym_t
+XKB_EXPORT xkb_keysym_t
xkb_keysym_to_lower(xkb_keysym_t ks)
{
xkb_keysym_t lower, upper;
@@ -274,7 +274,7 @@ xkb_keysym_to_lower(xkb_keysym_t ks)
return lower;
}
-xkb_keysym_t
+XKB_EXPORT xkb_keysym_t
xkb_keysym_to_upper(xkb_keysym_t ks)
{
xkb_keysym_t lower, upper;
diff --git a/src/keysym.h b/src/keysym.h
index ca2bd5e..2633963 100644
--- a/src/keysym.h
+++ b/src/keysym.h
@@ -62,10 +62,4 @@ xkb_keysym_is_keypad(xkb_keysym_t keysym);
bool
xkb_keysym_is_modifier(xkb_keysym_t keysym);
-xkb_keysym_t
-xkb_keysym_to_upper(xkb_keysym_t ks);
-
-xkb_keysym_t
-xkb_keysym_to_lower(xkb_keysym_t ks);
-
#endif
diff --git a/xkbcommon.map b/xkbcommon.map
index cc468c6..f28f68f 100644
--- a/xkbcommon.map
+++ b/xkbcommon.map
@@ -97,3 +97,9 @@ global:
xkb_state_key_get_consumed_mods2;
xkb_state_mod_index_is_consumed2;
} V_0.6.0;
+
+V_0.8.0 {
+global:
+ xkb_keysym_to_lower;
+ xkb_keysym_to_upper;
+} V_0.7.0;
diff --git a/xkbcommon/xkbcommon.h b/xkbcommon/xkbcommon.h
index 8b05835..3e7a68d 100644
--- a/xkbcommon/xkbcommon.h
+++ b/xkbcommon/xkbcommon.h
@@ -493,6 +493,26 @@ xkb_keysym_to_utf8(xkb_keysym_t keysym, char *buffer, size_t size);
uint32_t
xkb_keysym_to_utf32(xkb_keysym_t keysym);
+/**
+ * Convert a keysym to its uppercase form.
+ *
+ * If there is no such form, the keysym is returned unchanged.
+ *
+ * The conversion rules may be incomplete; prefer to work with the Unicode
+ * representation instead, when possible.
+ */
+xkb_keysym_t
+xkb_keysym_to_upper(xkb_keysym_t ks);
+
+/**
+ * Convert a keysym to its lowercase form.
+ *
+ * The conversion rules may be incomplete; prefer to work with the Unicode
+ * representation instead, when possible.
+ */
+xkb_keysym_t
+xkb_keysym_to_lower(xkb_keysym_t ks);
+
/** @} */
/**