From: akr Date: Tue, 18 Aug 1998 11:29:18 +0000 (+0000) Subject: * DOODLE-TIPS: Change `gnus-unstructured-field-decoder' and X-Git-Tag: doodle-1_9_2~45 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=3a12cf12b2cb6949dc169140932edc6356a068b7;p=elisp%2Fflim.git * DOODLE-TIPS: Change `gnus-unstructured-field-decoder' and `gnus-structured-field-decoder' usable by FLAM-DOODLE and FLIM. * ew-data.el (ew-mark-phrase): Update both ends of fragments after fragments separation. * ew-unit.el (ew-charset-aliases): Add 'x-ctext. --- diff --git a/ChangeLog b/ChangeLog index 906c706..cdb54b1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,6 +1,17 @@ -1998-08-19 Tanaka Akira +1998-08-18 Tanaka Akira + + * DOODLE-TIPS: Change `gnus-unstructured-field-decoder' and + `gnus-structured-field-decoder' usable by FLAM-DOODLE and FLIM. + + * ew-data.el (ew-mark-phrase): Update both ends of fragments after + fragments separation. + + * ew-unit.el (ew-charset-aliases): Add 'x-ctext. + +1998-08-18 Tanaka Akira - * mime-def.el (mime-library-version-string): bump up to FLAM-DOODLE 1.9.1. + * mime-def.el (mime-library-version-string): bump up to + FLAM-DOODLE 1.9.1. 1998-08-18 Tanaka Akira diff --git a/DOODLE-TIPS b/DOODLE-TIPS index 5d979a0..fe51fbb 100644 --- a/DOODLE-TIPS +++ b/DOODLE-TIPS @@ -12,11 +12,15 @@ because DOODLE cannot decide whether an atom is in phrase or not without field name information. (setq gnus-unstructured-field-decoder - (lambda (string) - (let ((ew-ignore-76bytes-limit t)) - (ew-cut-cr-lf (ew-decode-field "Subject" (ew-lf-to-crlf string)))))) + (lambda (string) + (if (fboundp 'ew-decode-field) + (let ((ew-ignore-76bytes-limit t)) + (ew-cut-cr-lf (ew-decode-field "Subject" (ew-lf-to-crlf string)))) + (eword-decode-and-unfold-structured-field string)))) (setq gnus-structured-field-decoder - (lambda (string) - (let ((ew-ignore-76bytes-limit t)) - (ew-cut-cr-lf (ew-decode-field "From" (ew-lf-to-crlf string)))))) + (lambda (string) + (if (fboundp 'ew-decode-field) + (let ((ew-ignore-76bytes-limit t)) + (ew-cut-cr-lf (ew-decode-field "From" (ew-lf-to-crlf string) 'ew-cut-cr-lf))) + (eword-decode-unstructured-field-body (std11-unfold-string string) 'must-unfold)))) diff --git a/ew-data.el b/ew-data.el index bd11f24..afa2754 100644 --- a/ew-data.el +++ b/ew-data.el @@ -115,7 +115,9 @@ (if ew-decode-quoted-encoded-word '(ew:atom-tok ew:qs-texts-tok) - '(ew:atom-tok)))) + '(ew:atom-tok))) + (setq frag1 (get (get frag1 'prev-frag) 'next-frag)) + (setq frag2 (get (get frag2 'next-frag) 'prev-frag))) (while (not (eq frag1 frag2)) (unless (ew-comment-frag-p frag2) (put frag2 'decode 'ew-decode-phrase)) diff --git a/ew-unit.el b/ew-unit.el index 74b379f..f115fab 100644 --- a/ew-unit.el +++ b/ew-unit.el @@ -75,7 +75,10 @@ (defconst ew-charset-aliases '((us-ascii . iso-8859-1) - (iso-2022-jp-2 . iso-2022-7bit-ss2))) + (iso-2022-jp-2 . iso-2022-7bit-ss2) + (x-ctext . ctext) + )) + (defun ew-char-decoder (charset) (catch 'return (setq charset (downcase charset)) diff --git a/eword-decode.el b/eword-decode.el index fda1696..3144048 100644 --- a/eword-decode.el +++ b/eword-decode.el @@ -366,8 +366,8 @@ mime-charset, it decodes non-ASCII bit patterns as the mime-charset. Otherwise it decodes non-ASCII bit patterns as the default-mime-charset." (interactive "*r") - (rotate-memo args-eword-decode-region - (list start end (buffer-substring start end) unfolding must-unfold code-conversion)) +;; (rotate-memo args-eword-decode-region +;; (list start end (buffer-substring start end) unfolding must-unfold code-conversion)) (save-excursion (save-restriction (narrow-to-region start end) @@ -410,8 +410,7 @@ Otherwise it decodes non-ASCII bit patterns as the default-mime-charset. If SEPARATOR is not nil, it is used as header separator." (interactive "*") - (rotate-memo args-eword-decode-header - (list code-conversion)) +;; (rotate-memo args-eword-decode-header (list code-conversion)) (unless code-conversion (message "eword-decode-header is called with no code-conversion")) (if (and code-conversion @@ -420,7 +419,7 @@ If SEPARATOR is not nil, it is used as header separator." (save-excursion (save-restriction (std11-narrow-to-header separator) - (rotate-memo header-eword-decode-header (buffer-substring (point-min) (point-max))) +;; (rotate-memo header-eword-decode-header (buffer-substring (point-min) (point-max))) (if code-conversion (let (beg p end field-name field-body len) (goto-char (point-min)) @@ -711,8 +710,8 @@ If MAX-COLUMN is omitted, `fill-column' is used. If MUST-UNFOLD is non-nil, it unfolds and eliminates line-breaks even if there are in decoded encoded-words (generated by bad manner MUA such as a version of Net$cape)." - (rotate-memo args-eword-decode-and-fold-structured-field - (list string start-column max-column must-unfold)) +;; (rotate-memo args-eword-decode-and-fold-structured-field +;; (list string start-column max-column must-unfold)) (or max-column (setq max-column fill-column)) (let* ((ew-decode-field-default-syntax '(ew-scan-unibyte-std11)) @@ -752,8 +751,7 @@ characters are regarded as variable `default-mime-charset'. If an encoded-word is broken or your emacs implementation can not decode the charset included in it, it is not decoded." - (rotate-memo args-eword-decode-and-unfold-structured-field - (list string)) +;; (rotate-memo args-eword-decode-and-unfold-structured-field (list string)) (let* ((ew-decode-field-default-syntax '(ew-scan-unibyte-std11)) (decoded (ew-decode-field "" (ew-lf-crlf-to-crlf string) @@ -775,8 +773,8 @@ decode the charset included in it, it is not decoded. If MUST-UNFOLD is non-nil, it unfolds and eliminates line-breaks even if there are in decoded encoded-words (generated by bad manner MUA such as a version of Net$cape)." - (rotate-memo args-eword-decode-structured-field-body - (list string must-unfold start-column max-column)) +;; (rotate-memo args-eword-decode-structured-field-body +;; (list string must-unfold start-column max-column)) (if start-column ;; fold with max-column (folding is not implemented.) (let* ((ew-decode-field-default-syntax '(ew-scan-unibyte-std11)) @@ -805,8 +803,8 @@ decode the charset included in it, it is not decoded. If MUST-UNFOLD is non-nil, it unfolds and eliminates line-breaks even if there are in decoded encoded-words (generated by bad manner MUA such as a version of Net$cape)." - (rotate-memo args-eword-decode-unstructured-field-body - (list string must-unfold)) +;; (rotate-memo args-eword-decode-unstructured-field-body +;; (list string must-unfold)) (let ((decoded (ew-decode-field "" (ew-lf-crlf-to-crlf string) (if must-unfold 'ew-cut-cr-lf)))) @@ -819,8 +817,7 @@ If no name can be extracted, FULL-NAME will be nil. It decodes non us-ascii characters in FULL-NAME encoded as encoded-words or invalid \"raw\" string. \"Raw\" non us-ascii characters are regarded as variable `default-mime-charset'." - (rotate-memo args-eword-extract-address-components - (list string)) +;; (rotate-memo args-eword-extract-address-components (list string)) (let* ((structure (car (std11-parse-address (eword-lexical-analyze (std11-unfold-string string) 'must-unfold))))