Eclipse經常使用設置

字體設置

window——preference——General——Appearance——Colors and Font.字體

Ubuntu下偏心的字體是nimbus Mono Lspa

設置製表符(Tab鍵)的寬度,並將Tab鍵用空格替換

1. window——preference——General——Editor——Text Editor設置頁面:Display Tab Width, 並勾選Insert spaces for tabs.orm

2. window——preference——Java——Code Style——Formatter設置頁面,Edit,在彈出的Editor profile窗口中,Indentation卡片,設置Indentation Size和Tab Size爲4;xml

    並將Tab policy 設置爲Spaces only。繼承

3. 設置CSS與HTML的,製表符爲空格,且數量爲2。ip

  window——preference——Web——CSS Files——Editor 選擇Indent using spacess, 並將Indentation size 設置爲2(PS:Eclipse 4.5,經過鼠標滾輪來完成);it

  相同方式能夠設置HTML, JSP默認繼承HTMLio

4. 設置Javascript的Indentation size與Tab size的值爲2cli

     window——preference——JavaScript——Code Style——Formatter設置頁面,Edit,在彈出的Editor profile窗口中,Indentation卡片,設置Indentation Size和Tab Size爲2;    並將Tab policy 設置爲Spaces onlyfile

5. 設置xml的製表符爲空格,且數量爲2

   window——preference——XML——XML Files——Editor 選擇Indent using spacess, 並將Indentation size 設置爲2(PS:Eclipse 4.5,經過鼠標滾輪來完成)

Eclipse顯示空白符,如空格、製表符、換行符等

window——preference——General——Editor——Text Editor設置頁面 勾選 Show whitespace characters

相關文章
相關標籤/搜索