Is it possible to preview a file with one click on file name like Sublime Text in Phpstorm?
Asked
Active
Viewed 4,889 times
24
-
2Luckily I have found the answer, here it is: http://stackoverflow.com/questions/11051692/how-to-make-scroll-from-source-feature-always-enabled – Sinan Eldem Sep 10 '14 at 17:11
-
1If by "preview" you mean "open file for editing" then yes -- that's the right solution (sorry, I'm not familiar with Sublime and do not know how it behaves). If you want to actually preview but not open it .. then you will have to use keyboard shortcut for that. – LazyOne Sep 10 '14 at 17:59
-
What is the keyboard shortcut for preview @LazyOne ? – Sinan Eldem Sep 11 '14 at 05:53
-
1Whatever you have there for `View | Quick Definition` – LazyOne Sep 11 '14 at 09:09
-
I see. It is alt+space on mac. Thank you @LazyOne. – Sinan Eldem Sep 11 '14 at 10:49
-
1I have a workaround for this. Go to `Settings | Editor | General | Editor Tabs` and set the `Tab limit` to 1 (Warning, all your tabs will get closed after 'Apply' or 'Ok'). In the Project-Window turn on the option "Scroll to Source". Single click on files will open them in only one editor tab. When you want to keep them, right click on a tab and `Pin Tab` ( I have a shortcut for "Pin active Tab" ). It's not perfect but it's something. – Paul Geisler Nov 12 '15 at 14:11
3 Answers
7
Yes, it's possible but it little bit different from sublime-text.
You can use phpstorm shortcut "Quick Definition", by default on linux:
CtrlShiftI
Select file at project window and press this hotkeys.

cn007b
- 16,596
- 7
- 59
- 74
2
I installed a plugin called Quick File Preview, by Martin Sommer.
I hate having to install plugins for small things like these, but I felt I had to. Having to double-click a file just to see its content can be quite annoying for someone coming from Sublime and VS Code (VSCodium in my case)

murume
- 154
- 1
- 3
- 13
2
Currently, this is natively supported by activating "Enable preview tab" in Editor > General > Editor Tabs > Opening policy.

SlimDeluxe
- 733
- 8
- 18