Note: this wiki is no longer maintained. If you have any questions related to this wiki, please post them on the CrunchBang forums.

Translations of this page?:

DESKTOP Configuring Keybindings

See also DESKTOP The CrunchBang Openbox configuration guide

By default Crunchbang makes good use of keybindings, many of these can be seen in the Conky window on the right of you screen. Keybindings are defined in the ~/.config/openbox/rc.xml file. it can be accessed from the menu in Preferences –> Openbox Config –> Edit rc.xml.

Adding your own tags

You will find the keybindings section about a 1/4 of the way down within the <keyboard></keyboard> tags, they will look something like this:

    <keybind key="W-t">
      <action name="Execute">
        <command>terminator</command>
      </action>
    </keybind>
<keybind key="W-t">
.....
</keybind>

The keybind tags surround a new keybinding, and also define the key combination, in this case the Windows/super key and 't'.

<action name="Execute">
....
</action>

The action tags define what to do, in this case execute something.

<command>terminator</command>

And finally the command tags define what to execute, in this case APPLICATIONS Terminator, CrunchBangs default terminal.

You can simply add your own by copying an existing keybinding and editing the relevant details or you can simply change the key combo, or command of an existing keybinding.

Commands work in the same way as on the terminal, you don't need an '&' suffix like you do in the autostart file.

The official openbox documentation has details on all the options Openbox Keybindings. which even include documentation on bindings for mice.

Finding Key Names

Many PCs will have special keys, such as volume keys, to get their name follow this guide.

this information can be used as your keybind key eg:

<keybind key="XF86AudioRaiseVolume">

Some useful keybindings

Configure any volume keys you may have:

    <keybind key="XF86AudioRaiseVolume">
      <action name="Execute">
        <command>amixer sset Master,0 5+</command>
      </action>
    </keybind>
    <keybind key="XF86AudioLowerVolume">
      <action name="Execute">
        <command>amixer sset Master,0 5-</command>
      </action>
    </keybind>
    <keybind key="XF86AudioMute">
      <action name="Execute">
        <command>amixer sset Master,0 toggle</command>
      </action>
    </keybind>

Other Useful Options

In openbox its possible to chain key combinations together, similar to Emacs, (not to put you off :))Key chains

Links

Platform specific Links

 
configuring_keybindings.txt · Last modified: 2012/05/24 07:47 by machinebacon
Except where otherwise noted, content on this wiki is licensed under the following license:CC Attribution-Share Alike 3.0 Unported

Powered by DokuWiki. Hosted by Linode.
Copyright © 2010 CrunchBang Linux.
Proudly powered by Debian GNU/Linux.
Debian is a registered trademark of Software in the Public Interest, Inc.