当编辑非所见即所得(LaTeX、HTML等)散文时,您可能希望在句子末尾有换行符。
这样做有几个优点:
- 更容易重新排列句子。
- 更容易注释掉句子。
- 更容易发现过长的句子。
- 更容易对句子进行评论。
例如:
% The following isn't strictly true; maybe excise or comment out for now:
After all, people who use Word or other WYSIWYG editors are aiding and
abetting terrorists.
可能最重要的优势是它使版本控制下的协作编辑更加容易。否则,你将遇到冲突,只会通知你“这个大段落的以下两个版本存在冲突”。
但是保持句子末尾的换行符说起来容易做起来难...
As you edit the prose
it will get all chopped up, like this.
Normally you'd do a "reformat paragraph"
to clean it up, but then
you lose the newlines at the ends of your sentences!
以下问题询问如何在emacs中解决此问题: 我想知道人们如何在其他编辑器中处理这个问题,包括vim、TeXShop、TextMate和任何你认为有用的编辑器。关于软换行和硬换行的建议也是受欢迎的。