Perl script manages keyboard shortcuts

Taking Shortcuts

Article from Issue 173/2015
Author(s):

The Autokey utility automates desktop processes by triggering specific actions when the user enters predefined text shortcuts or presses hotkey combinations. Perl helps to manage these helpers.

Going back five years, I fondly remember the Gnome window manager Metacity launching applications at the press of a keyboard shortcut, simply by adding an entry with the gconf-editor utility [1]. As a heavy terminal user, I probably open about 100 such windows in the course of the day, so it was a great time saver to map the keyboard shortcut Ctrl+Alt+N to a shell script that opened the new terminal with a special font and background color no matter which application the keyboard was currently focused on.

With the Compiz window manager now reigning over the Unity desktop, this capability seems to be a thing of the past, and I'm just fed up of continually modifying my scripts to reflect the changing fashions that desktop frameworks tend to follow.

Middle Man

Instead, in this column, I will be looking to put a man in the middle to handle the interface between the keyboard, the window manager currently en vogue in the Gnome world, and the actions I want to trigger.

[...]

Use Express-Checkout link below to read the full article (PDF).

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy Linux Magazine

SINGLE ISSUES
 
SUBSCRIPTIONS
 
TABLET & SMARTPHONE APPS
Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

comments powered by Disqus
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters

Support Our Work

Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.

Learn More

News