配置Eclipse以避免注释换行
当我编写代码时,我使用CTRL+SHIFT+F对其进行格式化。除了注释、Eclipse wrapes注释和非常烦人的注释外,其他一切都可以正常工作。我只想要一行评论,不管它有多长 比如说配置Eclipse以避免注释换行,eclipse,Eclipse,当我编写代码时,我使用CTRL+SHIFT+F对其进行格式化。除了注释、Eclipse wrapes注释和非常烦人的注释外,其他一切都可以正常工作。我只想要一行评论,不管它有多长 比如说 void SomeMethod() { int someValue = 155; // This value is for blah blah blah blah } 后格式 void SomeMethod() { int someValue = 155; // This value is
void SomeMethod()
{
int someValue = 155; // This value is for blah blah blah blah
}
后格式
void SomeMethod()
{
int someValue = 155; // This value is
// for blah blah
// blah blah
}
现在,它需要3行免费
我正在使用Eclipse3.7.2来修复它
Comments
选项卡包含有关注释格式的所有内容。将注释的最大线宽设置为非常大的数字李>
考虑在上述情况下使用JavaDoc注释而不是普通注释。这还有其他好处,比如Eclipse在将鼠标悬停在变量名上的任意位置时,将注释显示为工具提示。