Boost Your Productivity: Essential IntelliJ IDEA Settings, Tips, and Shortcuts
This guide walks you through the most useful IntelliJ IDEA configurations, practical usage tips, and a comprehensive list of keyboard shortcuts, helping you streamline development, reduce memorization effort, and work more efficiently with the IDE.
Common Settings
After reinstalling IntelliJ IDEA, configure:
Theme and font: set to Dark via Settings → Appearance & Behavior → Appearance.
Editor font size via Settings → Editor → Font.
Global and project file encoding via Settings → Editor → File Encoding.
Code templates via Settings → Editor → File and Code Templates.
Keymap customization via Settings → Keymap.
Shortcut Modifications
Copy current line: original Ctrl + D, changed to Ctrl + Alt + ↓ (reason: does not follow operation logic).
Delete current line: original Ctrl + Y, changed to Ctrl + D (reason: does not follow operation logic).
Move line up/down: original Alt + Shift + ↑ / ↓, changed to Alt + ↑ / ↓ (reason: key combination too complex).
Basic code completion: original Ctrl + Space, changed to Alt + / (reason: conflicts with input‑method shortcuts).
Usage Tips
IDEA provides left, middle, and right toolbars; any operation shown there can be used without memorizing a shortcut.
Core navigation is Search Everywhere (double‑press Shift) to search files, classes, actions, and settings.
To locate an action or shortcut, use Search → Action.
When editing MyBatis mapper.xml files and SQL suggestions are missing, add a MySQL data source via Database → Data Source → MySQL.
If certain tags lack suggestions, inject the language or reference MySQL to resolve the issue.
Selecting code shows a floating toolbar with quick actions such as surround, extract variable, and reformat.
Common Shortcuts
Global search (files/classes/actions/settings): Shift + Shift (double‑press) – Navigate → Search Everywhere.
Search class: Ctrl + N – Navigate → Class.
Find action (execute command): Ctrl + Shift + A – Help → Find Action.
Go to declaration: Ctrl + Left‑Click – Navigate → Declaration.
Show implementations: Ctrl + Alt + B – Navigate → Implementation.
Find usages: Alt + F7 – Edit → Find Usages.
Navigate back/forward: Alt + ← / → – Navigate → Back / Forward.
Go to line: Ctrl + G – Navigate → Line….
File structure (current file method list): Ctrl + F12 – Navigate → File Structure.
Basic code completion: Ctrl + Space – Code → Completion → Basic.
Smart code completion (type matching): Ctrl + Shift + Space – Code → Completion → Smart.
Intention actions / import class: Alt + Enter – Right‑click → Show Context Actions.
Reformat code (current file): Ctrl + Alt + L – Code → Reformat Code.
Comment / uncomment line: Ctrl + / – Code → Comment with Line Comment.
Comment / uncomment block: Ctrl + Shift + / – Code → Comment with Block Comment.
Copy current line: Ctrl + D – Edit → Duplicate Line.
Delete current line: Ctrl + Y (no default menu entry).
Move line up/down: Alt + Shift + ↑ / ↓ – Code → Move Line Up / Down.
Undo: Ctrl + Z – Edit → Undo.
Redo: Ctrl + Shift + Z – Edit → Redo.
Rename (variable/class/method): Shift + F6 – Refactor → Rename.
Column (vertical) editing: hold Alt and drag with left mouse button – Right‑click → Column Selection Mode.
Git commit: Ctrl + K – Git → Commit.
Signed-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
Java Tech Enthusiast
Sharing computer programming language knowledge, focusing on Java fundamentals, data structures, related tools, Spring Cloud, IntelliJ IDEA... Book giveaways, red‑packet rewards and other perks await!
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
