Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I use way too many tabs, and use ctrl-w to close tabs so much that it's bad for my wrists in a carpel tunnel way. Is there any way to map closing of tabs to a single key (e.g. the escape key) to avoid that?

Using native key remapping or some google chrome extension?

Edit: Clarification, I'm aware that a single key necessarily will overlap some functionality, but I don't see a way around it because using the dynamic multi-key combinations causes twisted hand positions that exacerbate carpel tunnel. I explicitly don't need the "stop this tab from loading" functionality, at least not in the form of the key, since I can click the icon.

I'm looking for a solution simple enough that it will replace my muscle memory impulse to use ctrl-w, since that has turned out to be so bad on my hands, preferably without leaving home row, since that is when I habitually try to use ctrl-w.

When I'm actually using a full fledged mouse, the "middle-click-tab-to-close" works well enough, but on a trackpad, using the keyboard for this continually necessary task is preferable.

Update: Tried the keyboard shortcuts extension here: https://chrome.google.com/extensions/detail/mgjjeipcdnnjhgodgjpfkffcejoljijf but I couldn't find any single keys results that worked.

share|improve this question
    
I'm looking for a AutoHotKey alternative for Ubuntu, but I can't really find any :-( –  Ivo Flipse Mar 31 '10 at 20:27
1  
Autokey is the best choice. Or autohotkey running on wine. –  Bruce Connor Apr 1 '10 at 0:48

4 Answers 4

up vote 2 down vote accepted

I'd suggest using Mouse Gestures (via an extension) instead

In example you could use the following gesture to close tabs:

alt text

And you even get to add your own gestures if you want:

alt text

share|improve this answer
    
Clarified in my original post, I have the "middle-click-to-close-tab" option is alright when I'm using a mouse, but not especially accessible when using laptop & mainly keyboard with minimal trackpad use. –  Kzqai Mar 31 '10 at 22:36
    
I guess there isn't a multi-touch gesture for trackpads (to distinguish between normal scrolling). Guess you can't stop using a trackpad... –  Ivo Flipse Apr 1 '10 at 5:23

I wouldn't recommend it. Single key commands would work if you also weren't required to type also. For example, in Photoshop single key commands are only disabled while in text mode, but that's it.

I think you'd find it hard to use or difficult to implement correctly. For example, what happens when you hit the Esc key to escape out of a dialog? Should it close the tab, close the dialog, both?

My recommendation is find a mouse or other peripheral that allows you to map key strokes to a key, and use a middle click to issue the Ctrl+W command. I'm not sure what options are available on Ubuntu, but most Logitech mice have options for Windows and OS X.

share|improve this answer
    
Clarified question. The mouse is a good solution, but only really when it's available. And since this is a browser-only problem, it seems like a workable extension might solve this problem if I could find one that actually allowed the functionality. –  Kzqai Mar 31 '10 at 22:40

How about use "Sticky Keys" or whatever Ubuntu calls its equivalent? Should be under your "control panel", look for something that mentions "Accessibility". Basically it lets you press "ctrl+w" as two different keystrokes. So press & release "ctrl", then press & release "w", and it sends "ctrl+w" to the application.

share|improve this answer

With the app Autokey you can map any frase or key combination to other key strokes. That way you could map the C key to ctrl-W, so every time you press C, you'll get Ctrl-W instead. You can also set a condition so that it only works while chrome is the active window, so it won't affect the berravior of other applications. The app's interface is pretty intuitive, you should take a look.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.