From 0e62d1716d5e6974cec368a8a586f8648679fc6e Mon Sep 17 00:00:00 2001 From: yamaoka Date: Fri, 17 Jan 2003 01:30:58 +0000 Subject: [PATCH] * infohack.el (infohack-texi-format): Insert one excessive newline after a @foo{bar} thing to prevent clinging of a line and a line (old texinfmt bug?) if it should be considered only one thing in a line. --- ChangeLog | 7 +++++++ texi/infohack.el | 8 ++++++++ 2 files changed, 15 insertions(+) diff --git a/ChangeLog b/ChangeLog index 93d91f5..4c45d19 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2003-01-17 Katsumi Yamaoka + + * texi/infohack.el (infohack-texi-format): Insert one excessive + newline after a @foo{bar} thing to prevent clinging of a line and + a line (old texinfmt bug?) if it should be considered only one + thing in a line. + 2003-01-16 Katsumi Yamaoka * lisp/gnus-msg.el (gnus-summary-digest-mail-forward): Set article diff --git a/texi/infohack.el b/texi/infohack.el index 17b1f68..1cf6e8d 100644 --- a/texi/infohack.el +++ b/texi/infohack.el @@ -133,6 +133,14 @@ (delete-region (point) (save-excursion (forward-line 1) (point)))))))))) + ;; Insert one excessive newline after a @foo{bar} thing to + ;; prevent clinging of a line and a line (old texinfmt bug?) + ;; if it should be considered only one thing in a line. + (goto-char (point-min)) + (while (re-search-forward "^[\t ]*@[a-z]+{.+}[\t ]*\n[\t ]*\n" + nil t) + (if (not (looking-at "[\t ]*$\\|[\t ]*@[a-z]+[\t\n ]")) + (insert "\n"))) (texinfo-mode) (texinfo-every-node-update) (set-buffer-modified-p nil) -- 1.7.10.4