• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.9.5/emacs-92/emacs/lisp/gnus/

Lines Matching +defs:mail +defs:header +defs:parse +defs:content +defs:type

41 (require 'mail-parse)
48 (autoload 'gnus-msg-mail "gnus-msg" nil t)
51 (autoload 'parse-time-string "parse-time" nil nil)
117 (lambda (header)
118 (concat "^" header ":"))
160 :type '(choice :custom-show nil
170 :type '(repeat :value-to-internal (lambda (widget value)
178 (defcustom gnus-sorted-header-list
185 :type '(repeat regexp)
192 'empty Headers with no content.
202 :type '(set (const :tag "Headers with no content." empty)
221 :type 'boolean
229 :type '(choice :format "%{%t%}: %[Value Menu%]\n%v"
242 :type '(choice (const nil)
251 :type 'sexp
258 (if (or (gnus-image-type-available-p 'xface)
259 (gnus-image-type-available-p 'pbm))
262 (if (gnus-image-type-available-p 'pbm)
266 "*String or function to be executed to display an X-Face header.
269 :type `(choice string
278 :type '(choice regexp (const nil))
286 :type '(repeat (cons symbol regexp))
294 :parameter-type
311 "Alist of mail addresses and banners.
313 to match a mail address in the From: header, BANNER is one of a symbol
315 If ADDRESS matches author's mail address, it will remove things like
320 :type '(repeat
394 :type
440 :type 'regexp)
488 header. The function is called with one argument, the time, which can
490 :type '(choice string symbol)
500 :type 'boolean)
511 :type '(choice (item always)
524 :type 'regexp)
534 * gnus-summary-save-in-mail (Unix mail format)
562 :type '(radio (function-item gnus-summary-save-in-rmail)
563 (function-item gnus-summary-save-in-mail)
600 :type `(choice
616 :type 'function)
618 (defcustom gnus-mail-save-name 'gnus-plain-save-name
619 "A function generating a file name to save articles in Unix mail format.
622 :type 'function)
628 :type 'function)
635 :type 'function)
660 :type '(repeat (choice (list :value (fun) function)
668 :type 'regexp
679 :type 'string
684 :type 'hook
696 :type 'hook
701 :type 'hook
712 :type 'face
720 :type 'face
726 :type 'face
739 (defface gnus-header-from
752 (put 'gnus-header-from-face 'face-alias 'gnus-header-from)
754 (defface gnus-header-subject
767 (put 'gnus-header-subject-face 'face-alias 'gnus-header-subject)
769 (defface gnus-header-newsgroups
784 (put 'gnus-header-newsgroups-face 'face-alias 'gnus-header-newsgroups)
786 (defface gnus-header-name
795 "Face used for displaying header names."
799 (put 'gnus-header-name-face 'face-alias 'gnus-header-name)
801 (defface gnus-header-content
809 (:italic t))) "Face used for displaying header content."
813 (put 'gnus-header-content-face 'face-alias 'gnus-header-content)
815 (defcustom gnus-header-face-alist
816 '(("From" nil gnus-header-from)
817 ("Subject" nil gnus-header-subject)
818 ("Newsgroups:.*," nil gnus-header-newsgroups)
819 ("" gnus-header-name gnus-header-content))
825 header and NAME and CONTENT are either face names or nil.
827 The name of each header field will be displayed using the face
829 the header name and NAME is non-nil. Similarly, the content will
833 :type '(repeat (list (regexp :tag "Header")
846 :type 'hook)
851 :type 'function)
853 (defvar gnus-decode-header-function 'mail-decode-encoded-word-region
856 (defvar gnus-decode-address-function 'mail-decode-encoded-address-region
885 :type '(repeat regexp))
893 :type '(repeat regexp))
905 :type '(repeat regexp))
914 :type 'boolean)
917 "String used to delimit header and body.
922 :type '(choice (item :tag "None" :value nil)
931 :type '(repeat directory)
950 :type '(choice (const nil)
957 :type 'alist)
959 (defcustom gnus-article-date-lapsed-new-header nil
961 When using `gnus-treat-date-lapsed', the \"X-Sent:\" header will
962 either replace the old \"Date:\" header (if this variable is nil), or
966 :type 'boolean)
978 :type '(choice
994 ("view as type" . gnus-mime-view-part-as-type)
999 :type '(repeat (cons (string :tag "name")
1034 :type gnus-article-treat-custom)
1043 :type gnus-article-treat-custom)
1052 :type gnus-article-treat-head-custom)
1065 :type gnus-article-treat-custom)
1075 :type gnus-article-treat-custom)
1084 :type gnus-article-treat-custom)
1093 :type gnus-article-treat-custom)
1101 :type gnus-article-treat-head-custom)
1109 :type gnus-article-treat-head-custom)
1117 :type gnus-article-treat-custom)
1125 :type gnus-article-treat-custom)
1133 :type gnus-article-treat-custom)
1141 :type gnus-article-treat-custom)
1150 :type gnus-article-treat-custom)
1161 :type gnus-article-treat-custom)
1170 :type gnus-article-treat-custom)
1178 :type gnus-article-treat-head-custom)
1187 :type gnus-article-treat-custom)
1196 :type gnus-article-treat-head-custom)
1204 :type gnus-article-treat-head-custom)
1213 :type gnus-article-treat-head-custom)
1216 "Display the Date header in a way that says how much time has elapsed.
1221 :type gnus-article-treat-head-custom)
1229 :type gnus-article-treat-head-custom)
1238 :type gnus-article-treat-head-custom)
1247 :type gnus-article-treat-head-custom)
1250 "Strip the X-No-Archive header line from the beginning of the body.
1256 :type gnus-article-treat-custom)
1267 :type gnus-article-treat-custom)
1277 :type gnus-article-treat-custom)
1285 :type gnus-article-treat-custom)
1288 "Unfold folded header lines.
1294 :type gnus-article-treat-custom)
1303 :type gnus-article-treat-custom)
1312 :type gnus-article-treat-custom)
1320 :type gnus-article-treat-custom)
1328 (gnus-image-type-available-p 'xbm)
1342 :type gnus-article-treat-head-custom
1364 (gnus-image-type-available-p 'png)
1374 :type gnus-article-treat-head-custom)
1377 (defcustom gnus-treat-display-smileys (gnus-image-type-available-p 'xpm)
1386 :type gnus-article-treat-custom)
1390 (if (and (gnus-image-type-available-p 'xpm)
1393 "Display picons in the From header.
1402 :type gnus-article-treat-head-custom)
1405 (defcustom gnus-treat-mail-picon
1406 (if (and (gnus-image-type-available-p 'xpm)
1418 :type gnus-article-treat-head-custom)
1419 (put 'gnus-treat-mail-picon 'highlight t)
1422 (if (and (gnus-image-type-available-p 'xpm)
1434 :type gnus-article-treat-head-custom)
1439 gnus-treat-mail-picon
1448 :type gnus-article-treat-head-custom)
1457 :type gnus-article-treat-custom)
1466 :type gnus-article-treat-custom)
1474 :type gnus-article-treat-custom)
1483 :type gnus-article-treat-custom)
1492 :type gnus-article-treat-custom)
1503 :type gnus-article-treat-custom)
1514 :type 'string
1527 :type 'boolean)
1533 :type 'boolean)
1573 (gnus-treat-mail-picon gnus-treat-mail-picon)
1652 (defun gnus-article-goto-header (header)
1654 (re-search-forward (concat "^\\(" header "\\):") nil t))
1658 (gnus-add-text-properties-when 'article-type nil b e props)
1671 (defun gnus-article-hide-text-type (b e type)
1673 (gnus-add-wash-type type)
1675 b e (cons 'article-type (cons type gnus-hidden-properties))))
1677 (defun gnus-article-unhide-text-type (b e type)
1679 (gnus-delete-wash-type type)
1681 b e (cons 'article-type (cons type gnus-hidden-properties)))
1686 (defun gnus-article-hide-text-of-type (type)
1691 (while (setq b (text-property-any b e 'article-type type))
1694 (defun gnus-article-delete-text-of-type (type)
1698 (if (eq type 'multipart)
1710 (when (eq (get-text-property b 'article-type) 'multipart)
1712 (while (setq b (text-property-any b (point-max) 'article-type type))
1714 b (or (text-property-not-all b (point-max) 'article-type type)
1726 (defun gnus-article-text-type-exists-p (type)
1727 "Say whether any text of type TYPE exists in the buffer."
1728 (text-property-any (point-min) (point-max) 'article-type type))
1730 (defsubst gnus-article-header-rank ()
1731 "Give the rank of the string HEADER as given by `gnus-sorted-header-list'."
1732 (let ((list gnus-sorted-header-list)
1748 (max (1+ (length gnus-sorted-header-list)))
1777 ;; Hide any "From " lines at the beginning of (mail) articles.
1782 ;; Then treat the rest of the header lines.
1785 ;; select which header lines is to remain visible in the
1789 ;; Mark the rank of the header.
1795 (gnus-article-header-rank)
1802 (gnus-add-wash-type 'headers)
1804 '(article-type headers dummy-invisible t))
1829 (gnus-article-hide-text-type
1837 ;; Hide boring Newsgroups header.
1845 (gnus-article-hide-header "newsgroups")))
1856 (nth 1 (mail-extract-address-components to))
1858 (gnus-article-hide-header "to"))))
1869 (nth 1 (mail-extract-address-components to))
1871 (gnus-article-hide-header "to"))))
1882 (nth 1 (mail-extract-address-components cc))
1884 (gnus-article-hide-header "cc"))))
1889 (gnus-article-hide-header "followup-to")))
1893 (gnus-article-hide-header "reply-to")
1903 (mail-extract-address-components from t))
1907 (mail-extract-address-components reply-to t))
1909 (gnus-article-hide-header "reply-to")))))
1919 (gnus-article-hide-header "date"))))
1924 (gnus-article-hide-header "to"))
1926 (gnus-article-hide-header "cc"))))
1940 (gnus-article-hide-header "to"))
1952 (gnus-article-hide-header "cc"))
1955 (defun gnus-article-hide-header (header)
1958 (when (re-search-forward (concat "^" header ":") nil t)
1959 (gnus-article-hide-text-type
1968 (defvar gnus-article-normalized-header-length 40
1972 "Make all header lines 40 characters long."
1982 gnus-article-normalized-header-length)
1985 (- gnus-article-normalized-header-length column)
1987 ((> column gnus-article-normalized-header-length)
1990 (forward-char gnus-article-normalized-header-length)
2055 (gnus-article-hide-text-type (- (point) 2) (point) 'overstrike)
2058 (gnus-article-hide-text-type
2063 (gnus-article-hide-text-type (- (point) 2) (point) 'overstrike)
2076 (mail-header-narrow-to-field)
2077 (let ((header (buffer-string)))
2079 (insert header)
2095 (mail-header-narrow-to-field)
2096 (mail-header-fold-field)
2108 (gnus-add-wash-type 'smiley)
2125 (while (gnus-article-goto-header "newsgroups\\|followup-to")
2127 (mail-header-narrow-to-field)
2130 (mail-header-fold-field)
2148 (gnus-put-text-property start (point) 'gnus-decoration 'header)))))
2211 "Display any Face headers in the header."
2229 (mail-narrow-to-head)
2230 (while (gnus-article-goto-header "Face")
2231 (push (mail-header-field-value) faces))))
2234 (let ((from (gnus-article-goto-header "from"))
2244 (gnus-add-wash-type 'face)
2249 "Look for an X-Face header and display it if present."
2251 (let ((wash-face-p buffer-read-only)) ;; When type `W f'
2267 ;; If type `W f', use gnus-original-article-buffer,
2272 (mail-narrow-to-head)
2273 (while (gnus-article-goto-header "X-Face")
2274 (push (mail-header-field-value) x-faces))
2293 (let ((process-connection-type nil))
2318 (mail-parse-charset gnus-newsgroup-charset)
2319 (mail-parse-ignored-charsets
2322 (mail-decode-encoded-word-region (point-min) (point-max)))))
2330 (mail-parse-charset gnus-newsgroup-charset)
2331 (mail-parse-ignored-charsets
2342 ctl (and ct (mail-header-parse-content-type ct))
2347 (mail-content-type-get ctl 'charset)))
2348 format (and ctl (mail-content-type-get ctl 'format)))
2350 (setq cte (mail-header-strip cte)))
2357 (when (and (eq mail-parse-charset 'gnus-decoded)
2360 (setq charset mail-parse-charset))
2372 (mail-parse-charset gnus-newsgroup-charset)
2373 (mail-parse-ignored-charsets
2394 (funcall gnus-decode-header-function start end))
2467 (let ((inhibit-read-only t) type charset)
2470 (setq type
2471 (gnus-fetch-field "content-transfer-encoding"))
2472 (let* ((ct (gnus-fetch-field "content-type"))
2473 (ctl (and ct (mail-header-parse-content-type ct))))
2475 (mail-content-type-get ctl 'charset)))
2483 (and type (let ((case-fold-search t))
2484 (string-match "quoted-printable" type))))
2495 (let ((inhibit-read-only t) type charset)
2498 (setq type
2499 (gnus-fetch-field "content-transfer-encoding"))
2500 (let* ((ct (gnus-fetch-field "content-type"))
2501 (ctl (and ct (mail-header-parse-content-type ct))))
2503 (mail-content-type-get ctl 'charset)))
2511 (and type (let ((case-fold-search t))
2512 (string-match "base64" type))))
2566 (let* ((ct (gnus-fetch-field "content-type"))
2567 (ctl (and ct (mail-header-parse-content-type ct))))
2569 (mail-content-type-get ctl 'charset)))
2632 "Remove list identifies from the Subject header.
2663 ;; Hide the horrendously ugly "header".
2668 (gnus-add-wash-type 'pem)
2669 (gnus-article-hide-text-type
2678 (gnus-article-hide-text-type
2692 ;; Note that the From header is decoded here, so it is
2698 (mail-fetch-field "from"))))
2758 (gnus-article-hide-text-type
2910 (defun gnus-article-check-hidden-text (type arg)
2916 (let ((hide (gnus-article-hidden-text-p type)))
2922 (gnus-article-show-hidden-text type)
2927 (gnus-article-show-hidden-text type)
2931 (defun gnus-article-hidden-text-p (type)
2932 "Say whether the current buffer contains hidden text of type TYPE."
2933 (let ((pos (text-property-any (point-min) (point-max) 'article-type type)))
2938 (text-property-any (1+ pos) (point-max) 'article-type type)))
2943 (defun gnus-article-show-hidden-text (type &optional dummy)
2944 "Show all hidden text of type TYPE.
2949 'article-type type
2951 (cons 'article-type (cons type
2953 (gnus-delete-wash-type type)))
2964 (defun gnus-article-forward-header ()
2965 "Move point to the start of the next header.
2966 If the current header is a continuation header, this can be several
2975 (defun article-date-ut (&optional type highlight)
2979 `gnus-article-date-lapsed-new-header' says whether the \"X-Sent:\" header
2983 (date-regexp (cond ((not gnus-article-date-lapsed-new-header)
2985 ((eq type 'lapsed)
3019 (gnus-article-forward-header)
3023 (gnus-article-forward-header)
3031 (insert (article-make-date-line date (or type 'ut)))
3046 (defun article-make-date-line (date type)
3048 (unless (memq type '(local ut original user iso8601 lapsed english))
3049 (error "Unknown conversion type: %s" type))
3054 ((eq type 'local)
3060 ((eq type 'ut)
3063 (let* ((e (parse-time-string date))
3072 ((eq type 'original)
3077 ((eq type 'user)
3087 ((eq type 'iso8601)
3096 ((eq type 'lapsed)
3139 ((eq type 'english)
3203 "Start a timer to update the X-Sent header in the article buffers.
3282 (props (append '(article-type emphasis)
3297 (gnus-article-unhide-text-type
3301 (gnus-add-wash-type 'emphasis)
3478 (defun gnus-summary-save-in-mail (&optional filename)
3479 "Append this article to Unix mail file.
3483 "Save %s in Unix mail file" filename
3484 gnus-mail-save-name gnus-newsgroup-name
3485 gnus-current-headers 'gnus-newsgroup-last-mail))
3492 (mail-file-babyl-p filename))
3494 (gnus-output-to-mail filename)))))
3623 "/" (int-to-string (mail-header-number headers)))
3641 "/" (int-to-string (mail-header-number headers)))
3665 (let ((from (mail-header-from headers)))
3689 (setq headers (mapconcat (lambda (header)
3690 (concat header ": "
3691 (mail-fetch-field header)
3726 (message-remove-header "X-Gnus-PGP-Verify")
3747 "Verify Cancel-Lock header."
3833 "\C-c\C-m" gnus-article-mail
3866 ["Mail to address at point" gnus-article-mail t]
3903 \\[gnus-article-mail]\t Send a reply to the address near point
4020 (defun gnus-article-prepare (article &optional all-headers header)
4030 (let* ((gnus-article (if header (mail-header-number header) article))
4092 (gnus-summary-article-header gnus-current-article)
4157 %t The MIME type
4158 %T MIME type, along with additional info
4169 '((?t gnus-tmp-type ?s)
4170 (?T gnus-tmp-type-long ?s)
4180 (gnus-mime-view-part-as-type "t" "View As Type...")
4250 (mail-parse-charset gnus-newsgroup-charset)
4251 (mail-parse-ignored-charsets
4280 (insert "Content-Type: " (mm-handle-media-type data))
4281 (mml-insert-parameter-string (cdr (mm-handle-type data))
4285 (mail-header-encode-parameter "name" (file-name-nondirectory file)))
4293 (access-type . "LOCAL-FILE")
4299 (let ((mail-parse-charset (or gnus-article-charset
4301 (mail-parse-ignored-charsets
4315 (let ((mail-parse-charset (or gnus-article-charset
4319 (mail-parse-ignored-charsets
4328 ,(or (mail-header-references gnus-current-headers) "")
4348 (mail-decode-encoded-word-string (or (mm-handle-description data)
4351 (or (mail-content-type-get (mm-handle-disposition data) 'filename)
4353 (type (mm-handle-media-type data)))
4364 "| Type: " type "\n"
4380 (let ((mail-parse-charset (or gnus-article-charset
4382 (mail-parse-ignored-charsets
4396 (let ((mail-parse-charset (or gnus-article-charset
4400 (mail-parse-ignored-charsets
4409 ,(or (mail-header-references gnus-current-headers) "")
4444 (defun gnus-mime-view-part-as-type-internal ()
4449 (mail-content-type-get (mm-handle-type handle) 'name)
4452 (def-type (and name (mm-default-file-encoding name))))
4453 (and def-type (cons def-type 0))))
4455 (defun gnus-mime-view-part-as-type (&optional mime-type pred)
4456 "Choose a MIME media type, and view the part as such.
4460 (unless mime-type
4461 (setq mime-type
4462 (let ((default (gnus-mime-view-part-as-type-internal)))
4464 (format "View as MIME type (default %s): "
4472 (when (equal (mm-handle-media-type handle) "message/external-body")
4478 (cons mime-type (cdr (mm-handle-type handle)))
4530 (mail-content-type-get (mm-handle-type handle) 'name)
4531 (mail-content-type-get (mm-handle-disposition handle)
4554 (printer (mailcap-mime-info (mm-handle-media-type handle) "print")))
4565 printer file (mm-handle-type handle))))
4586 (setq charset (or (mail-content-type-get
4587 (mm-handle-type handle) 'charset)
4614 (let* ((type (mm-handle-type (if (equal (mm-handle-media-type handle)
4621 (charset (assq 'charset (cdr type))))
4623 (delq charset type)))))
4654 (equal (mm-handle-media-type parts) "multipart/alternative")
4668 (mail-parse-charset gnus-newsgroup-charset)
4669 (mail-parse-ignored-charsets
4672 (type (mm-handle-media-type handle))
4673 (method (mailcap-mime-info type))
4676 (gnus-mime-view-part-as-type
4677 nil (lambda (type) (stringp (mailcap-mime-info type))))
4691 (mail-parse-charset gnus-newsgroup-charset)
4692 (mail-parse-ignored-charsets
4697 (gnus-mime-view-part-as-type
4698 nil (lambda (type) (mm-inlinable-p handle type)))
4776 (equal (mm-handle-media-type (cdr ihandle))
4816 (mail-parse-charset gnus-newsgroup-charset)
4817 (mail-parse-ignored-charsets
4846 (mm-handle-media-type handle)))))
4861 (or (mail-content-type-get (mm-handle-type handle) 'name)
4862 (mail-content-type-get (mm-handle-disposition handle) 'filename)
4863 (mail-content-type-get (mm-handle-type handle) 'url)
4865 (gnus-tmp-type (mm-handle-media-type handle))
4867 (mail-decode-encoded-word-string (or (mm-handle-description handle)
4875 gnus-tmp-type-long b e)
4878 (setq gnus-tmp-type-long (concat gnus-tmp-type
4882 (setq gnus-tmp-type-long (concat " --- " gnus-tmp-type-long)))
4891 article-type annotation
4994 :type 'boolean)
5000 :type 'boolean)
5010 :type 'boolean)
5044 (gnus-add-wash-type 'signed)
5047 (gnus-add-wash-type 'encrypted)
5062 (let ((type (mm-handle-media-type handle))
5070 (when (string-match (pop ignored) type)
5082 (mm-automatic-external-display-p type)))
5097 (not (gnus-unbuttonized-mime-type-p type)))
5109 (let ((mail-parse-charset gnus-newsgroup-charset)
5110 (mail-parse-ignored-charsets
5124 (let ((charset (mail-content-type-get (mm-handle-type handle)
5141 (mm-handle-media-type handle)))))))))
5143 (defun gnus-unbuttonized-mime-type-p (type)
5149 (when (string-match (pop types) type)
5154 (when (string-match (pop types) type)
5184 (not (gnus-unbuttonized-mime-type-p
5202 article-type multipart))
5213 (mm-handle-media-type handle)))
5235 (let ((mail-parse-charset gnus-newsgroup-charset)
5236 (mail-parse-ignored-charsets
5247 (mm-handle-media-type handle))))))
5308 (defun gnus-add-wash-type (type)
5310 (add-to-list 'gnus-article-wash-types type))
5312 (defun gnus-delete-wash-type (type)
5314 (setq gnus-article-wash-types (delq type gnus-article-wash-types)))
5330 (gnus-delete-wash-type category)))
5505 (if (and (boundp 'header-line-format)
5506 (symbol-value 'header-line-format))
5746 "Start composing a reply mail to the current message.
5811 (let (do-update-line sparse-header)
5825 (gnus-read-header article))
5836 (let ((header (gnus-summary-article-header article)))
5842 (setq article (mail-header-id header))
5843 (setq sparse-header (gnus-read-header article))
5846 ((vectorp header)
5848 (setq article (mail-header-id header)))
5852 (gnus-request-pseudo-article header))))
5857 (vectorp header))
5859 (mail-header-id header))))
5980 (gnus-summary-update-article do-update-line sparse-header)
5993 :type 'hook)
6019 "\C-c\C-f\C-m" message-goto-mail-followup-to
6023 "\C-c\C-f\C-a" message-generate-unsubscribed-mail-followup-to
6058 ["Mail-Followup-To" message-goto-mail-followup-to t]
6072 (set (make-local-variable 'mail-header-separator) "")
6082 This will have permanent effect only in mail groups.
6095 ,(or (mail-header-references gnus-current-headers) "")
6191 :type 'regexp)
6198 :type 'regexp)
6203 "Regular expression that matches a localpart of mail addresses or MIDs."
6206 :type 'regexp)
6213 :type '(choice (function-item :tag "Man" manual-entry)
6226 :type '(choice (const "http://www.tex.ac.uk/tex-archive/")
6235 :type '(choice (function-item :tag "Browse Url" browse-url)
6243 :type '(choice (const "^/?tex-archive/\\|/")
6256 :type 'regexp)
6258 (defcustom gnus-button-mid-or-mail-regexp
6262 "Regular expression that matches a message ID or a mail address."
6265 :type 'regexp)
6267 (defcustom gnus-button-prefer-mid-or-mail 'gnus-button-mid-or-mail-heuristic
6269 Strings like this can be either a message ID or a mail address. If it is one
6270 of the symbols `mid' or `mail', Gnus will always assume that the string is a
6271 message ID or a mail address, respectively. If this variable is set to the
6274 must return `mid', `mail', `invalid' or `ask'."
6277 :type '(choice (function-item :tag "Heuristic function"
6278 gnus-button-mid-or-mail-heuristic)
6281 (const mail)))
6283 (defcustom gnus-button-mid-or-mail-heuristic-alist
6311 ;; compensation for TDMA dated mail addresses:
6335 "An alist of \(RATE . REGEXP\) pairs for `gnus-button-mid-or-mail-heuristic'.
6337 A negative RATE indicates a message IDs, whereas a positive indicates a mail
6341 :type '(repeat (cons (number :tag "Rate")
6344 (defun gnus-button-mid-or-mail-heuristic (mid-or-mail)
6345 "Guess whether MID-OR-MAIL is a message ID or a mail address.
6346 Returns `mid' if MID-OR-MAIL is a message IDs, `mail' if it's a mail
6349 (list gnus-button-mid-or-mail-heuristic-alist)
6352 (length (gnus-replace-in-string mid-or-mail "^\\(.*\\)@.*$" "\\1")))
6353 (gnus-message 8 "`%s', length of local part=`%s'." mid-or-mail lpartlen)
6360 mid-or-mail)
6361 (gnus-message 8 "`%s' is a known mail address." mid-or-mail)
6362 (setq result 'mail))
6363 (when (string-match "@.*@\\| " mid-or-mail)
6364 (gnus-message 8 "`%s' is invalid." mid-or-mail)
6373 (when (string-match regexp mid-or-mail)
6377 mid-or-mail regexp rate result)))
6381 mid-or-mail result))
6383 (gnus-message 9 "`%s' matched (>= lpartlen 12)" mid-or-mail)
6385 ((string-match "[0-9][^0-9]+[0-9].*@" mid-or-mail)
6386 ;; Long local part should contain realname if e-mail address,
6393 mid-or-mail rate result))
6395 mid-or-mail)
6400 mid-or-mail -5.0 result))
6404 9 "`%s', rate `%s', result `%s'." mid-or-mail 5.0 result)))))
6405 (gnus-message 8 "`%s': Final rate is `%s'." mid-or-mail result)
6411 ((> result 10.0) 'mail)
6414 (defun gnus-button-handle-mid-or-mail (mid-or-mail)
6415 (let* ((pref gnus-button-prefer-mid-or-mail) guessed
6416 (url-mid (concat "news" ":" mid-or-mail))
6417 (url-mailto (concat "mailto" ":" mid-or-mail)))
6418 (gnus-message 9 "mid-or-mail=%s" mid-or-mail)
6423 (gnus-replace-in-string mid-or-mail "^<\\|>$" "")))
6424 (if (or (eq 'mid guessed) (eq 'mail guessed))
6429 (if (y-or-n-p (concat "Is <" mid-or-mail "> a mail address? "))
6430 (setq pref 'mail)
6435 ((eq pref 'mail)
6527 :type 'integer)
6539 :type 'integer)
6551 :type 'integer)
6554 "*Integer that says how many buttons for news or mail messages will appear.
6557 ;; mail addresses, MIDs, URLs for news, ...
6560 :type 'integer)
6569 :type 'integer)
6683 ;; MID or mail: To avoid too many false positives we don't try to catch
6684 ;; all kind of allowed MIDs or mail addresses. Domain part must contain
6688 (gnus-button-mid-or-mail-regexp
6689 0 (>= gnus-button-message-level 5) gnus-button-handle-mid-or-mail 1))
6704 :type '(repeat (list (choice regexp variable sexp)
6712 (defcustom gnus-header-button-alist
6718 0 (>= gnus-button-message-level 0) gnus-msg-mail 0)
6736 HEADER is a regexp to match a header. For a fuller explanation, see
6740 :type '(repeat (list (regexp :tag "Header")
6798 "Highlight article headers as specified by `gnus-header-face-alist'."
6803 (let ((alist gnus-header-face-alist)
6807 entry regexp header-face field-face from hpoints fpoints)
6816 header-face (nth 1 entry)
6824 (when (and header-face
6827 (gnus-put-text-property from (point) 'face header-face))
6916 (alist gnus-header-button-alist)
6925 ;; Each header matching the entry.
6932 ;; Each match within a header.
6973 (if (text-property-any end (point-max) 'article-type 'signature)
6975 (gnus-delete-wash-type 'signature)
6977 'article-type 'signature end (point-max)
6978 (cons 'article-type (cons 'signature
6980 (gnus-add-wash-type 'signature)
6982 'article-type nil end (point-max)
6983 (cons 'article-type (cons 'signature
7022 (defun gnus-parse-news-url (url)
7052 (gnus-parse-news-url url)
7091 (t (error "Can't parse %s" url))))
7105 (error "Can't parse %s" url)))
7133 (error "Can't parse %s" address)
7144 (defun gnus-url-parse-query-string (query &optional downcase)
7163 ;; Send mail to someone
7167 (setq args (gnus-url-parse-query-string
7176 (gnus-msg-mail)
7225 article-type annotation))
7257 article-type annotation))
7282 (defvar gnus-decode-header-methods
7283 '(mail-decode-encoded-word-region)
7293 mail-decode-encoded-word-region
7297 (defvar gnus-decode-header-methods-cache nil)
7299 (defun gnus-multi-decode-header (start end)
7301 (unless (and gnus-decode-header-methods-cache
7303 (car gnus-decode-header-methods-cache)))
7304 (setq gnus-decode-header-methods-cache (list gnus-newsgroup-name))
7307 (nconc gnus-decode-header-methods-cache (list x))
7310 (nconc gnus-decode-header-methods-cache
7312 gnus-decode-header-methods))
7313 (let ((xlist gnus-decode-header-methods-cache))
7324 (defun gnus-treat-article (condition &optional part-number total-parts type)
7328 (treated-type
7329 (or (not type)
7333 (when (string-match (pop list) type)
7345 treated-type)
7356 (defvar type)
7381 (equal (car val) type))
7415 (let ((mail-parse-charset gnus-newsgroup-charset)
7416 (mail-parse-ignored-charsets gnus-newsgroup-ignored-charsets)
7424 (or (mail-header-references gnus-current-headers) ""))
7441 (message-remove-header "MIME-Version")
7448 (message-options-set 'message-sender user-mail-address)
7449 (message-options-set 'message-recipients user-mail-address)
7470 %t The security MIME type
7477 %t The security MIME type
7483 '((?t gnus-tmp-type ?s)
7571 (gnus-tmp-type
7602 article-type annotation
7626 (unless (gnus-unbuttonized-mime-type-p (car handle))
7631 (unless (gnus-unbuttonized-mime-type-p (car handle))