How to see JavaDoc in IntelliJ IDEA?
To quickly activate JavaDoc in IntelliJ IDEA, position the cursor over any code element and press Ctrl+Q
(or F1
on macOS). This action produces a brief overlay of the JavaDoc. For a persistent view window, press Ctrl+Q
twice. For JavaDoc capabilities for standard classes, attach the JDK source via Project Structure
> SDKs
, and link the src.zip
from your JDK home directory.
Use Preferences
> Editor
> General
> Code Completion
to auto-activate JavaDoc popup on code completion, check the box that says Autopopup documentation
. You can use manual quick documentation to avoid constant pop-ups.
Quick access to JavaDoc
Getting instant access to documentation empowers you to code with greater understanding. There are several ways to access JavaDocs in IntelliJ IDEA.
Keyboard Command: Quick Documentation
Press Ctrl+Q
(Cmd+Q for macOS) to display an immediate overview of the documentation.
Auto JavaDoc Popups: Be spoiled
Want the IDE to spoon-feed you JavaDocs as you type? Enable automatic JavaDoc popups:
Preferences
> Editor
> General
> Code Completion
> Tick Autopopup documentation
box.
On Mouse Move: Stealthy Lookup
Hover the mouse pointer over a code element to sneak a peek at the JavaDoc:
Preferences
> Editor
> General
> Tick Show quick documentation on mouse move
box.
Was this article helpful?