[NBLUG/talk] Logitech keyboards with "extra" keys

Eric Eisenhart eric at nblug.org
Tue Apr 13 14:47:14 PDT 2004


On Tue, Apr 13, 2004 at 12:36:28PM -0700, Lincoln Peters wrote:
> Has anyone used a Logitech keyboard that features an additional row of
> programmable keys along the top?  How difficult is it to use those keys
> under Linux?
> 
> I'm running Debian/unstable with KDE 3.2.1.

Yes, I've used one of those before and set it up so those keys would be
useful.  I was using GNOME with the sawfish window manager at the time. 
I've since switched to a more ergonomic keyboard from a different
manufacturer that doesn't happen to have those keys (or anything like that
at all)

First off, I used http://www.jwz.org/xkeycaps/ to create an xmodmap file
that mapped the keys (KeyCodes) to appropriate mappings (KeySyms), such as
mapping a little down arrow next to a speaker to "XF86AudioLowerVolume", a
little right-pointing triangle to "XF86AudioPlay", a little light bulb to
"XF86LightBulb", etc.  (I don't remember the exact graphics or mappings now,
but if you look in /usr/X11R6/lib/X11/XKeysymDB there's a large section full
of mappings that likely match the pictures on the keys well).  I already had
a script set up to run during the start of X and I added the appropriate
xmodmap command line to that.

Next, I installed the "sawfish-xmms"
(http://packages.debian.org/stable/x11/sawfish-xmms) package.

Then I did some configuring in sawfish's menu for handling keybindings. 
Some keys ran commands, some called XMMS actions, etc.  It's possible to
configure sawfish to run, say "xmms --play-pause" when you hit the play
button, but using the "sawfish-xmms" stuff is faster (less lag from button
push to apparent effect).

For instance, i think I configured the little guy running to run a script
that did "xscreensaver-command -lock" as well as logging me as "out to
lunch" in our timekeeping application; and I configured "XF86HomePage" to
run "ssh-add -D ; xscreensaver-command -lock ; xscreensaver-watch-eric.pl ;
ssh-add" where the watch script looked at the output of
"xscreensaver-command -watch" and exited when "UNBLANK" showed up. 
(http://www.jwz.org/xscreensaver/man3.html has a similar example).
-- 
Eric Eisenhart
NBLUG Co-Founder & Director-At-Large
The North Bay Linux Users Group
http://nblug.org/
eric at nblug.org, IRC: Freiheit at freenode, AIM: falschfreiheit, ICQ: 48217244




More information about the talk mailing list