128
votes

How to enable "Scroll from source" in IntelliJ IDEA so it is always on, meaning if you open any file it is automatically shown in Project view, likewise it is made in Eclipse?

There is a possibility to click the button in Project to find chosen file, but it is annoying to click it each time you open another file.

4
Now it's called "Always Select Opened File". In case someone else stares at the IntelliJ project menu for minutes like me.Gazihan Alankus

4 Answers

199
votes

You can check Autoscroll from source in setting for project pane (in the lastest version is probably different icon)

enter image description here

35
votes

Unfortunately this setting must be ticked every time you open or create a new project.

If you would like this setting to persist between projects, you can use this plugin:

AutoScroll Save IntelliJ Plugin

Disclaimer: I am the plugin author.

9
votes

From version 2019.3.1, the name of the options have been changed as below:

Autoscroll to Source -> Open Files with Single Click

Autoscroll from Source -> Always Select Opened File

The credit will go to this post. Hope it helps.

0
votes

I'm using 2019.3 and I could not find the gear icon, or Autoscroll or Open Files in the Settings.

Here's what I did instead, after 30 minutes of searching.

  1. Right click on the Project
  2. Enable "Open Files with Single Click"

enter image description here