Powered By

Powered by Blogger

Tampilkan postingan dengan label lock keys. Tampilkan semua postingan
Tampilkan postingan dengan label lock keys. Tampilkan semua postingan

Senin, 10 Januari 2011

Get Caps / Num / Scroll Lock Keys NotifyOSD Notifications Using Compiz And A Script

lock keys notifications

Using this tweak you will get NotifyOSD notification bubbles when the caps lock, num lock or scroll lock status changes (you press a lock key).


One way of getting NotifyOSD notifications when you press the Caps Lock, Num Lock and Scroll Lock keys is using Indicator Keylock - which displays the lock keys status using both NotifyOSD and an appindicator.

But if you only want NotifyOSD notifications, you can do this without installing Indicator Keylock - by using a patched NotifyOSD provided by Leolik, a script and Compiz. This is a tweak Antoni "Pinguy" is using in his latest Pinguy OS 10.10 and he shared this tip with us so you can use it even if you don't want to install Pinguy OS.


How to set up and use the Lock Keys script

1. Optional: install the patched NotifyOSD we've talked about a while back - this makes the notifications respect the timeout passed by the script. Without this package, the notifications will be displayed for 10 seconds which is annoying in some occasions.

sudo add-apt-repository ppa:leolik/leolik
sudo apt-get update && sudo apt-get upgrade
sudo apt-get install libnotify-bin
pkill notify-osd

2. Download the script from HERE and save it somewhere on your system (like a "scripts" folder in your home directory for example). Then right click the file, select "Properties" and on the "Permissions" tab, check the "Allow executing file as program" box.

3. Make sure you have CompizConfig Settings Manager installed:
sudo apt-get install compizconfig-settings-manager


compizconfig settings manager commands tab

Go to System > Preferences > CompizConfig Settings Manager, enable the "Commands" plugin (if not already enabled) and on the commands tab, for 3 empty command boxes, enter this:

/path/to/lock_keys caps
/path/to/lock_keys num
/path/to/lock_keys scrl

In the above commands, replace "/path/to/lock_keys" with the exact path to where you've save the lock_keys script (downloaded in step 1).

4. On the same CompizConfigSettings Manager Commands plugin, go to the "Key Bindings" tab and for the "Run command X" corresponding to each command enter under step 3 press the "disabled" button, then press "Grab key combination" and press the key corresponding to the command (caps, num or scroll lock). When assigning a key such as Caps Lock, Num Lock or Scoll Lock, after pressing the key, press ENTER or else Compiz will not assign the key and will wait to press some more keys!

Compizconfig settings manager key bindings

And you're done!



Thanks to Antoni "Pinguy" for the script tip! Script credits: red_five and excedio

Kamis, 15 Juli 2010

Indicator Keylock Displays The Keyboard Lock Keys On Machines Without Keyboard LEDs

indicator keylock


Indicator-keylock is one of those tiny but extremely useful applications. Like the name says, it's an appindicator for viewing the status of the keyboard lock keys for machines which don't have keyboard LEDs like netbooks or even laptops. That means that you can quickly see if Caps Lock, Num Lock or Scroll Lock is turned on/off even if your machine doesn't have a keyboard LEDs to indicate this.

To install Indicator Keylock in Ubuntu, simply use the following commands:
sudo add-apt-repository ppa:tsbarnes/indicator-keylock && sudo apt-get update
sudo apt-get install indicator-keylock

Once installed, start it by pressing Alt + F2 and then entering: "indicator-keylock".


Indicator Keylock also comes with Mono, Elementary and Humanity icons which you can install using the following command:
sudo apt-get install indicator-keylock-ubuntu-mono indicator-keylock-humanity indicator-keylock-elementary


Update: Indicator Keylock now also display NotifyOSD notifications on lock keys change!



Thanks to Timothy Scott Barnes for the tip!