eclipse的代碼提示很方便,但有時候按space只是想空格,但默認會將提示的第一個選項選中,若不想被選中,可以修改如下文件
ecipse中Window->Show view找到Plug ins,找到org.eclipse.jface.text,右鍵Import as -> source project, 在工程文件中就可以看到這個工程文件,找到org.eclipse.jface.text.contentassist.CompletionProposalPopup.java文件,搜尋verifyKey()函數,
找到其中的if (contains(triggers, key))條件,修改爲if (key!=0x20 && key!='=' && key!=';' && contains(triggers, key))。然後將這個工程再導出Export->Deployable plugins and fragments。
在導出的目錄下有一個plugins文件夾,裏邊生成了一個jar包,將eclipse 中的jar替換掉即可