Next Previous Contents

3. Usage

3.1 General Usage

KHotKeys consists of two programs : KHotKeys itself and configuration program. To run it, select System/KHotKeys. To configure the running program, select Settings/Keys/KHotKeys.

3.2 Configuration

Action name

Whatever you want :) ( well, there are some exceptions ... ).

Command to execute/URL to execute/Macro to execute

The command you wish to be executed when the hotkey is pressed. The first one is for shell commands, the second one for any URL's ( such as '/usr/src/linux', '/files/pictures/pic01.jpg', '/root/program.kdelnk' ). Macros are not finished yet.

Window command is not significant/Don't run if window command exists/Don't run if window command exists (regexp)

When the hotkeys is pressed and there is a window with WM_COMMAND property ( it's usually equal to the command or it's empty ) equal to this field, or it matches the regular expression, the command won't be executed and only the found window will be activated.

Window title is not significant/Don't run if window title exists/Don't run if window title exists (regexp)

When the hotkeys is pressed and there is a window with WM_NAME property equal to this field, or it matches the regular expression, the command won't be executed and only the found window will be activated.

Window class is not significant/Don't run if window class exists/Don't run if window class exists (regexp)

When the hotkeys is pressed and there is a window with WM_CLASS property ( window class is usually same for all windows of that application ) equal to this field, or it matches the regular expression, the command won't be executed and only the found window will be activated.

Switch only to window created by this command

If this option is on, only windows created by previous executions of this command are searched.

Hotkey

Press the 'Hotkey' button to change the hotkeys assigned to the actions.

Autodetect

Press this button after you've entered the command. It will execute the command, watch for all windows created and print their properties. Pick the window that belongs to the command ( usually only one window will be displayed ) and press 'Select window'. 'Window command', 'Window title' and 'Window class' will be set to values obtained from the picked window. ( Also don't forget to quit the running application started by the autodetection, it won't be terminated automaticaly ).

3.3 How to run it

KHotKeys does not have session management, so you have to start it somehow. The easiest thing is to put it in the Autostart folder ( drag&drop from /opt/kde/bin or 'ln -s /opt/kde/bin/khotkeys  /Desktop/Autostart' should work, assuming KDEDIR is /opt/kde )


Next Previous Contents