Eclipse 帮助框
我正在使用 Eclipse 来编写 Android 应用程序,我喜欢当您开始输入时出现的小帮助框并向您提供建议。
然而,这种情况只是偶尔发生,我想知道是否有办法让它保持更长时间的可见状态,或者更好的是,我可以按下组合键来调出它。如果我开始输入某些内容,它要么通过建议来帮助我,要么不会出现。
I am using Eclipse to program Android apps and I love how the little helper box thing comes up when you start to type and suggests things to you.
However, this only happens sporadically and I was wondering if there was a way to keep it visible for longer or, even better, a key combo I could press to bring it up. If I start to type something, it either helps me by suggesting things or doesn't appear.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
尝试Ctrl+空格。该功能被称为“内容辅助”、“代码完成”、“自动完成”。在 Visual Studio 世界中,我认为它被称为“Intellisense”。
如果您希望建议立即出现(我更喜欢这样),您可以通过转到 Window → Preferences → Java → 更改延迟>编辑器 → 内容辅助并将自动激活延迟更改为
0
。在我的 Eclipse 版本(Helios for Java EE)中,该字段是倒数第三个。找到此首选项屏幕的一种更简单的方法是使用首选项左上角的搜索框(如前所述,窗口 → 首选项),然后键入
完成
。从那里您可以看到 Eclipse 提供的所有不同的内容辅助首选项。我的有 Java、JavaScript、CSS、HTML、JSP 和 XML - 其中大部分是因为我使用的是更高级的 Eclipse 版本。默认情况下,在编写 Java 代码时,.(句点)键会触发内容辅助的自动激活。您可以在与自动激活延迟相同的屏幕中更改此设置。
Try Ctrl+Space. The feature is known as "content assist," "code completion," "auto-complete." In the Visual Studio world, I think it's called "Intellisense."
If you want the suggestions to appear immediately (I prefer this) you can change the delay by going to Window → Preferences → Java → Editor → Content Assist and change the Auto activation delay to
0
. In my version of Eclipse (Helios for Java EE), that field is third from the bottom.An easier way of finding this preference screen is to use the search box in the upper-left-hand corner of the prefs (as before, Window → Preferences), and typing
completion
. From there you can see all of the different content assist preferences that Eclipse offers. Mine has Java, JavaScript, CSS, HTML, JSP, and XML - most of those because I'm using a fancier version of Eclipse.By default, when writing Java code, the . (period) key triggers auto-activation of content assist. You can change this setting in the same screen as the auto-activation delay.
我认为它是 Control+Space 来完成代码。尝试一下
I think its Control+Space for Code completion. Try that
还可以轻松处理代码完成弹出延迟。不要将其设置为 0,我记得 Eclipse 中有一个奇怪的行为,根本没有弹出窗口。
Also go easy with the code completion popup delay. Dont set it to 0, i remember a strange behaviour in Eclipse where there was no popup at all.
Ctrl+Space 是内容辅助的快捷方式。
Ctrl+1 是“快速修复”的快捷键。
Ctrl+2 是快速助手菜单的快捷方式。 (Ctrl+2、F 是“快速辅助 - 分配给变量/字段”的快捷方式,您也可以键入 L 或 R 来代替 F 以获取其他选项。)
要查看和/或修改可用的快捷方式,您可以转至 Window > ;首选项>一般>钥匙。
Ctrl+Space is the shortcut for Content Assist.
Ctrl+1 is the shortcut for Quick Fix.
Ctrl+2 is the shortcut for a menu of Quick Assists. (Ctrl+2, F is the shortcut for Quick Assist - Assign to var/field, and in place of F you can also type L or R for other options.)
To see and/or modify available shortcuts you can go to Window > Preferences > General > Keys.