windows中一般不会出现这个问题,一般是装linux的eclipse 版本,默认不会自动开启代码提示功能,需要你自己设定,这也是我很想不通的一点,但事实就是如此!!


Eclipse版本(本文测试)

Eclipse IDE for Java Developers

Version:Indigo Service Release 1

Build id: 20110916-0149


配置步骤:

1  Window > Preferences > Java > Editor > Content Assist

2  “Auto Activation triggers for java”这个选项就是指触发代码提示的的选项,

    把“.”修改成".abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"

    意思就是指遇到26个字母的大小写和.(这些符号就触发代码提示功能了)


配置截图:

0_13244350073LuS.gif




1、菜单window->Preferences->Java->Editor->Content Assist->Enable auto activation 选项要打上勾 
  2、windows-->preference-->workbench-->keys 下设置Content Assist 的快捷键 
  3、window->Preferences->Java->Editor->Content Assist->Advanced 上面的选项卡Select the proposal kinds contained in the 'default' content assist list: 中把 Other Java Proposals 选项打上勾就可以了