Bug 21481

Summary: Backword key needed
Product: xkeyboard-config Reporter: Ethan Anderson <ethana2>
Component: GeneralAssignee: xkb
Status: RESOLVED INVALID QA Contact:
Severity: normal    
Priority: medium Keywords: NEEDINFO
Version: unspecified   
Hardware: All   
OS: All   
Whiteboard:
i915 platform: i915 features:
Attachments: out.xkb

Description Ethan Anderson 2009-04-29 15:06:13 UTC
http://bugzilla.gnome.org/show_bug.cgi?id=580694
http://forum.colemak.com/viewtopic.php?pid=4874#p4874

When I hit backspace (particularly key 66 under colemak), I need it to send a ctrl+backspace signal to the in-focus application to delete the last continuous word that I typed.
Comment 1 Sergey V. Udaltsov 2009-04-29 15:37:35 UTC
Sorry, I did not understand your idea in the gnome bugzilla. Now, let's talk about it.

If I understand you right, you want backspace to behave like ctrl-backpace. What you can try is set modifier_map Control to Backspace. If the apps just use the modifier, it might be enough.

In symbols/us file, 'colemak' section, add

modifier_map Control { BackSpace };

at the end. Then reload xkb configuration.
Comment 2 Ethan Anderson 2009-04-30 06:57:34 UTC
That sounds like exactly what I want! When I get home and have some
time I'll have to try that.  Thanks a ton!
Comment 3 Ethan Anderson 2009-04-30 09:17:30 UTC
Ok, I added that line to the end of the colemak section of
/usr/share/X11/xkb/symbols/us

I don't know how to reload the xkb configuration, so I guess I'll just
try logging out and in, restarting, etc.
Comment 4 Ethan Anderson 2009-04-30 09:33:26 UTC
That didn't work, and I can't find any relevant man pages or sites via
google, no response on #xorg..

How do I reload the xkb configuration?
Comment 5 Sergey V. Udaltsov 2009-04-30 15:00:43 UTC
Well, debugging xkb sometimes is tricky, and there is not much docs. See http://freedesktop.org/wiki/Software/XKeyboardConfig, the Links section.

Restarting X is usually enough.

Would you attach the result of "xkbcomp :0 -xkb out.xkb"?
Comment 6 Ethan Anderson 2009-04-30 21:41:58 UTC
ethan@home:~$ xkbcomp :0 -xkb out.xkb
Warning:          Could not load keyboard geometry for :0
                  BadAlloc (insufficient resources for operation)
                  Resulting keymap file will not describe geometry
Comment 7 Sergey V. Udaltsov 2009-05-01 02:39:38 UTC
> Warning:          Could not load keyboard geometry for :0
>                   BadAlloc (insufficient resources for operation)
>                   Resulting keymap file will not describe geometry
First of all, it is a warning, not a error. Second, it shows there something wrong with your xkb (probably, in X server). How do you start X? Do you use gdm autologin or smth? Try to do just 'setxkbmap', it might refresh your xkb configuration.
You should still get out.xkb with necessary details. Please attach it here.
Comment 8 Ethan Anderson 2009-05-02 14:18:51 UTC
Created attachment 25375 [details]
out.xkb
Comment 9 Ethan Anderson 2009-05-02 14:19:57 UTC
Evidently you can't attach things to bugs in bugzilla via email.  Learn something new every day.

Well, it's attached now, sorry about that.
Comment 10 Ethan Anderson 2009-05-04 13:00:56 UTC
I have confirmed that the qwerty backspace key is acting as both ctrl
and backspace.. so if I hold backspace (repeat is off), and hit 't',
it makes a new tab..  if I hit backspace and then (capslock)backspace,
it deletes the last word I typed.
I switched ? and /, so I know I'm applying the latest 'us' layout file here.

Now that I know kind of what's going on, I should be getting closer to
what I need..
Comment 11 Ethan Anderson 2009-05-06 06:45:40 UTC
Well, I hate moving my fingers to shift, when I've got two thumbs, so
after I figure this one out, I want my spacebar to act as a shift
modifier while held down, but if let up before another keystroke,
produce a space.  Eventually, hopefully, I'll get a keyboard with a
split spacebar so I can just remap each key how I will, but on a
laptop, that's not likely.  I think I'll try locking the shift
modifier to the space key and just see how that goes.
Comment 12 Sergey V. Udaltsov 2009-05-06 15:27:52 UTC
> Now that I know kind of what's going on, I should be getting closer to
> what I need..
Well, it was clear from out.xkb that your configuration was reloaded. But that did not actually work - it seems XKB is checking the state (of the Control modifier) before it changes it. Most probably, it is impossible to change, at least ATM I cannot think of any way... Let me look a bit more.
Comment 13 Sergey V. Udaltsov 2009-05-06 15:51:22 UTC
What you also can try:

key <BKSP> { [BackSpace], actions[Group1] = [SetMods(modifiers=Control)] };

But I am not sure that the action will be performed before the modifiers check...
Comment 14 Sergey V. Udaltsov 2010-05-06 16:09:59 UTC
no reply for a year

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.