* wl-highlight.el (wl-highlight-message): Fixed problem of
authorteranisi <teranisi>
Mon, 30 Oct 2000 10:39:21 +0000 (10:39 +0000)
committerteranisi <teranisi>
Mon, 30 Oct 2000 10:39:21 +0000 (10:39 +0000)
highlighting failure which occured when the last field contains
multiple lines in the draft buffer.

wl/ChangeLog
wl/wl-highlight.el

index a264200..a53fa33 100644 (file)
@@ -1,5 +1,9 @@
 2000-10-30  Yuuichi Teranishi  <teranisi@gohome.org>
 
+       * wl-highlight.el (wl-highlight-message): Fixed problem of
+       highlighting failure which occured when the last field contains
+       multiple lines in the draft buffer.
+
        * wl.el (wl-toggle-plugged): Call `wl-biff-stop' if unplugged,
        `wl-biff-start' if plugged.
 
index b39de13..5b5732f 100644 (file)
@@ -1167,7 +1167,7 @@ interpreted as cited text.)"
                                    "^$\\|%s"
                                    (regexp-quote mail-header-separator))
                                   nil t)
-               (narrow-to-region (point-min) (point)))
+               (narrow-to-region (point-min) (match-beginning 0)))
            ;; highlight only when header is not too-big.
            (when (or (null wl-highlight-max-header-size)
                      (< (point) wl-highlight-max-header-size))
@@ -1195,15 +1195,15 @@ interpreted as cited text.)"
                    (put-text-property
                     p hend 'face 'wl-highlight-message-header-contents)))
                  (goto-char hend))
-                ((looking-at mail-header-separator)
-                 (put-text-property (match-beginning 0) (match-end 0)
-                                    'face 'wl-highlight-header-separator-face)
-                 (goto-char (match-end 0)))
                 ;; ignore non-header field name lines
                 (t (forward-line 1))))))
          (let (prefix prefix-face-alist pair end)
            (while (not (eobp))
              (cond
+              ((looking-at mail-header-separator)
+               (put-text-property (match-beginning 0) (match-end 0)
+                                  'face 'wl-highlight-header-separator-face)
+               (goto-char (match-end 0)))
               ((null wl-highlight-force-citation-header-regexp)
                nil)
               ((looking-at wl-highlight-force-citation-header-regexp)