X-Git-Url: http://git.chise.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=elmo%2Felmo-vars.el;h=160fea55615ed6a3e2c2dbc18a2934735feab913;hb=9041da3cb714676c25dad85e6cd4a80b3755d4c8;hp=d1f34e2614123d9a4ff4260be66d77d287818bf5;hpb=a96af5f347545669151a8aa6b7326b374023e494;p=elisp%2Fwanderlust.git diff --git a/elmo/elmo-vars.el b/elmo/elmo-vars.el index d1f34e2..160fea5 100644 --- a/elmo/elmo-vars.el +++ b/elmo/elmo-vars.el @@ -35,6 +35,16 @@ (defun-maybe dynamic-link (a)) (defun-maybe dynamic-call (a b))) +;; bind colon keywords for old Emacsen. +(dont-compile + (condition-case nil + :symbol-for-testing-whether-colon-keyword-is-available-or-not + (void-variable + (let ((kwds '(:cc :date :extra :message-id :number :references :subject))) + (while kwds + (set (car kwds) (car kwds)) + (setq kwds (cdr kwds))))))) + (defgroup elmo nil "ELMO, Elisp Library for Message Orchestration." :tag "ELMO" @@ -47,24 +57,58 @@ :prefix "elmo-" :group 'elmo) -;; Local -(defvar elmo-localnews-folder-path "~/News" - "*Local news folder path.") -(defvar elmo-maildir-folder-path "~/Maildir" - "*Maildir folder path.") -(defvar elmo-maildir-list '("\\+~/Maildir") - "*All Folders that match this list will be treated as Maildir. -Each elements are regexp of folder name (This is obsolete).") +(defcustom elmo-digest-flags '(unread) + "Flags which are treated as `digest'." + :type '(repeat (symbol :tag "flag")) + :group 'elmo) + +(defcustom elmo-preserved-flags '(forwarded answered cached new unread) + "A list to define preserved flags. +Flags in this list can be searched by `any' flag condition. +If you want to treat a flag in this list as a `digest' flag, +you have to add it to `elmo-digest-flags'. +" + :type '(repeat (symbol :tag "flag")) + :group 'elmo) + +;; Message Database + +(defcustom elmo-msgdb-default-type 'standard + "*Default type of Message Database for ELMO." + :type '(radio (const legacy) + (const standard)) + :group 'elmo + :group 'elmo-setting) + +(defcustom elmo-msgdb-convert-type 'auto + "*MODB conversion type." + :type '(radio (const sync) + (const auto) + (const :tag "No convert" nil)) + :group 'elmo + :group 'elmo-setting) + +(defcustom elmo-init-hook '(elmo-global-mark-migrate) + "*A hook called when elmo is initialized." + :type 'hook + :group 'elmo) (defvar elmo-msgdb-file-header-chop-length 2048 "*Number of bytes to get header in one reading from file.") -(defvar elmo-msgdb-directory "~/.elmo" - "*ELMO Message Database path.") +(defcustom elmo-msgdb-directory "~/.elmo" + "*ELMO Message Database path." + :type 'directory + :group 'elmo + :group 'elmo-setting) (defvar elmo-passwd-alist-file-name "passwd" "*ELMO Password filename.") -(defvar elmo-passwd-life-time nil - "*Duration of ELMO Password in seconds. nil means infinity.") +(defcustom elmo-passwd-life-time nil + "*Duration of ELMO Password in seconds. nil means infinity." + :type '(choice (const :tag "Infinity" nil) + number) + :group 'elmo + :group 'elmo-setting) (defvar elmo-warning-threshold 30000 "*Display warning when the bytes of message exceeds this value.") @@ -78,12 +122,6 @@ Each elements are regexp of folder name (This is obsolete).") ;;; IMAP4 -(defcustom elmo-imap4-default-mailbox "inbox" - "*Default IMAP4 mailbox." - :type 'string - :group 'elmo - :group 'elmo-setting) - (defcustom elmo-imap4-default-server "localhost" "*Default IMAP4 server." :type 'string @@ -229,8 +267,6 @@ This is taken precedence over `elmo-network-stream-type-alist'.") (defvar elmo-msgdb-lock-list-filename "lock" "Locked messages...list of message-id. For disconnected operations.") -(defvar elmo-msgdb-global-mark-filename "global-mark" - "Alist of global mark.") (defvar elmo-lost+found-folder "+lost+found" "Lost and found.") (defvar elmo-crosspost-alist-filename "crosspost-alist" @@ -242,11 +278,24 @@ For disconnected operations.") (defvar elmo-strict-diff-folder-list nil "List of regexps of folder name which should be checked its diff strictly.") -(defvar elmo-msgdb-extra-fields nil - "Extra fields for msgdb.") +(defcustom elmo-msgdb-prefer-in-reply-to-for-parent nil + "*Non-nil to prefer In-Reply-To header for finding parent message on thread, +rather than References header." + :type 'boolean + :group 'elmo + :group 'elmo-setting) -(defvar elmo-enable-disconnected-operation t - "*Enable disconnected operations.") +(defcustom elmo-msgdb-extra-fields nil + "Extra fields for msgdb." + :type '(repeat string) + :group 'elmo + :group 'elmo-setting) + +(defcustom elmo-enable-disconnected-operation t + "*Non-nil enables disconnected operations." + :type 'boolean + :group 'elmo + :group 'elmo-setting) (defvar elmo-auto-change-plugged 600 "*Time to expire change plugged state automatically, as the number of seconds. @@ -308,7 +357,8 @@ If function, return value of function.") (defvar elmo-network-stream-type-alist '(("!" ssl ssl open-ssl-stream) ("!!" starttls starttls starttls-open-stream) - ("!socks" socks socks socks-open-network-stream)) + ("!socks" socks socks socks-open-network-stream) + ("!direct" direct nil open-network-stream)) "An alist of (SPEC-STRING SYMBOL FEATURE OPEN-STREAM-FUNCTION). SPEC-STRING is a string for stream-type spec (it must start with '!'). SYMBOL is a symbol which indicates the name of the stream type. @@ -371,9 +421,6 @@ Arguments for this function are NAME, BUFFER, HOST and SERVICE.") (defvar elmo-use-decoded-cache (featurep 'xemacs) "Use cache of decoded mime charset string.") -(defvar elmo-use-overview-hashtb t - "Use hash table of overview.") - (defvar elmo-display-progress-threshold 20 "*Displaying progress gauge if number of messages are more than this value.") @@ -389,6 +436,49 @@ Arguments for this function are NAME, BUFFER, HOST and SERVICE.") (defvar elmo-dop-queue nil "Global variable for storing disconnected operation queues.") +(defcustom elmo-mime-display-as-is-coding-system (if (boundp 'MULE) + '*autoconv* 'undecided) + "*Coding system used when message is displayed as is." + :type 'symbol + :group 'elmo) + +(defcustom elmo-mailing-list-name-spec-list + '(x-ml-name + (x-sequence "^\\([^ ]+\\)") + (subject "^\\s(\\(\\S)+\\)[ :][0-9]+\\s)[ \t]*") + (list-post "]+\\)-return-[0-9]+-") + (delivered-to "^mailing list \\([^@]+\\)@")) + "*List of spec to extract mailing list name from field value." + :type '(repeat + (choice (symbol :tag "Field Name") + (list (symbol :tag "Field Name") + (repeat + :inline symbol + (choice regexp + (cons regexp + (integer :tag "Match Index"))))))) + :group 'elmo) + +(defcustom elmo-mailing-list-count-spec-list + '(x-mail-count + x-ml-count + (x-sequence "^[^ ]+ \\([^ ]+\\)") + (subject "^\\s(\\S)+[ :]\\([0-9]+\\)\\s)[ \t]*") + (return-path "^<[^@>]+-return-\\([0-9]+\\)-")) + "*List of spec to extract mailing list count from field value." + :type '(repeat + (choice (symbol :tag "Field Name") + (list (symbol :tag "Field Name") + (repeat + :inline symbol + (choice regexp + (cons regexp + (integer :tag "Match Index"))))))) + :group 'elmo) + (require 'product) (product-provide (provide 'elmo-vars) (require 'elmo-version))