改进 Eclipse 自动完成功能?
目前 Eclipse 自动补全似乎只在点后或参数上触发,我也想将它用于变量,例如,如果我有
字符串测试=“你好”;
然后,如果我开始在下一行中输入“t”(例如,如果我打算更改变量 test 的值),我希望自动完成功能建议“test”。
有没有 Eclipse 插件可以做到这一点?我已经检查了 Eclipse 内容辅助选项,但似乎没有我想要的选项?感谢您的任何提示!
Currently the Eclipse autocompletion seems only to be triggered after a dot or on parameters, I want to use it for variables too, e.g. if I have
String test="hello";
then I want the autocompletion to suggest "test" if I start typing "t" in the next line (e.g. if I intent to change the value of the variable test).
Is there any Eclipse plugin capable of doing this? I already checked the Eclipse content assist options, but seems like there no option for what I want? Thanks for any hint!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(6)
首先,感谢大家的回复。它们是正确的,但是您每次都必须按组合键。这是自动完成的方法:
这只会在任何英文字母字符和点之后触发自动激活。
https://bugs.eclipse.org/bugs/show_bug.cgi?id=159157#c12< /a>
工作正常:-)
提示:您可能还想将自动激活延迟设置为 0,至少如果您习惯使用 Visual Studio 的话;-)
First of all, thanks for all the replies. They are correct, however you have to press the key combination each time. Here's how it's done automatically:
This simply triggers auto activation after any English alphabet character and after dot.
https://bugs.eclipse.org/bugs/show_bug.cgi?id=159157#c12
Works fine :-)
Hint: You probably want to additionally set the auto activation delay to 0, at least if you are used to visual studio ;-)
除了上面的建议之外,您是否尝试过 ALT + / 它进行增量匹配?不?
In addition to the suggestions above, did you try ALT + / it does incremental matching? No?
ctrl + 空格
ctrl + space
如果您按
ctrl+space
组合键,Eclipse将显示代码辅助窗口。输入 t 然后按
ctrl+space
,它会显示可能的匹配项If you press
ctrl+space
key combination, eclipse will show you the code assist window.Type t and then hit
ctrl+space
, it will show you possible matches您可以按“t”,然后按 Ctrl+Space..
是吗?
You can press "t" and then Ctrl+Space..
is it?
在 Eclipse 中
完成。
In Eclipse
done.