Friday, 12 August 2011

Putting Your Screen to Sleep with Hot Corners in Ubuntu 11.04

A college lecturer introduced me to Red Hat 7.1 in 2001. From then on, I was intrigued by the flexibility of Linux and the community behind it. For a long time now I've wanted to use Linux exclusively as the operating system of choice for my home computer. In 2007, I felt that Linux wasn't quite there as a Desktop OS, so I splashed out on a Macbook.

Having a UNIX base, I was pleased with OSX and I'd gotten used to some of its nicer features. One of my favourite features was Hot Corners. Hot Corners are where an action happens as a result of moving the mouse pointer to a certain area of the screen (usually one of the four corners). Typical actions are Lock Screen, Start Screensaver and Show Desktop. Having a laptop, I found it particularly useful to be able to use a Hot Corner to put my screen to sleep in order to save power if I left it for a few minutes.

I recently bought a ThinkPad W520, wiped Windows 7, and installed Ubuntu 11.04 (Classic Gnome). ThinkPads are renowned for having most, if not all of their hardware supported out of the box by Linux, so a ThinkPad was a no-brainer. Much to my disappointment however, Hot Corners are not available by default in Ubuntu 11.04

After doing a little digging around on Google, I found that it was a two-part solution. First I needed to install the brightside package, which is available in the repositories:

sudo apt-get install brightside

Once brightside is installed, open its preferences panel through the Run Application dialog (Alt+F2):

By default, brightside does not have a "Sleep Screen" action, but it does have a "Custom" action which can execute an arbitrary script.

Add /etc/acpi/ to the "On entering region" field and leave all other settings as they are, then click "Close".

With that, it should work! Move your mouse to the assigned Hot Corner to try it out. One final thing to remember is to add brightside to the list of start up application. Go to System >> Preferences >> Startup Applications >> Add and put in the following details.

1: []
2: []

1 comment:

  1. I've used Brightside through three Ubuntu versions on four different machines: two laptops and two desktops. The one thing I've noticed about it that I don't like is, if you leave your screensaver running for any length of time, it prompts for your user password when you move your mouse to dismiss it. As the icon on that dialog box is the one for Xorg, I'm presuming that's where the author got the code. It's too bad there couldn't be a "lockout-free" version of this utility. I'm decidedly DIS-inclined to have to log in anywhere twice. *G*