Eclipse開發Java前配置

字體設置

Window->Preferences->General->Apperance->Colors and Fonts->Basic->Text Font->Edit(Consolas 常規 小四)
自己喜歡就好

工作空間默認編碼設置

Window->Preferences->General->Workspace->Text file encoding(UTF-8)
Window->Preferences->General->Workspace->New text file line delimiter(Other Unix)
參考公司/團隊規定

指定類型文件默認編碼設置

Window->Preferences->General->Content Types->Text->Java Source File->Default encoding(UTF-8)
Window->Preferences->General->Content Types->Text->Java Properties File->Default encoding(UTF-8)
參考公司/團隊規定


保存時自動格式化代碼

Window->Preferences->Java->Editor->Save Actions->Perform the selected actions on save
其他選項按照自己需求自己選擇

設置Java代碼模版

Window->Preferences->Java->Code Style->New Java Files->Edit
java類模版

其他參數可以自己選擇

自定義編程風格

Window->Preferences->Java->Code Style->Formatter->New
可以選擇tab格式,每行代碼字符個數,if else格式等等
如果沒有特殊需求,默認的格式已經可以滿足需求

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章