我将我的项目导入到 eclipse 中,它变成了双倍行距。有谁知道如何解决这个问题吗?
尝试过:
Find: [\t ]+$
Replace With: Nothing //error: incompatible line delimiter
Find: \s*\n
Replace With: Nothing //error: incompatible line delimiter
Find: ^\s*\r?\n
Replace With: /R //error: incompatible line delimiter
Find: ^\s*\r?\n
Replace With: nothing //string not found
Find: (.)\r\n(.)
Replace With: nothing //string not found
File > Convert Line Delimiters to > Windows //no changes
Source > Apply Formatting //grayed out
CTRL + Shift + F //doesn't remove double spaces
最佳答案
您尝试过吗(当然要启用正则表达式检查):
查找:^\s*\r?\n
替换为:\R
这会找到一行或双行并将其替换为一行。
编辑:
有一篇相关帖子,也许其中一个答案适合您:Remove empty lines in eclipse code editor by find/replace (Ctrl+F)
关于java - 删除eclipse中的双倍间距,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21990826/