in pycharm, how to go back to last location

2019-02-04 04:17发布

i've tried these answers, but nothing happened:

Keyboard shortcut for Jump to Previous View Location (Navigate back/forward) in IntelliJ Idea

for example:

  1. i'm navigating to a function body,
  2. put the cursor on a function call,
  3. click F12 ("go to definition")
  4. from the new location (the function's body), how do I return to the function call?

i've tried these, but they didn't do anything:

  • ctrl-shift-left
  • ctrl-shift-F2 <-- this is my default mapping
  • alt-shift-left
  • ctrl-shift-backspace
  • don't try that on linux: ctrl-alt-backspace

or maybe F12 ("go to def") isn't "strong enough" to trigger a location-change event??

标签: pycharm
9条回答
forever°为你锁心
2楼-- · 2019-02-04 04:38

In mac OS X (atleast in El Capitan) it is cmd + [ to go back to the previous location.

查看更多
我只想做你的唯一
3楼-- · 2019-02-04 04:39

Search for Back in the Settings ‒> Keymap, click on it and change it for what you want ‒ should help on all systems.

I use Ubuntu so the default was Ctrl + Alt + Left, but this combination is already in use by the system.

查看更多
甜甜的少女心
4楼-- · 2019-02-04 04:41

In Ubuntu Ctrl+Altr+Left is overridden in for switching to left workspace. I don't use workspaces at all so I cancelled that shortcut in System Settings -> Keyboard -> Shortcuts -> Navigation -> Switch to workspace left.

查看更多
登录 后发表回答