eclipse 代码自动提示(java、xml)

配置方法如下
1)java文件中的自动提示
    Window->Preferences->Java->Editor->Content Assist->Auto Activation,将Auto activation triggers for Java的值从“.”替换成“.abcdefghijklmnopqrstuvwxyz(,”。

2)xml文件中的自动提示
    Window->Preferences->XML->XML Files->Editor->Content Assist->Auto Activation,将Prompt when these characters are inserted的值从“<=:”替换成“.abcdefghijklmnopqrstuvwxyz(,”。

注意:如果配置成功,但是在java中未完成的代码后按快捷键“alt+/”还是没有自动提示,那么检查以下选项是否打勾:
    Window->Preferences->Java->Editor->Content Assist->Advance,将选项“Java Proposals”勾上。

快捷键“alt+/”的配置在:
     Window->Preferences->General->Key:第一个文本框中输入Content Assist即可。

猜你喜欢

转载自boat-in-sea.iteye.com/blog/2322090