How to disable Ctrl Alt M in Eclipse? - eclipse

When in a Java editor in Eclipse, pressing Ctrl+Alt+M inserts a new line (like hitting the enter key). How can I disable that? I did not find any corresponding entry in Preferences > General > Keys.
The same happens if I press Alt Gr+M (generally, Alt Gr seems to be the same as Ctrl+Alt in many cases).
Is there some other place where you can see/disable/change key shortcuts in Eclipse (or plug-ins?)

#msa, Go to : Window --> Preferences --> General --> Keys. Now type Ctrl+Alt+M in the search box. You will find a command named as "Add Memory Block" & an option below that "Unbind Command". Select the command & press the button. Now Click on "Apply" button & you're done.

In my case, it unbinds when binding it to another command (for example, maven install) when in Windows.

As stated by RAS, you can unbind the key combination functionality through eclipse preferences - > General -> Keys . Here's a screenshot for easy reference.

Related

Is there a hotkey in Eclipse to "Open declared type"?

When hovering over a variable, one can go straight to its definition pressing F3. But what I'm looking for is for a way to go directly to its type definition, which I'm currently doing by pressing CTRL + clicking "Open declared type".
Is there a easier way to do this?
Assign a key stroke for 'Navigate > Open Hyperlink' command via 'Preferences > Keys'. (I use F6)
Now you can use this key stroke instead of using Ctrl+Click to bring up the hyperlink popup.
Not exactly what you are looking for, but this is the best solution I think.
There is another option, using Ctrl+Shift+t. This opens a window where you can look up any type you wish. This becomes a shortcut when you highlight your target, press Ctrl+Shift+t and hit enter. Imho Ctrl+Click is still faster.
If you would like to check any other shortcuts bind keys go to Windows -> Preferences -> General -> Keys
I've always relied on a combination of ctrl+shift+t and the hover options. I never thought of the key stroke assignment. I might try mapping a scroll button click, like opening a link in a new tab.
in Windows > Preferences > Keys
search for Go to Type and assign it a ctrl-f3 or shift-f3 (there is a conflict with ctrl-f3)

Adding Alt + Space shortcut in Eclipse

I am using win7 and eclipse with Aptana plugin for trying some examples on Ruby. But I can't figure out how to add Alt + Space as a shortcut in Eclipse (I want to add it to complete already defined variables). The issue is that when I try to add that combination (Eclipse reads the keys clicked) and the menu window appears in the top left -> it is shown when you hit the Alt key.
Does anyone has a hint how to add the shortcut?
I found similar post, but don't know how and where to add the code there.
Autohotkey, remap Left Alt + Space to Control + Escape
In Eclipse, the code-completion shortcut is Ctrl+Space (it's called Content Assist in Eclipse lingo). Is that what you're looking for?
I'm pretty sure it can be mapped to a different keyboard combination. Open Preferences and navigate to General > Keys and then search for the Content Assist command to re-map.

Eclipse Short Cut: File Search

I have looked and looked but I cannot find a shortcut for "File Search" in Eclipse.
I even downloaded the mousefeed plugin. (It is pretty cool whenever you do something with the mouse. A little popup comes up and tells you how you could have done that with a shortcut. Not super useful but somewhat useful.)

			
				
ctrl + H opens the search dialogue box. Click on customize and check the option 'Remember last used page'. First time you have to select the tab file search and perform a search. After that if you press ctrl + H , it will automatically point to file search tab.
There is none, but if you go to Windows - Preferences - General - Keys, and type File search in the filter text box, you'll then be able to select the File search action, and type your own key binding.
You can change all shortcut keys in eclipse for instance:
Window -> Preferences -> General -> Keys -> search: File Search -> Binding -> *what ever key combination you like.

what's the keyboard shortcut to toggle breakpoint in pydev using eclipse

I think I'm missing the elephant in the room but for the life of me I can't find the keyboard shortcut to setting a breakpoint in eclipse when using the pydev plugin.
Things that I've already tried:
Ctrl + Shift + B: does nothing.
Ctrl + F10: brings up the breakpoint context menu where you can select to add breakpoint, remove etc... I don't want to have to scroll through a menu every time I want to use a keyboard shortcut.. .kinda defeats the purpose of a shortcut.
Clicking on the strip on the left hand side of the code: this is the only way that I'm setting it atm, but I'm rather avoid using the mouse if I can.
I'm using pydev 1.6.1 on eclipse 3.6
EDIT (31/08): In light of the two answers by codedevour and Tao, I've tried editing the shortcut but have had no luck with the new shortcut Ctrl + Shift + Alt + B either. Other shortcuts work. I've also tried changing the "When" drop down from In Windows to 'Pydev editor scope' with no effects.
From what the editor is telling me, there is no conflicts with the breakpoint shortcut.
This is a fresh install on two machines, both windows 7 and it's happened on both machines.
Finally found it!
The answer is here:
http://www.mail-archive.com/pydev-users#lists.sourceforge.net/msg04234.html
In short, shortcuts are not set for all perspectives of eclipse.
Whilst in the pydev perspective, go to Window > Customize perspective > Command Groups Availability > Check breakpoints.
That's it!
I was using the pydev perspective (which is what it switches to when you first create a pydev project) however, breakpoint shortcuts are only available in the debug perspective by default so you need to turn the shortcut on... wow that was so NOT obvious!
Ctrl + Shift + B
If this refuses to work, have a look at Window > Preferences > General > Keys and look for overlayed keys which may shadow this shortcut.
Ctrl + Shift + B works for me and I am using pydev 1.6.1 with eclipse 3.6.
Perhaps, you have a conflict with another program? Try change it under menu Window > Preference > General > Keys > Toggle Breakpoint to another keyboard shortcut.
On recent pydev versions:
Go to Window > Perspective > customize perspective...
And in tab "Action Set Availability", check "Breakpoints"

Eclipse C++: How do you quickly switch between header and implementation files?

How do you switch between header (.h) and implementation files (.cpp) in Eclipse when using the C++/CDT environment with a keyboard shortcut?
In XCode you can quickly switch between headers and implementation with applekey option and up/down arrow keys. I was hoping that eclipse had something similar, but I haven't found it yet.
Ctrl + Tab.
See in menu Window --> Preferences --> "General" category (far left) --> Keys --> "Toggle Source/Header"
Ctrl + Tab is the default shortcut and here is a list of some of the more useful shortcut keys in Eclipse.
Ctrl + Tab is the default shortcut. You can change it in Window->Preferences->General->Keys - Toggle Source/Header
F3 to jump between declarations and definitions of specific methods
This is another good one to know in this context:
double click on the method name with the mouse, selecting it
hit F3 (shortcut for Right Click > Open Declaration)
This takes you from the declaration (.hpp) to definition (.cpp) and vice versa depending on which one you are currently in, which is useful if you want to go to the other file to see a specific method when the file is large.
Tested in Eclipse CDT 2019-09.
You can also Ctrl + click on an identifier ( method name of member,... ). That way you seldomly need Ctrl + Tab.