在Eclipse中,当鼠标悬停在一个方法、变量等上时,会显示一个带有相应JavaDocs的工具提示。IntelliJ中有这样的特性吗?


当前回答

文件- >设置- >编辑器

选中“在鼠标上显示快速文件”

现在,当您将鼠标放在一个方法上时,将出现一个带有文档的工具提示。有时工具提示的大小太小,你将不得不调整它移动鼠标到工具提示的底部。

其他回答

在Mac上的IntelliJ U上,我需要用光标指向一些方法,变量等,然后按[cntrl]或[cmd]键。然后点击弹出窗口中的链接,弹出窗口中出现了JavaDocs

从IntelliJ Ultimate 2018.1.5,也就是IntelliJ IDEA 2018.1.5,到2019.3,在File -> Preferences下实际上有两个选项:

In Editor > General > Other (section) > Show quick documentation on mouse move - delay 500 ms Select this check box to show quick documentation for the symbol at caret. The quick documentation pop-up window appears after the specified delay. In Editor > General > Code Completion (sub-item) > Auto-display documentation in 1000 ms Select this check box to have IntelliJ IDEA automatically show a pop-up window with the documentation for the class, method, or field currently highlighted in the lookup list. If this check box is not selected, use Ctrl+Q to show quick documentation for the element at caret. Quick documentation window will automatically pop up with the specified delay in those cases only, when code completion has been invoked explicitly. For the automatic code completion list, documentation window will only show up on pressing Ctrl+Q.

Android Studio(至少2.3.3)用户注意,因为这个页面出现在我的谷歌搜索“Android Studio hover javadoc”,Android Studio是基于Intellij:

参见文件->设置->编辑器->通用:“显示鼠标移动的快速文档”, 而不是文件->设置->编辑器->通用->代码完成 用于显式调用补全的(ms)自动操作文档 以及“(ms)自动操作”,之前已经讨论过。

在mac IntelliJ终极(试用)14我有我的设置>编辑器>一般>代码完成。我笔记本电脑上的工具提示是F1。

它被称为“自动opup文档(毫秒):”

在IntelliJ版本11之前,不,不仅仅是将鼠标悬停在它上面。如果光标在方法名或属性名内,那么CTRL+Q将显示*nix和Windows上的JavaDoc。在MacOSX上,按CTRL+J。

引用:“不,查看完整javadoc的唯一方法是使用Quick Doc (Ctrl-Q)。”——http://devnet.jetbrains.net/thread/121174

EDIT

从IntelliJ 12.1开始,这是可能的。请看@ADNow的回答。