由于外部强制执行的编码标准,我需要编写所有四个边对齐边框的代码注释。
在 Emacs 中,最简单的方法是:
- 将一些文本转换成这种格式的块注释
- 编辑块注释中的文本并让 Emacs 正确重排它
评论格式示例:
#*****************************************************************************#
#* This is a block comment. It has right-aligned borders. *#
#* *#
#* It can have separate paragraphs. Text in a long paragraph flows from one *#
#* line to the next with one space of internal padding. *#
#* *#
#* The right hand border is at char 78 *#
#*****************************************************************************#
sub MySub
{
#***************************************************************************#
#* The left hand edge of the comment is aligned with the current code *#
#* block, but the right hand border is still at char 78 *#
#***************************************************************************#
my $var = 3;
}
auto-fill-mode
本身不保留右侧边界。