3

Consider this simple class:

package net.zomis.test;

public class Test {
    public Test() {

    }

    public void registerSomething(String key) {

    }

}

When I have the cursor placed right before registerSomething and pressing CtrlShift, I'm used to Eclipse only selecting register at first. But now, it selects the entire registerSomething text, when I press it again it selects the entire method (from public void to }), when I press it again it selects the entire class, and the last time the entire file is selected. The exactly same thing happens if I press CtrlShift.

Also, when I simply click the End key, I get an option to choose: Line End or Text End.

What has gone wrong in my settings for this to happen? Where can I find these keybindings?

If it matters, I have this workspace within my Dropbox-folder to synchronize it between my PC and Mac.

Georg Schölly
  • 124,188
  • 49
  • 220
  • 267
Simon Forsberg
  • 13,086
  • 10
  • 64
  • 108

2 Answers2

7

Turns our that the fact that I had the workspace in my Dropbox folder matters a lot. Note to everybody else: Do not share your workspace between computers. How I solved this is the following:

  • Create a new workspace on each computer
  • In the computer-specific workspace, import projects from your shared Dropbox/other folder

I noticed that when having a shared workspace on the computers, the Mac somehow changed the key-bindings to the Mac-version, which made them not work on the PC. The correct Ctrl+Shift+ key-binding on Mac is Alt+Shift+.

So by using a separate workspace on each computer, I can use that computer's specific key-bindings, without mixing them up.

Naveed S
  • 5,106
  • 4
  • 34
  • 52
Simon Forsberg
  • 13,086
  • 10
  • 64
  • 108
5

Open the preferences dialog from the Main Menu: Window->Preferences.

In the dialog, open General->Keys. You'll see a table of keybindings, with a field with type filter text. In that field, type: Ctrl+Shift+Right, and you'll narrow the table down to this key.

The behavior that you expect - only register is selected with the first keypress - is the behavior that I see when using Ctrl+Shift+Right, and the keybinding for me is: Select Next Word.

There is a Restore Command button that should reset this binding if it has been changed.

pb2q
  • 58,613
  • 19
  • 146
  • 147
  • Many thanks for this, it turns out that my key-bindings was screwed up by sharing the workspace with the Mac, see my answer below. Your answer helped me find the correct key-binding for Mac! – Simon Forsberg Sep 14 '12 at 13:45