Intellij shows method parameter hints on usage - How to disable it
Need to disable IntelliJ parameter hints? Simply navigate to Settings
> Editor
> Inlay Hints
> Java
. Now, just uncheck the Parameter hints
box, hit apply
, and you've successfully banished those hints.
Keep in mind, these hints can be a blessing for complex function calls.
Deep dive into parameter hints
Wondering what these parameter hints actually are? They are small labels that pop up next to method calls in your code editor - acting as a handy reminder for what each parameter is. While these hints can be a lifesaver with complex code, they can also become an unnecessary distraction.
Hints for specific methods or languages
If you'd like a more customized experience, consider disabling those hints only for specific methods or languages. Thankfully, IntelliJ IDEA allows you to do just that:
- Head over to
Settings
>Editor
>Inlay Hints
. - Pick the language you want to customize (for example, Java).
- Within the settings for that specific language, you can tweak how and when you see hints - opting for more, less, or none at all.
Custom keybindings for hint toggling
Often play hide and seek with hints? Add a shortcut to the game! Just follow the steps below:
- Use
Ctrl+Alt+S
to get toSettings
. - Type in "Toggle parameter name hints" in the
Keymap
search box. - Right-click on the result, select "Add Keyboard Shortcut", and pick your winning combo.
Considerations when disabling hints
While disabling parameter hints can create a neater workspace, recall the times they come in handy:
- Collaboration: Sharing code with others? Hints could offer your teammates a reliable roadmap.
- Learning a new codebase: For beginners or when exploring unfamiliar code, hints serve as useful tour guides.
- Tackling complex functions: For functions with numerous parameters of similar types, knowing what's what is no small feat.
Tips for a hint-free workflow
Once you've waved goodbye to parameter hints, here are some tips to keep up the good work:
- Use Parameter Info (
Ctrl+P
on Windows/Linux,Cmd+P
on macOS) if you miss what a method's parameters are. - Mousing over method calls reveals their docs.
- Naming conventions that are descriptive make missing hints a non-issue.
Was this article helpful?