Eclipse 設定: Java 自動排版

使用快捷鍵自動排版

Windows: Ctrl + Shift + F
Mac:  +  + F


儲存時自動排版、import packages、增加 annotations


  1. 點選 Windows -> Preferences


  2. Java -> Editor -> Save Action -> 勾選 Perform the selected actions on save
    • Format source code:自動排版
    • Organize imports:自動 import
    • Additional actions:自動增加 annotations

留言

這個網誌中的熱門文章

歐萊禮 - 深入淺出 HTML 5 程式設計 重點整理

Scrum 重點整理