Strange key mapping in Android Studio

允我心安 提交于 2019-11-30 00:35:14

Add this line:

actionSystem.force.alt.gr=true

to this file:

...\Android\android-studio\bin\idea.properties

As written here: http://youtrack.jetbrains.com/issue/IDEA-91975

Yes, well... its problem with "old" keyboards. Newer keyboards don't have Alt Gr keys and IDE doesn't count on this in default.

Solutions:

  1. Buy a new keyboard with no Alt Gr on it (using right Alt instead of Alt Gr is working for me)
  2. Go to File -> Settings -> Keymap and search for implementation - delete Ctrl + Alt + B, hit "Apply" and you can now use this shortcut for "{"
  3. As already mentioned below... add following line to ..\<Android Studio folder>\bin\idea.properties:

    actionSystem.force.alt.gr=true

    (update) Since newer version of AS (not sure which one, should be 2.3.3+), you don't need to manually access the properties file. Go to Help -> Edit Custom Properties and add actionSystem.force.alt.gr=true there.

Go to Preferences -> Keymap and choose Mac OS X as Keymaps.

I have been a long time Visual Studio user, so wanted to leverage all the keyboard shortcuts that I had picked up using Visual Studio.

On Android Studio, I first changed the Keymap to be Visual Studio. You can do this by using Alt+F7 on Windows and then search for Keymap.

By using the Visual Studio Keymap in Android studio, I got only debug related mapping, which was still a minority of what I use in Visual Studio.

So went ahead and added/modified some more mappings. Here is the github link https://github.com/vinayakg/VisualStudioKeymapforAndroidStudio/blob/master/settings.jar.

PR's welcome.

As for '>' sign (AltGr + .) and Android Studio 1.0.1, go to File>Settings, choose Keymap in IDE Settings section, search for "GotoCustomRegion" item (it is located in MainMenu-Navigate) and remove its mapping (via context menu).

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!