You are not logged in.

#1 2010-09-16 18:03:54

hbekel
Member
Registered: 2008-10-04
Posts: 311

xchainkeys - chained keybindings for X11

xchainkeys, a standalone X11 program which implements key chaining in a similar manner to  ratpoison or StumpWM. (Think xbindkeys for keychains).

Given that a wm is properly scriptable (such as musca), xchainkeys can be used to replace the wm's keyboard handling and implement ratpoison-style keybindings. Escaping chain prefix keys (i.e. passing through the prefix key to the currently focused window) is supported, and thus no keys are "stolen" from applications.

The behavior of keychains can be configured in various ways, allowing stuff like "chrooted" keychains (as in openbox) or special interactive modes (see :repeat). Feedback about the current chain status can optionally be displayed in a small popup window.

AUR package: http://aur.archlinux.org/packages.php?ID=40797.

As an example, this is my current (incomplete) config for musca:

timeout 3000     
delay 1000
feedback on   
font -*-terminus-bold-*-normal-*-14-*-72-72-c-80-*-*
foreground blue 
background black 

# keybindings...

C-t :enter chain
C-t C-t :escape
C-t C-g :abort

C-t r :exec bashrun
C-t c :exec urxvt
C-t f :exec firefox
C-t e :exec emacs

C-w c :exec musca -c 'command'
C-w g :exec musca -c 'switch group'

C-w h :exec musca -c 'hsplit 1/2'
C-w C-h :exec printf 'hsplit 1/2\nfocus right' | musca -i
C-w v :exec musca -c 'vsplit 1/2'
C-w C-v :exec printf 'vsplit 1/2\nfocus down' | musca -i

C-w r :exec musca -c 'remove'
C-w C-r :exec printf 'kill\nremove' | musca -i

C-w i :exec  musca -c 'focus up' 
C-w k :exec musca -c 'focus down' 
C-w j :exec musca -c 'focus left' 
C-w l :exec musca -c 'focus right'

C-w C-i :repeat musca -c 'resize up'
C-w C-k :repeat musca -c 'resize down'
C-w C-j :repeat musca -c 'resize left'
C-w C-l :repeat musca -c 'resize right'

C-w space :exec musca -c 'cycle local next'
C-w n :exec musca -c 'cycle local next'
C-w p :exec musca -c 'cycle local prev'
C-w C-A-q :exec musca -c 'quit'

Offline

#2 2010-09-18 11:18:37

sugardeath
Member
Registered: 2010-03-02
Posts: 82

Re: xchainkeys - chained keybindings for X11

What would I use if I wanted to use the windows key?  S is for shift and W appears to be for nothing... 

Thanks smile


Edit: Oh, no, I'm wrong.  The --keys option shows me it's W and that actually does work...

Nice tool!  Compiz's 10 or 11 commands were too few for me and I'd prefer a standalone thing as opposed to Openbox's on my other computers.  This is great!

Last edited by sugardeath (2010-09-18 11:23:17)

Offline

#3 2012-06-14 16:32:41

mentat
Member
From: France
Registered: 2009-01-13
Posts: 138
Website

Re: xchainkeys - chained keybindings for X11

hbekel,

I'm a great fan of your apps ...

Now I rewrite all my wm keybindings with xchainkeys to be wm agnostic ^_^

For xchainkeys, I miss a feature to choose my notify / feedback app.
By defaut it use the internal feedback but I wanted to send info to my notify app (like dunst, dzen ...).

Thanks.

Last edited by mentat (2012-06-14 16:33:07)

Offline

#4 2012-08-23 06:17:46

chickenPie4tea
Member
Registered: 2012-08-21
Posts: 278

Re: xchainkeys - chained keybindings for X11

can you give a link so you can get it if you dont use Arch ? I am using Crunchbang
Never mind I got it from the link, thanks, cant understand why I cant find it in synaptic in Crunchbang - going to ask why not on their forum.

Last edited by chickenPie4tea (2012-08-23 06:48:06)


You can like linux without becoming a fanatic!

Offline

#5 2012-08-27 22:42:31

quigybo
Member
Registered: 2009-01-15
Posts: 220

Re: xchainkeys - chained keybindings for X11

Excellent utility, very useful, thanks a lot.

It seems to bork on font names with spaces in them though. Eventually I would like to get something like DejaVu working, but I'm afraid to ask whether it has/you plan to add freetype support?

/me wonders whether hbekel is still around and/or this is still maintained?

Offline

Board footer

Powered by FluxBB