Bug 469861 - Provide IntelliJ keybindings for Eclipse to ease the pain for IntelliJ users coming to Eclipse
Summary: Provide IntelliJ keybindings for Eclipse to ease the pain for IntelliJ users...
Status: CLOSED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.5   Edit
Hardware: PC All
: P3 normal with 2 votes (vote)
Target Milestone: ---   Edit
Assignee: Platform-UI-Inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords: helpwanted
Depends on:
Blocks:
 
Reported: 2015-06-10 12:22 EDT by Lars Vogel CLA
Modified: 2020-03-03 20:13 EST (History)
9 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Lars Vogel CLA 2015-06-10 12:22:38 EDT
For Android developent I had to switch to Android Studio. One of the reasons I hated it initially was that I felt completely helpless, as none of my known shortcuts worked. After discovering that I can configure IntelliJ to use Eclipse shortcuts I discovered a little love for it.

I guess IntelliJ users switching to Eclipse will have a similar experience. To smooth the migration from IntelliJ to Eclipse we should provide an IntelliJ keybinding in Eclipse similar to the Emacs one we already have.
Comment 1 Lars Vogel CLA 2015-06-11 04:12:21 EDT
IntelliJ is welcoming to me in the sense that I can use Eclipse keybindings. We should be as friendly in Eclipse to new users.
Comment 2 Gautier de SAINT MARTIN LACAZE CLA 2015-09-10 17:30:07 EDT
I begin a little work to support this feature. I don't know when I could provide a key binding scheme for IntelliJ. 

I use this google spreadsheet from Xavier Hanin.  https://docs.google.com/spreadsheets/d/1AzLtUCLkUW7_Cog3ZOcF_ASwFQhF8PM2I1cGJtRfPbE/edit#gid=0

The main problem for me is about key binding on gtk platform and carbon platform. I guess that the MacOS column of the spreadsheet is about cocoa platform. 

An other problem is about keybinding for chinese, japanese and korean locales.
Comment 3 Lars Vogel CLA 2015-09-10 17:44:10 EDT
(In reply to Gautier de SAINT MARTIN LACAZE from comment #2)

> The main problem for me is about key binding on gtk platform and carbon
> platform. I guess that the MacOS column of the spreadsheet is about cocoa
> platform. 

I tend to forget Mac stuff, but Eclipse only support the "latest" Mac toolkit. I think that is Carbon.
Comment 4 Gautier de SAINT MARTIN LACAZE CLA 2015-09-11 18:04:02 EDT
Thanks Lars for this information. 

I have one more question. To provide a good IntelliJ keybinding, I think I need to configure keys in these following plugins : 
 - org.eclipse.ui
 - org.eclipse.ui.workbench.texteditor
 - org.eclipse.search
 - org.eclipse.ui.editors
 - org.eclipse.jdt.ui
 - org.eclipse.jdt.debug.ui

Do you know if there is other plugins to configure ?

I hope I will provide a good enough keybinding for Neon M4.
Comment 5 Thomas Schindl CLA 2015-09-14 04:10:25 EDT
[...]

> I tend to forget Mac stuff, but Eclipse only support the "latest" Mac
> toolkit. I think that is Carbon.

No Cocoa!
Comment 6 Lars Vogel CLA 2015-09-14 04:17:05 EDT
(In reply to Thomas Schindl from comment #5)
> No Cocoa!
Thanks.
Comment 7 Gautier de SAINT MARTIN LACAZE CLA 2015-09-14 14:40:35 EDT
Thanks Tom.
Comment 8 Patrick-Jeffrey Pollo Guilbert CLA 2016-06-09 12:50:15 EDT
Is this still being worked on? Coming from IntelliJ I too liked the feature where I could use eclipse shortcuts right from the start.
Comment 9 Patrik Suzzi CLA 2016-06-16 06:17:46 EDT
I agree, We should welcome IntelliJ users, by providing a set of familiar KeyBindings. 

I think there are two general options: 
1. Provide an additional scheme for IntelliJ
2. Provide an Export/Import feature for keybindings.

See: http://i.imgur.com/3p1mNnp.png

As I don't see any import options on "Keys" menu, I suppose the easy way is to add a new Scheme. 

Indeed, in NewKeysPreferencePage, when you change the KeyBinding scheme from the dropdown, a new SchemeElement is set in the KeyController as follows:

SchemeElement scheme = (SchemeElement) ((IStructuredSelection) event.getSelection()).getFirstElement();
keyController.getSchemeModel().setSelectedElement(scheme);

To solve this bug, I think we should manually add mappings to the various plugin.xml, by specifying mappings for the new schemeId. 

As an example see org.eclipse.ui\plugin.xml where are defined bindings for emacs. Below you see how a single keybinding is defined: 

      <key
            commandId="org.eclipse.ui.file.close"
            sequence="CTRL+X K"
            schemeId="org.eclipse.ui.emacsAcceleratorConfiguration" />

This solution is not complex, but long to do, and it will increase the size of the plugin.xml

Do you think this is an acceptable solution?
Comment 10 Patrick-Jeffrey Pollo Guilbert CLA 2016-08-30 10:34:18 EDT
(In reply to Patrik Suzzi from comment #9)
> I agree, We should welcome IntelliJ users, by providing a set of familiar
> KeyBindings. 
> 
> I think there are two general options: 
> 1. Provide an additional scheme for IntelliJ
> 2. Provide an Export/Import feature for keybindings.
> 
> See: http://i.imgur.com/3p1mNnp.png
> 
> As I don't see any import options on "Keys" menu, I suppose the easy way is
> to add a new Scheme. 
> 
> Indeed, in NewKeysPreferencePage, when you change the KeyBinding scheme from
> the dropdown, a new SchemeElement is set in the KeyController as follows:
> 
> SchemeElement scheme = (SchemeElement) ((IStructuredSelection)
> event.getSelection()).getFirstElement();
> keyController.getSchemeModel().setSelectedElement(scheme);
> 
> To solve this bug, I think we should manually add mappings to the various
> plugin.xml, by specifying mappings for the new schemeId. 
> 
> As an example see org.eclipse.ui\plugin.xml where are defined bindings for
> emacs. Below you see how a single keybinding is defined: 
> 
>       <key
>             commandId="org.eclipse.ui.file.close"
>             sequence="CTRL+X K"
>             schemeId="org.eclipse.ui.emacsAcceleratorConfiguration" />
> 
> This solution is not complex, but long to do, and it will increase the size
> of the plugin.xml
> 
> Do you think this is an acceptable solution?

I think modifying the different plugin.xml would be acceptable, as like you said, this seems to be the way the emacs keybindings are made. I don't think plugin.xml sizes are really a concern.
Comment 11 Patrick-Jeffrey Pollo Guilbert CLA 2016-10-05 10:27:36 EDT
After thinking a bit on it I think maybe adding an import option would be better. Cluttering up the plugin.xml might not be such a good idea, as there may be other schemes we want to add in the future. 

Correct me if I'm wrong, but at the moment there's only an option for exporting the current keymap right? So the only way to get the same preferences would be via Oomph (preference recorder, although I'm not sure it saves the keys) or via a preference file (same problem, not sure if keys are saved inside it)?
Comment 12 Josef Lehner CLA 2017-12-10 12:14:45 EST
Are you still working on it?

As I want this feature, I created a new plugin and pushed it to GitHub: https://github.com/IntelliJIdeaKeymap4Eclipse/IntelliJIdeaKeymap4Eclipse 

Pull requests are appreciated.

As a separate plugin we can get feedback from users earlier. As soon as it is feature complete you can merge it into base Eclipse.

It will be long to do, but if you help me, we can ship the IntelliJ IDEA keymap with Eclipse Photon.
Comment 13 Eclipse Genie CLA 2020-03-03 18:48:57 EST
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug.

If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.