emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] /srv/bzr/emacs/trunk r99495: * man.el (Man-fontify-manpage


From: Juri Linkov
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r99495: * man.el (Man-fontify-manpage, Man-cleanup-manpage):
Date: Sun, 14 Feb 2010 02:20:31 +0200
User-agent: Bazaar (2.0.3)

------------------------------------------------------------
revno: 99495
committer: Juri Linkov <address@hidden>
branch nick: trunk
timestamp: Sun 2010-02-14 02:20:31 +0200
message:
  * man.el (Man-fontify-manpage, Man-cleanup-manpage):
  Remove remaining ^H with their preceding chars.  (Bug#5566)
modified:
  lisp/ChangeLog
  lisp/man.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2010-02-13 19:29:25 +0000
+++ b/lisp/ChangeLog    2010-02-14 00:20:31 +0000
@@ -1,3 +1,8 @@
+2010-02-14  Juri Linkov  <address@hidden>
+
+       * man.el (Man-fontify-manpage, Man-cleanup-manpage):
+       Remove remaining ^H with their preceding chars.  (Bug#5566)
+
 2010-02-13  Glenn Morris  <address@hidden>
 
        * simple.el (transpose-subr): Give it a doc-string.

=== modified file 'lisp/man.el'
--- a/lisp/man.el       2010-02-11 16:00:01 +0000
+++ b/lisp/man.el       2010-02-14 00:20:31 +0000
@@ -1087,6 +1087,11 @@
     (while (re-search-forward "[-|]\\(\b[-|]\\)+" nil t)
       (replace-match "+")
       (put-text-property (1- (point)) (point) 'face 'bold))
+    ;; When the header is longer than the manpage name, groff tries to
+    ;; condense it to a shorter line interspered with ^H.  Remove ^H with
+    ;; their preceding chars (but don't put Man-overstrike-face).  (Bug#5566)
+    (goto-char (point-min))
+    (while (re-search-forward ".\b" nil t) (backward-delete-char 2))
     (goto-char (point-min))
     ;; Try to recognize common forms of cross references.
     (Man-highlight-references)
@@ -1174,6 +1179,11 @@
        ))
   (goto-char (point-min))
   (while (re-search-forward "[-|]\\(\b[-|]\\)+" nil t) (replace-match "+"))
+  ;; When the header is longer than the manpage name, groff tries to
+  ;; condense it to a shorter line interspered with ^H.  Remove ^H with
+  ;; their preceding chars (but don't put Man-overstrike-face).  (Bug#5566)
+  (goto-char (point-min))
+  (while (re-search-forward ".\b" nil t) (backward-delete-char 2))
   (Man-softhyphen-to-minus)
   (message "%s man page cleaned up" Man-arguments))
 


reply via email to

[Prev in Thread] Current Thread [Next in Thread]