I finally got around to play with the different suggestions.
The best seems to be a cocktail made out of the suggestions by Martin and Matt:
clear lock
clear control
keycode 66 = Control_L (66 is the key to the left of "A")
add Control = Control_L
keysym Control_R = Caps_Lock
add Lock = Caps_Lock
keycode 37 = F22
This makes caps lock (the key next to "A") into the control key, the left
control key into F22, and the right control key into the caps lock.
And XEmacs doesn't complain!
Still, if I try to simplify
keysym Control_R = Caps_Lock
add Lock = Caps_Lock
to
add Lock = Control_R
(as suggested by Martin) then I get a complaint that "Control_R does
locking, which is nonsensical". These two are essentially equivalent
if I understand 'man xmodmap' correctly (which I could never figure out
completely).
It seems that XEmacs assumes a specific function for every keysym name...
Thanks for all the suggestions.
--michael
Matt Tucker <tuck(a)whistlingfish.net> said:
-- "Stephen J. Turnbull" <turnbull(a)sk.tsukuba.ac.jp> spake thusly:
> Michael> I do something similar:
>
> Not really.
>
> Michael> remove Control =3D Control_L
> Michael> remove Lock =3D Caps_Lock
> Michael> keysym Control_R =3D Caps_Lock
>
> So far, so good. You now have no key that can do lock, and you have =
a
> key in the lower right corner that does control. That key generates
> the keysym Caps_Lock. The key in the lower left corner generates the
> keysym Control_L, and the key to the left of the "A" generates the
> keysym Caps_Lock.
>
> Michael> add Control =3D Caps_Lock
>
> You have added the control modifier to the key to the left of "A" and
> (redundantly) to the key in the lower right corner.
>
> Michael> keycode 37 =3D F22
>
> I assume this keycode corresponds to the key in the lower left =
corner?
> That key now generates the keysym F22. You have no Control keys
> anymore, although you can generate control keystrokes. Summarizing:
>
> Physical Keysym Modifier
> ------------------ --------- --------
> Left of "A" Caps_Lock control
> Lower left corner F22
> Lower right corner Caps_Lock control
It might also help if someone were to point out the commands that need =
to be added to the current configuration to get the appropiate =
behavior.
I'll attempt to do so, but someone please correct me if I'm wrong.
I know for a fact that you want to make "Left of 'A'" a control key. To
=
do this, figure out what the keycode of that key is (using xev), and =
then add to .xmodmap (assuming your keyboard is like mine, which it =
probably is):
keycode 66 =3D Control_L
Then I'm going to make a leap and guess that you want the lower right =
corner to be a Caps Lock. So you could do:
remove Control =3D Caps_Lock
add Lock =3D Caps_Lock
This should give you a configuration:
Physical Keysym Modifier
------------------ --------- --------
Left of "A" Control_L control
Lower left corner F22
Lower right corner Caps_Lock (caps) lock
With the set of commands:
remove Control =3D Control_L
remove Lock =3D Caps_Lock
keysym Control_R =3D Caps_Lock
add Control =3D Caps_Lock
keycode 37 =3D F22
keycode 66 =3D Control_L
remove Control =3D Caps_Lock
add Lock =3D Caps_Lock
I've tried launching XEmacs with this configuration, and it doesn't =
complain. There's a probably a shorter way to get what you want (it =
seems like that configuration does a bit too much moving things =
around), but I'll leave that as an exercise for you if you want to =
pursue it.
Now I have to figure out how to fix my keyboard. ;-)