Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Trivial tip: [] and () keyboard remap

4 views
Skip to first unread message

David Golden

unread,
Feb 3, 2002, 5:51:04 PM2/3/02
to
To make writing Lisp and Scheme (and C and most
other languages, for that matter) easier, you might
want to reorganise your keyboard:

While there are some versions of Scheme that will let
you use []s interchangeably with ()s, it's worth pointing
out that you can easily remap your keyboard so that the
'[' key produces '(' etc. if the effort of pressing
"shift"+ 9/0 is just too much:

The following xmodmap expressions work on my XFree system to
rotate (), [], {} to more useful positions - you may have to
adjust them (see xmodmap manpage):

keycode 18 = 9 braceleft
keycode 19 = 0 braceright
keycode 34 = parenleft bracketleft
keycode 35 = parenright bracketright

This makes:
[keytop, value, shift-value]
'[' , ( , [
']' , ) , ]
'9' , 9 , {
'0' , 0 , }

Performing equivalent remappings on OSes that
don't use X as their GUI is left as an exercise for the reader.

--
Don't eat yellow snow.

0 new messages