From 59e597e9fe5858539787e77d50930c73c40ef2ad Mon Sep 17 00:00:00 2001 From: Daniel Carl Date: Sun, 10 Feb 2013 17:43:31 +0100 Subject: [PATCH] Fixed none working keybindings with a 1. If a keybind contained a 1 this was only checked if it where uppercase, and the shift mask was added to the keybinding. Indeed the 1 is uppercase and lowercase together, so we ignore such cases where the char is available in both cases. --- src/keybind.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/keybind.c b/src/keybind.c index dcd06eb..dae1651 100644 --- a/src/keybind.c +++ b/src/keybind.c @@ -206,7 +206,10 @@ static void keybind_str_to_keybind(gchar* str, Keybind* keybind) /* set the shift mask for uppercase keys like 'G' */ guint32 ukval = gdk_keyval_to_unicode(keybind->keyval); - if (g_unichar_isgraph(ukval) && gdk_keyval_is_upper(keybind->keyval)) { + if (g_unichar_isgraph(ukval) + /* ignore SHIFT if key is not subject to case */ + && (gdk_keyval_is_upper(keybind->keyval) && !gdk_keyval_is_lower(keybind->keyval)) + ) { keybind->modmask = GDK_SHIFT_MASK; } -- 2.20.1