Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I've got a classic M-series IBM keyboard that I want to put to a use. However, it does not have a Windows (a.k.a Super) key, that I use for many windows-manager-related shortcuts. On top of it, I use Emacs, so many Alt or Ctrl shortcuts are already taken. I also can't use Caps Lock as a modifier, since that it is taken for switching between languages.

What keyboard shortcuts would you recommend me for the windows manager (Gnome w. Emerald), taking into account these limitations (no Super key, can't remap Caps, and must not collide with frequent Emacs shortcuts)?

share|improve this question
    
Do you have a preferred key? –  Mikel Jan 23 '11 at 0:58
add comment

3 Answers 3

up vote 4 down vote accepted

Do you already use right Alt?

You could map it to the Windows key in Gnome settings:

  • System->Preferences->Keyboard
  • Layouts
  • Options...
  • Alt/Win key behavior
  • Left Alt is swapped with Left Win

Or you could map Caps Lock to the Windows key, and choose another shortcut for changing languages.

In the same control panel:

  • CapsLock key behaviour
  • Make CapsLock an additional Super

    (or Make CapsLock an additional Hyper)

and then:

  • Key(s) to change layout
  • too many options to mention

Common choices include:

  • Left Alt + Left Shift
  • Left Ctrl + Left Shift
  • Left Ctrl + Right Ctrl

but being an Emacs user, I would suggest the Both Ctrl keys together option.


If those options are insufficient, you will need to use xmodmap.

You could map Right Control to Windows at the shell like this:

xmodmap -e 'remove control = Control_R'
xmodmap -e 'add Mod4 = Control_R'

Depending on your system, you can probably also put the equivalent settings in .Xmodmap, e.g.

.Xmodmap

remove control = Control_R'
add Mod4 = Control_R'

If you'd rather use xmodmap than the Gnome control panel, you can change Control_R to something else, for instance right Alt is either Alt_R or ISO_Level3_Shift, depending on your keyboard settings, e.g.

xmodmap -e 'remove ISO_Level3_Shift = Mod5'
xmodmap -e 'add Mod4 = ISO_Level3_Shift'

works for me.

share|improve this answer
    
These are good options - Right Alt as super might work. I'll give it a swing. Thanks! –  Little Bobby Tables Jan 24 '11 at 9:09
    
No problem. Note that you'll probably need the xmodmap version, and that it could be ISO_Level3_Shift or Alt_R. –  Mikel Jan 24 '11 at 9:37
add comment

From normal desktop usage I can attest to the fact that 'alt' is used far less frequently than 'ctrl' (unless you use 'alt' for menubar navigation). Since I am assuming you have only 'shift', 'ctrl', and 'alt', I would pair 'alt' and 'shift' together - Your thumb could press down 'alt' while your pinky would press 'shift'. This kind of motion is extremely easy for me to use. Also, there are never any shortcuts calling for those two modifiers at the same time.

I don't use emacs but I'm pretty sure that it uses 'alt' as the main modifier. If so, I guess this runs the risk of conflicting. Thus, the only other usable alternative would be 'ctrl'+'shift'. Of course, if you have one of those context menu buttons then that could work wonderfully (depending on the position).

share|improve this answer
add comment

You can create or locate a keymap which treats left and right control or alt keys differently. I didn't see an easy way to do it from the Gnome panel.

Look at the options for xmodmap.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.