- (overlay-put ov 'face 'wl-highlight-summary-displaying-face))))
-
-(defun-hilit2 wl-highlight-folder-group-line (numbers)
- (if wl-highlight-group-folder-by-numbers
- (let (fsymbol bol eol)
- (beginning-of-line)
- (setq bol (point))
- (save-excursion (end-of-line) (setq eol (point)))
- (setq fsymbol
- (let ((unsync (nth 0 numbers))
- (unread (nth 1 numbers)))
- (cond ((and unsync (eq unsync 0))
- (if (and unread (> unread 0))
- 'wl-highlight-folder-unread-face
- 'wl-highlight-folder-zero-face))
- ((and unsync
- (>= unsync wl-folder-many-unsync-threshold))
- 'wl-highlight-folder-many-face)
- (t
- 'wl-highlight-folder-few-face))))
- (put-text-property bol eol 'face fsymbol))
- (let ((highlights (list "opened" "closed"))
- fregexp fsymbol bol eol matched type extent num type)
- (beginning-of-line)
- (setq bol (point))
- (save-excursion (end-of-line) (setq eol (point)))
- (catch 'highlighted
- (while highlights
- (setq fregexp (symbol-value
- (intern (format "wl-highlight-folder-%s-regexp"
- (car highlights)))))
- (setq fsymbol (intern (format "wl-highlight-folder-%s-face"
- (car highlights))))
- (when (looking-at fregexp)
- (put-text-property bol eol 'face fsymbol)
- (setq matched t)
- (throw 'highlighted nil))
- (setq highlights (cdr highlights)))))))
-
-(defun-hilit2 wl-highlight-summary-line-string (line mark temp-mark indent)
+ (overlay-put ov 'face 'wl-highlight-summary-displaying-face)
+ (overlay-put ov 'evaporate t)
+ (overlay-put ov 'wl-momentary-overlay t))))
+
+(defun wl-highlight-folder-group-line (numbers)
+ (end-of-line)
+ (let ((eol (point))
+ bol)
+ (beginning-of-line)
+ (setq bol (point))
+ (let ((text-face (cond ((looking-at wl-highlight-folder-opened-regexp)
+ 'wl-highlight-folder-opened-face)
+ ((looking-at wl-highlight-folder-closed-regexp)
+ 'wl-highlight-folder-closed-face))))
+ (if (and wl-highlight-folder-by-numbers
+ (re-search-forward "[0-9-]+/[0-9-]+/[0-9-]+" eol t))
+ (let* ((unsync (nth 0 numbers))
+ (unread (nth 1 numbers))
+ (face (cond ((and unsync (zerop unsync))
+ (if (and unread (> unread 0))
+ 'wl-highlight-folder-unread-face
+ 'wl-highlight-folder-zero-face))
+ ((and unsync
+ (>= unsync wl-folder-many-unsync-threshold))
+ 'wl-highlight-folder-many-face)
+ (t
+ 'wl-highlight-folder-few-face))))
+ (if (numberp wl-highlight-folder-by-numbers)
+ (progn
+ (put-text-property bol (match-beginning 0) 'face text-face)
+ (put-text-property (match-beginning 0) (match-end 0)
+ 'face face))
+ ;; Remove previous face.
+ (put-text-property bol (match-end 0) 'face nil)
+ (put-text-property bol (match-end 0) 'face face)))
+ (put-text-property bol eol 'face text-face)))))
+
+(defun wl-highlight-summary-line-string (line mark temp-mark indent)