From: kaoru Date: Wed, 18 Jun 2003 19:05:13 +0000 (+0000) Subject: * wl-highlight.el (wl-highlight-summary-window): Re-calculate the X-Git-Tag: wl-2_10_1pre~1 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8368b5a19842ba04eba4189bd8b368439f842ca0;p=elisp%2Fwanderlust.git * wl-highlight.el (wl-highlight-summary-window): Re-calculate the end of the window if possible. --- diff --git a/wl/ChangeLog b/wl/ChangeLog index 9c3622b..df3ba02 100644 --- a/wl/ChangeLog +++ b/wl/ChangeLog @@ -1,5 +1,8 @@ 2003-06-18 TAKAHASHI Kaoru + * wl-highlight.el (wl-highlight-summary-window): Re-calculate the + end of the window if possible. + * wl-vars (wl-delete-folder-alist,): Change default value. (wl-folder-hierarchy-access-folders): Ditto. diff --git a/wl/wl-highlight.el b/wl/wl-highlight.el index c24b04b..eea611c 100644 --- a/wl/wl-highlight.el +++ b/wl/wl-highlight.el @@ -991,13 +991,18 @@ Variables used: (defun wl-highlight-summary-window (&optional win beg) "Highlight summary window. This function is defined for `window-scroll-functions'" - (if wl-summary-highlight - (with-current-buffer (window-buffer win) - (when (eq major-mode 'wl-summary-mode) - (wl-highlight-summary (window-start win) - (window-end win) - 'lazy) - (set-buffer-modified-p nil))))) + (when wl-summary-highlight + (with-current-buffer (window-buffer win) + (when (eq major-mode 'wl-summary-mode) + (let ((start (window-start win)) + (end (condition-case nil + (window-end win t) ;; old emacsen doesn't support 2nd arg. + (error (window-end win))))) + (wl-highlight-summary start + end + 'lazy)) + (set-buffer-modified-p nil))))) + (defun wl-highlight-headers (&optional for-draft) (let ((beg (point-min)) @@ -1098,8 +1103,7 @@ interpreted as cited text.)" (real-end end) current beg e p hend) - (if too-big - nil + (unless too-big (save-excursion (save-restriction (widen)