Window-->Preferences-->Java-->Code Style-->Formatter
需要自己新建個Formatter,否則提示無法編輯,此為默認設置;然后選擇右邊Edit按鈕,在Indentation-->General Settings頁中Tab policy右邊的下拉框,選擇Space only!
然后下面的Indentation size和Tab size都設置成你要的空格數即可!一般是8個空格!!
注意:3.6之前版本好像設置Window-->Preferences-->General-->Editors-->Text Editors右邊的選項Insert spaces for tabs勾上!然后Displayed tab width=8也可以!但3.6不行!