hotkeys.py

Hotkeys management. Requires “gi” package and “Gtk” & “Keybinder” modules.

class clay.hotkeys._HotkeyManager[source]

Manages configs. Runs Gtk main loop in a thread.

__init__()[source]

x.__init__(…) initializes x; see help(type(x)) for signature

__weakref__

list of weak references to the object (if defined)

_parse_hotkeys()[source]

Reads out the configuration file and parse them into a hotkeys for urwid.

_parse_x_hotkeys()[source]

Reads out them configuration file and parses them into hotkeys readable by GTK.

static _to_gtk_modifier(key)[source]

Translates the modifies to the way that GTK likes them.

fire_hook(key, operation)[source]

Fire hook by name.

initialize()[source]

Unbind previous hotkeys, re-read config & bind new hotkeys.

keypress(name, caller, super_, size, key)[source]

Process the pressed key by looking it up in the configuration file

clay.hotkeys.report_error(exc)[source]

Print an error message to the debug screen