subdirectories here.
(elmo-global-flags-initialize): New function.
* elmo.el (toplevel): Added autoload setting for
`elmo-global-flags-initialize'.
* wl.el (wl-init): Call `elmo-global-flags-initialize'.
* wl-highlight.el (wl-highlight-summary-flagged-face): New face.
(wl-highlight-get-face-by-name): New internal function.
(wl-highlight-summary-line-face-spec): Use it and fixed.
+2005-03-11 Hiroya Murata <lapis-lazuli@pop06.odn.ne.jp>
+
+ * elmo-flag.el (elmo-folder-list-subfolders): Don't list from
+ subdirectories here.
+ (elmo-global-flags-initialize): New function.
+
+ * elmo.el (toplevel): Added autoload setting for
+ `elmo-global-flags-initialize'.
+
2005-03-07 Yoichi NAKAYAMA <yoichi@geiin.org>
* elmo.el (message-number-changed): Define new signal.
(luna-define-method elmo-folder-list-subfolders ((folder elmo-flag-folder)
&optional one-level)
- (let ((dir (expand-file-name "flag" elmo-msgdb-directory)))
- (mapcar (lambda (flag)
- (concat
- (elmo-folder-prefix-internal folder)
- (symbol-name (elmo-folder-type-internal folder))
- "/"
- (symbol-name flag)))
- (elmo-uniq-list
- (append
- (mapcar 'intern (delete ".." (delete "." (directory-files dir))))
- (copy-sequence elmo-global-flags))))))
+ (mapcar (lambda (flag)
+ (concat
+ (elmo-folder-prefix-internal folder)
+ (symbol-name (elmo-folder-type-internal folder))
+ "/"
+ (symbol-name flag)))
+ elmo-global-flags))
(defun elmo-flag-folder-delete-message (folder number
&optional keep-referrer)
(setq result (delq flag result))))
result))
+(defun elmo-global-flags-initialize (&optional additional-flags)
+ (let ((dir (expand-file-name "flag" elmo-msgdb-directory)))
+ (setq elmo-global-flags
+ (elmo-uniq-list
+ (append
+ elmo-global-flags
+ additional-flags
+ (mapcar 'intern
+ (delete ".." (delete "." (directory-files dir)))))))))
+
;;; To migrate from global mark folder
(defvar elmo-global-mark-filename "global-mark"
"Obsolete variable. (Just for migration)")
(autoload 'elmo-global-flag-detach-messages "elmo-flag")
(autoload 'elmo-global-flag-set "elmo-flag")
(autoload 'elmo-get-global-flags "elmo-flag")
+ (autoload 'elmo-global-flags-initialize "elmo-flag")
(autoload 'elmo-global-mark-migrate "elmo-flag")
(autoload 'elmo-folder-list-global-flag-messages "elmo-flag"))
+2005-03-11 Hiroya Murata <lapis-lazuli@pop06.odn.ne.jp>
+
+ * wl.el (wl-init): Call `elmo-global-flags-initialize'.
+
+ * wl-highlight.el (wl-highlight-summary-flagged-face): New face.
+ (wl-highlight-get-face-by-name): New internal function.
+ (wl-highlight-summary-line-face-spec): Use it and fixed.
+
2005-03-10 Hiroya Murata <lapis-lazuli@pop06.odn.ne.jp>
* wl-summary.el (wl-summary-sync-update): Use
;; important messages
+(wl-defface wl-highlight-summary-flagged-face
+ '((((type tty)
+ (background dark))
+ (:foreground "magenta"))
+ (((class color)
+ (background dark))
+ (:foreground "orange"))
+ (((class color)
+ (background light))
+ (:foreground "purple")))
+ "Face used for displaying flagged messages."
+ :group 'wl-summary-faces
+ :group 'wl-faces)
+
(wl-defface wl-highlight-summary-new-face
'(
(((type tty)
(put-text-property bol (match-end 0) 'face face)))
(put-text-property bol eol 'face text-face)))))
+(defsubst wl-highlight-get-face-by-name (format &rest args)
+ (let ((face (intern (apply #'format format args))))
+ (and (find-face face)
+ face)))
+
(defsubst wl-highlight-summary-line-face-spec (flags temp-mark indent)
"Return a cons cell of (face . argument)."
(let (action)
(fl wl-summary-flag-alist)
face result global-flags)
(while (and (null result) priorities)
- (if (and (eq (car priorities) 'flag)
- (setq global-flags
- (elmo-get-global-flags flags 'ignore-preserved)))
- (while fl
- (when (memq (car (car fl)) global-flags)
- (setq result
- (progn
- (setq face
- (intern (format
- "wl-highlight-summary-%s-flag-face"
- (car (car fl)))))
- (when (find-face face)
- (list face)))
- fl nil))
- (setq fl (cdr fl)))
+ (if (eq (car priorities) 'flag)
+ (when (setq global-flags
+ (elmo-get-global-flags flags 'ignore-preserved))
+ (while fl
+ (when (memq (car (car fl)) global-flags)
+ (setq result
+ (list (or (wl-highlight-get-face-by-name
+ "wl-highlight-summary-%s-flag-face"
+ (car (car fl)))
+ 'wl-highlight-summary-flagged-face))
+ fl nil))
+ (setq fl (cdr fl)))
+ (unless result
+ (setq result (list 'wl-highlight-summary-flagged-face))))
(when (memq (car priorities) flags)
(setq result
- (progn (setq face
- (intern (format
- "wl-highlight-summary-%s-face"
- (car priorities))))
- (if (find-face face)
- (list face)
- (list 'wl-summary-persistent-mark-face))))))
+ (list (or (wl-highlight-get-face-by-name
+ "wl-highlight-summary-%s-face"
+ (car priorities))
+ 'wl-summary-persistent-mark-face)))))
(setq priorities (cdr priorities)))
result))
((string= temp-mark wl-summary-score-below-mark)
(nth 1 spec)))
(setq elmo-no-from wl-summary-no-from-message)
(setq elmo-no-subject wl-summary-no-subject-message)
+ (elmo-global-flags-initialize (mapcar 'car wl-summary-flag-alist))
(elmo-connect-signal
nil
'message-number-changed