Eclipse设置Tab键为四个空格

摘自:https://my.oschina.net/xunxun10/blog/110074

Window---->preference--->Editors--->Text Editors :勾选Insert spaces for tabs  应用

第二步:window-->preference-->Java--->Code Style--->Formatter----->Edit--->Indentation 下的Tab policy  选Spaces only

若出现应用Apply按钮为灰色的情况,需要回到上一步,点击new按钮,根据当前的样式重新生成一个新的样式并保存,重复第2步,编辑该样式即可,如下图:

posted @ 2017-03-30 20:50  21heshang  阅读(142)  评论(0编辑  收藏  举报