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.

Suppose that I'm writing some text and the caret is in the middle of a word. I would like to be able to select that word without using my mouse. (Using the mouse, simply double-click on the word.)

I have found the following, but it's kind of clunky:

  1. Ctrl + : to go to the beginning of the word
  2. Ctrl + Shift + : to select the whole word

Is there a better way of doing this?

share|improve this question
1  
I think this is the simplest way to do it without a mouse. It's only 2 steps. –  bwall Oct 14 '11 at 14:57
    
It depends on what program you're in. Many editors would have a keystroke for select current word. –  Julian Oct 14 '11 at 15:01
    
@Julian: I'm mostly in Google Chrome, I guess. –  Randomblue Oct 14 '11 at 15:29

4 Answers 4

up vote 5 down vote accepted

On OS X, create a file ~/Library/Keybindings/DefaultKeyBinding.dict with the following content:

{
    "^w" = (selectWord:);
}

If the file already exists, add the second line above within its top-level braces.

Now you can press ^w (Control-W) in any native application (i.e. not Firefox, Eclipse, etc.) to have it select the current word.

You can customize the shortcut, ^ is Control, ~ Option, $ Shift, @ Command.


Some applications include menu items for this action. TextMate, for example, uses the ^w shortcut for Edit » Select » Word by default.

share|improve this answer
    
This works with Google Chrome. –  Daniel Beck Oct 14 '11 at 17:53

There is a better way. AutoHotkey.

http://www.autohotkey.com/

Or if you are in Visual Studios, Ctrl W selects the whole word.

share|improve this answer
    
How'd you configure AutoHotkey to make this work? –  Daniel Beck Oct 18 '11 at 17:53
3  
Visual Studio was what I was looking for, thanks. –  Benjamin Mar 28 '13 at 19:55

In MSWord, press F8 once to enter the extended mode, twice to select the whole word, three times to select the whole sentence, four times to select paragraph and five times the entire document. Press ESC to exit the extended mode

share|improve this answer

This AutoHotKey script maps Ctrl-W to select the word under the cursor:

#IfWinActive ahk_class OpusApp
^W::
SendInput ^{left}+^{right}
#IfWinActive

Tested with Word 2010, should work with other versions as well.

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.