Friday, April 15, 2011

Global Hotkeys

Ever wondered how many key combinations our keyboards (assume a 101 key keyboard) have and what all we can do with those?

The answer to the first part of the question - I leave it to you guys to answer.
My answer to the second part - A LOT!

For the benefit of those who don't know what global hotkeys are, these are key combinations assigned to perform a task in an application. Just like Ctrl + Alt + Delete. Another example, I'm currently using the browser and I want to switch to the next track in my music player. A simple Ctrl + Alt + Right Arrow does it for me. It avoids the arduous task of going to the music player and switching to the next song and returning to the browser. Got the hang of it? Good.

If there's a way to assign custom keys to various tasks in various applications, wouldn't that be cool? Now add mouse input to this. Even cooler. Add touch to it. Add speech to it. Add any other input mechanism you can think of to it. Too complicated now? That's ok. You'll get used to it. You'll be amazingly productive on the computer thereafter.

AFAIK, there doesn't exist a tool through which you can assign shortcuts for tasks from various applications even for the keyboard. Such a tool would a super cool tool in my eyes.

PS: Quite an off-topic post probably? Just wanted to let people about global hotkeys if they haven't heard of them.

8 comments:

  1. Thinking on the lines of implementation. Touch I think is too hardware dependent (at least as of now. Or Maybe it's easier to do on iPads). Speech is a bit easy to do. But needs a lot of background computation to recognize every fart noise in the surroundings and identify the right fart and act accordingly (Hope you guys understand the fart metaphor).
    Dream Input mechanisms for me:
    1. I would love to have an iPad type monitor and just scribble on the screen for anything and everything. (Just a great substitute for command lines. Instead of remembering commands, we remember our customized touch inputs)
    2. I would really love to gesture or clap or sigh onto the monitor. Wouldn't it be great?

    ReplyDelete
  2. In ubuntu, global keyboard shortcuts are assignable in more than one way. "Desktop | Preferences | Keyboard Shortcuts" is one and gconf-editor is another.

    I searched a bit for windows but found none :( Will be super useful there...

    ReplyDelete
  3. And minirity report movie style gesture recognition is possible with special hardware called "Kinect". Search for "kinect gesture recognition" and you'll get many videos...

    ReplyDelete
  4. @Praapi : I guess a lot of us know about Ubuntu Global keys. (Amarok users at least). I was talking about feasibility too. On a desktop or a phone or on a device like ipad, I don't think we can write an app and use Kinect with it? Or can we?

    ReplyDelete
  5. @Sunny: We can. That's what kinect does. Connect a kinect to a pc, and use gestures to control the pc. Since kinect has excellent voice support (a array of microphones which can detect any fart in a room, in your terminology), sound control is also possible. There are only rudimentary apps as of now (but there are many of them).

    One such app: http://kinecthacks.net/kinect-controlling-apps-on-windows-7/ which does the standard mouse operations with gestures.

    ReplyDelete
  6. I didn't know of the existence of such a utility in Ubuntu. I'll try it out very soon. But I doubt if it has the ability to control tasks within an application. For instance, I'm writing code in emacs and with a key combo I want to open a new tab in my browser (an application that doesn't support global hotkeys).

    ReplyDelete
  7. "System | Preferences | Keyboard Shortcuts" works on Ubuntu. I use it all the time - making use of the otherwise useless "Windows" key on the keyboard.

    And, voice commands for Android are there from about 2 yrs ago: http://googlemobile.blogspot.com/2010/12/voice-search-gets-personal.html
    http://googlemobile.blogspot.com/2010/08/just-speak-it-introducing-voice-actions.html

    Even if this doesn't work, beating it there is not our core competency... So, gestures without Kinect is your best bet if you are planning an app in this space IMO.

    ReplyDelete
  8. @ praapi, there is an app called autohotkey in windows too. Using that, u can assign global hotkeys to start/ kill applications like browser/ music player. i believe it has more than just start kill apps. to tap its potential, you should learn how to use it. you have to write some script to use it

    ReplyDelete