【发布时间】:2012-12-04 11:53:41
【问题描述】:
我有这段 Java 代码:
/**
* Initializes the Levenshtein Object with the two given words.
*
* @param word1 first word
* @param word2 second word
*/
public Levenshtein(String word1, String word2) {
this.word1 = "." + word1.toLowerCase();
this.word2 = "." + word2.toLowerCase();
this.distance = new int[this.word2.length()][this.word1
.length()];
}
如果我按 Ctrl + Shift + F,我会得到:
/**
* Initializes the Levenshtein Object with the two given words.
*
* @param word1
* first word
* @param word2
* second word
*/
public Levenshtein(String word1, String word2) {
this.word1 = "." + word1.toLowerCase();
this.word2 = "." + word2.toLowerCase();
this.distance = new int[this.word2.length()][this.word1
.length()];
}
为什么 Eclipse 做这种婴儿车换行?如何切换它(不完全切换到 JavaDoc)?
这些是我目前在 eclipse 3.5.2 (Galileo) 中使用的 Formatter settings。
【问题讨论】: