简体   繁体   English

如何在IntelliJ中查看类包类型和参数?

[英]How to view class package type and parameters in IntelliJ?

When hovering your mouse over a Class or variable, how come I don't see any information on the type of the class? 将鼠标悬停在类或变量上时,为什么我看不到有关类类型的任何信息?

Is this not a feature in IntelliJ? 这不是IntelliJ的功能吗?

For example, in vs.net, if I mouse over any variable or class it will popup and tell me what namespace that belongs to etc. 例如,在vs.net中,如果我将鼠标悬停在任何变量或类上,它将弹出并告诉我属于哪个命名空间等。

And when I am using a method of a class, it also tells me the different overloads for the method (like types for each parameter, and a list of all the overloads). 当我使用类的方法时,它还告诉我方法的不同重载(比如每个参数的类型,以及所有重载的列表)。

This must be a feature in IntelliJ, I just don't know how to get it. 这必须是IntelliJ中的一个功能,我只是不知道如何获得它。

Can someone please clear this up? 有人可以清楚这个吗?

Also, how can I tidy up the formatting of a page? 另外,我如何整理页面的格式?

It doesn't work on hover yet, please star/vote the issue . 它暂不起作用,请为此问题加注星标/投票

You need to use keyboard shortcuts for quick documentation pop-up or parameter info pop-up ( Ctrl + Q and Ctrl + P with default Windows keymap, F1 and Cmd + P with default OS X 10.5+ keymap). 您需要使用键盘快捷键进行快速文档弹出或参数信息弹出( Ctrl + QCtrl + P使用默认的Windows键盘映射, F1Cmd + P使用默认的OS X 10.5+键盘映射)。

Code | Code | Reformat Code... is the answer to your second question. Reformat Code...是您第二个问题的答案。

Formatting: Code -> Reformat (shortcut: Ctrl-Alt-L ) 格式化: Code -> Reformat (快捷键: Ctrl-Alt-L

Hover doesn't produce the kind of information I'd like either. 哈弗不会产生我想要的那种信息。 You can get info with Ctrl-Q ("Quick Help") in Windows or F1 in OS X, which will show where it's from and what it is, with most stuff in the popup window linked up in a reasonable way. 您可以使用Windows中的Ctrl-Q (“快速帮助”)或OS X中的F1获取信息,这将显示它的来源和内容,弹出窗口中的大多数内容以合理的方式链接。

That popup view can also be pinned and/or docked; 该弹出视图也可以固定和/或停靠; I often have it docked on the bottom. 我经常将它停靠在底部。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM