After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 115384 - Capslock makes keyboard shortcuts work incorrectly
Capslock makes keyboard shortcuts work incorrectly
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Widget: Other
2.2.x
Other Linux
: Normal minor
: future
Assigned To: Marco Pesenti Gritti
Marco Pesenti Gritti
Depends on:
Blocks:
 
 
Reported: 2003-06-17 17:08 UTC by Toni Willberg
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Toni Willberg 2003-06-17 17:08:15 UTC
I pressed ^t and waited for new tab to open. Instead Ephy did hide my
location bar. "Wtf?" I asked.

I had accidentally pressed capslock.

So, capslock should not have effect on keyboard shortcuts. It works
correctly on other GNOME apps, like Evolution.
Comment 1 Marco Pesenti Gritti 2003-06-17 17:31:46 UTC
Gtk2 evolution you mean ?
Comment 2 Toni Willberg 2003-06-17 17:48:24 UTC
evolution-1.4.0-2 I mean.

Works atleast in Evolution, Pan, gnome desktop switcher,
gnome-calculator and so on.

It also works in Ephy's menu's... (Try capslock and ^w)

Something weird with ^t and ^T...


Comment 3 Dave Bordoley [Not Reading Bug Mail] 2003-06-17 23:47:23 UTC
I have sneaking suspicion this has something to do with gtk+ since
ctrl+N works with or without capslock but ctrl+T acts like
ctrl+shift+T with caplock.
Comment 4 Pekka Lampila 2003-06-24 20:30:18 UTC
Strange, this works correctly for me.
I'm using Debian unstable and newest epiphany from CVS.
GTK+'s version is 2.2.1 and mozilla's 1.3.1.
Comment 5 Marco Pesenti Gritti 2003-06-24 20:33:14 UTC
Could be a gtk regression, I posted a similar bug about keys some days
ago (ctrl/alt F1 open help).
Comment 6 Dave Bordoley [Not Reading Bug Mail] 2003-07-08 16:57:23 UTC
1.0 if we can fix it.
Comment 7 Marco Pesenti Gritti 2003-08-01 18:53:55 UTC
Could be 100439
Comment 8 Marco Pesenti Gritti 2003-08-05 17:36:03 UTC
Reproducable with gnome terminal (caps lock + ctrl t opens a new tab).
Comment 9 Owen Taylor 2003-08-12 18:38:45 UTC
Mostly fixed in CVS.

Tue Aug 12 14:27:42 2003  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/gtkkeyhash.c (_gtk_key_hash_lookup): Remove
        GDK_LOCK_MASK before calling
        gdk_keymap_translate_keyboard_state so bindings
        and accelerators are independent of the Caps-lock
        key. (#115384, reported by Toni Willberg)

Two minor issues remain:

 - The same thing should probably apply to NumLock as
   well as CapsLock, though I'm not entirely sure about
   that.

 - For certain keyboard setups (XFree86 with the caps:shift
   option, in particular), the modifier for the caps-lock
   key is not GDK_LOCK_MASK, but something else.

   In order to handle such cases we need to search for the
   appropriate modifier rather than assuming it is GDK_LOCK_MASK.

The best way to handle these things is probably to have
something like a alternative version of
gdk_keymap_translate_keyboard_state() with a flags field
that can be set to include GDK_TRANSLATE_NO_LOCK_MODIFIERS
flag.
Comment 10 Owen Taylor 2003-08-13 14:11:43 UTC
Ivan Pascal points out that the way caps:shift is implemented,
it actually will work. (Some magic is done so that 
Lock is not in the consumed modifers for normal operation,
but is in consumed modifiers for caps:shift - this is 
why we have the '& ~tmp_modifiers' in:

 if (state & ~tmp_modifiers & LockMask)
    tmp_keyval = gdk_keyval_to_upper (tmp_keyval)

in gdk_keymap_translate_keyboard_state().

Closing, because I suspect that stripping out NumLock probably
is not a good idea.