(delete-process "article-x-face"))
(let ((inhibit-point-motion-hooks t)
(case-fold-search t)
+ (x-faces "")
from last)
+ (when (gnus-buffer-live-p gnus-original-article-buffer)
+ (with-current-buffer gnus-original-article-buffer
+ (save-restriction
+ (article-narrow-to-head)
+ (while (re-search-forward "^X-Face:" nil t)
+ (setq x-faces
+ (concat
+ x-faces
+ (buffer-substring (match-beginning 0)
+ (1- (re-search-forward
+ "^\\($\\|[^ \t]\\)" nil t)))))))))
(save-restriction
(article-narrow-to-head)
- (goto-char (point-min))
(setq from (message-fetch-field "from"))
+ (when (gnus-buffer-live-p gnus-original-article-buffer)
+ (message-remove-header "X-Face")
+ (goto-char (point-min))
+ (insert x-faces))
(goto-char (point-min))
(while (and gnus-article-x-face-command
(not last)
(not (string-match gnus-article-x-face-too-ugly
from))))
;; Has to be present.
- (re-search-forward "^X-Face: " nil t))
+ (re-search-forward "^X-Face:[\t ]*" nil t))
;; This used to try to do multiple faces (`while' instead of
;; `when' above), but (a) sending multiple EOFs to xv doesn't
;; work (b) it can crash some versions of Emacs (c) are
(number-to-string (nth 3 dtime))
(let ((digit (% (nth 3 dtime) 10)))
(cond
- ((memq (nth 3 dtime) '(11 12)) "th")
+ ((memq (nth 3 dtime) '(11 12 13)) "th")
((= digit 1) "st")
((= digit 2) "nd")
((= digit 3) "rd")