Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a shortcut to go to the beginning/end of a file in IntelliJ?

I often need to get quickly to the very beginning or very end of a file in the IntelliJ editor. Is there a shortcut key or button that allows me to do this quickly?

I am running on Windows, if that matters.

like image 460
user697911 Avatar asked Oct 12 '17 17:10

user697911


People also ask

How do I go to previous point in IntelliJ?

To navigate backwards, press Ctrl+Alt+Left . To navigate forward, press Ctrl+Alt+Right . To navigate to the last edited location, press Ctrl+Shift+Backspace .

What is Ctrl Shift O in IntelliJ?

In Eclipse, you press CTRL + SHIFT + O “Organize Imports” to import packages automatically. For IntelliJ IDEA, if you press CTRL + ALT + O “Optimize Imports”, it just removes some unused imports, never imports any package.

What is Ctrl h in IntelliJ?

Ctrl + H = "Type Hierarchy" view = shows a tree of parent and child classes of this class. Ctrl + Shift + A = "It does a search as you type through all the commands in intellij. Not only that but when you find the command you want it also displays the corresponding shortcut key next to it!"

How do you go to the beginning of a line in IntelliJ?

There are shortcuts for this in IntelliJ IDEA! Simply hit Shift+Enter to start a new line below the current line or Ctrl+Alt+Enter (⌥⌘Enter on Mac) to start a new line above the current line.


3 Answers

Beginning of File: Fn + +

End of File: Fn + +


Note: This answer was posted prior to windows specificity. Leaving it here to include MacOS alternative.

like image 128
chazsolo Avatar answered Sep 21 '22 07:09

chazsolo


On Windows, you can use Ctrl+Home and Ctrl+End to go to the beginning and end of a file respectively.

like image 33
nyvokub Avatar answered Sep 24 '22 07:09

nyvokub


The action is called Move caret to Page Top/Bottom, default shortcuts would depend on the OS/Keymap and can be checked here:

top

On Windows these are Ctrl+Page Up and Ctrl+Page Down.

like image 37
CrazyCoder Avatar answered Sep 23 '22 07:09

CrazyCoder