*** empty log message ***
authorLars Magne Ingebrigtsen <larsi@gnus.org>
Sun, 25 Oct 1998 05:24:05 +0000 (05:24 +0000)
committerLars Magne Ingebrigtsen <larsi@gnus.org>
Sun, 25 Oct 1998 05:24:05 +0000 (05:24 +0000)
20 files changed:
GNUS-NEWS
lisp/ChangeLog
lisp/gnus-art.el
lisp/gnus-ems.el
lisp/gnus-spec.el
lisp/gnus-start.el
lisp/gnus-sum.el
lisp/gnus-util.el
lisp/gnus-xmas.el
lisp/gnus.el
lisp/mailcap.el
lisp/mm-bodies.el
lisp/mm-decode.el
lisp/mm-uu.el
lisp/nnheader.el
lisp/nnml.el
lisp/pop3.el
texi/ChangeLog
texi/gnus.texi
texi/message.texi

index 4059d5b..a0ba334 100644 (file)
--- a/GNUS-NEWS
+++ b/GNUS-NEWS
@@ -1,5 +1,7 @@
 ** Gnus changes.
 
+*** Gnus is now a MIME-capable reader.  See the manual for details. 
+
 *** gnus-auto-select-first can now be a function to be
 called to position point.
 
index fe38344..8eb0615 100644 (file)
@@ -1,3 +1,89 @@
+Sun Oct 25 06:23:13 1998  Lars Magne Ingebrigtsen  <larsi@menja.ifi.uio.no>
+
+       * gnus.el: Pterodactyl Gnus v0.39 is released.
+
+1998-10-25 00:34:39  Lars Magne Ingebrigtsen  <larsi@gnus.org>
+
+       * gnus-art.el (gnus-ignored-mime-types): New variable.
+       (gnus-mime-display-single): Use it.
+       (gnus-treatment-function-alist): New variable.
+
+       * gnus.el (gnus-mime): New group.
+
+       * gnus-art.el (gnus-mime-display-alternative): Don't destroy
+       things for other parts.
+       (gnus-mime-display-alternative): Place point.
+
+       * gnus.el: autoload gnus-uu-post-news.
+
+       * mailcap.el (mailcap-mailcap-entry-passes-test): Also check
+       needsterm/DISPLAY. 
+
+       * mm-decode.el (mm-display-part): Default to inline text/.*
+       parts. 
+
+       * mm-bodies.el (mm-decode-content-transfer-encoding): Default to
+       8bit. 
+
+       * gnus-art.el (gnus-mime-copy-part): Use normal-mode.
+       (gnus-mime-display-single): Inline all text parts.
+       (gnus-article-narrow-to-signature): Removed mime:: stubs.
+
+1998-10-24 21:38:37  Lars Magne Ingebrigtsen  <larsi@gnus.org>
+
+       * nnml.el (nnml-possibly-create-directory): Rewrite.
+       (nnml-request-create-group): Change to right server.
+
+       * gnus-xmas.el (gnus-xmas-define): Use byte-code-function-p. 
+
+       * gnus-sum.el (gnus-set-mode-line): Use truncate-string-to-width. 
+
+       * gnus.el: rmail-output-to-rmail-file autoload.
+
+       * gnus-util.el (gnus-output-to-rmail): Didn't work if not in
+       Gnus. 
+
+       * nnheader.el (nnheader-parse-head): Checked wrong variable.
+
+       * gnus-sum.el (gnus-summary-update-mark): Ignore nil'd marks.
+
+Tue Oct 20 23:37:43 1998  Shenghuo ZHU  <zsh@cs.rochester.edu>
+
+       * gnus-art.el (gnus-mime-display-mixed): Multipart in
+       mixed part.
+
+Tue Oct 20 23:36:43 1998  Shenghuo ZHU  <zsh@cs.rochester.edu>
+
+       * gnus-sum.el (gnus-summary-exit): Use mm-destroy-parts.
+       
+       * gnus-sum.el (gnus-summary-exit-no-update): Ditto.
+
+Tue Oct 20 16:22:51 1998  Shenghuo ZHU  <zsh@cs.rochester.edu>
+
+       * mm-uu.el (mm-uu-dissect): Create pseudo multipart head.
+
+1998-10-24 20:51:53  Lars Magne Ingebrigtsen  <larsi@gnus.org>
+
+       * gnus-sum.el (gnus-valid-move-group-p): Make sure group has a
+       value. 
+
+       * gnus-art.el (gnus-article-hidden-text-p): Return nil when not
+       hidden. 
+
+       * gnus-spec.el (gnus-update-format-specifications): Use the
+       article mode line spec.
+
+       * gnus-art.el (gnus-insert-mime-button): Put right type.
+       (gnus-insert-prev-page-button): Ditto.
+       (gnus-insert-next-page-button): Dutti.
+
+       * pop3.el: New version installed.
+
+Sat Oct 24 16:48:51 1998  Shenghuo ZHU  <zsh@cs.rochester.edu>
+
+       * mm-uu.el (mm-uu-dissect): Delete the begining spurious newline
+       and display last part.
+
 Sat Oct 24 20:31:55 1998  Lars Magne Ingebrigtsen  <larsi@menja.ifi.uio.no>
 
        * gnus.el: Pterodactyl Gnus v0.38 is released.
@@ -59,21 +145,6 @@ Sat Oct 24 07:41:42 1998  Lars Magne Ingebrigtsen  <larsi@menja.ifi.uio.no>
        (gnus-parse-format): understand the %< %> specifiers
        (gnus-parse-complex-format): ditto.
 
-Tue Oct 20 23:37:43 1998  Shenghuo ZHU  <zsh@cs.rochester.edu>
-
-       * gnus-art.el (gnus-mime-display-mixed): Multipart in
-       mixed part.
-
-Tue Oct 20 23:36:43 1998  Shenghuo ZHU  <zsh@cs.rochester.edu>
-
-       * gnus-sum.el (gnus-summary-exit): Use mm-destroy-parts.
-       
-       * gnus-sum.el (gnus-summary-exit-no-update): Ditto.
-
-Tue Oct 20 16:22:51 1998  Shenghuo ZHU  <zsh@cs.rochester.edu>
-
-       * mm-uu.el (mm-uu-dissect): Create pseudo multipart head.
-
 1998-10-24 06:31:33  Lars Magne Ingebrigtsen  <larsi@gnus.org>
 
        * gnus.el: Changed following-char to char-after throughout.
@@ -153,6 +224,23 @@ Tue Oct 20 02:16:36 1998  Shenghuo ZHU  <zsh@cs.rochester.edu>
 
        * mm-decode.el (mm-display-external): Check before selecting.
 
+Sat Sep 26 02:03:00 1998  Shenghuo ZHU  <zsh@cs.rochester.edu>
+
+       * gnus-sum.el (gnus-multi-decode-encoded-word-string): Rewrite. 
+       
+       * gnus-sum.el (gnus-decode-encoded-word-methods): New variable.
+       
+       * gnus-sum.el (gnus-decode-encoded-word-methods-cache): New
+       variable.
+       
+       * gnus-sum.el (gnus-encoded-word-method-alist): Deleted.
+       
+       * gnus-art.el (gnus-decode-header-methods): New variable.
+
+       * gnus-art.el (gnus-decode-header-methods-cache): New variable.
+
+       * gnus-art.el (gnus-multi-decode-header): New function.
+       
 Tue Oct 20 00:24:16 1998  Lars Magne Ingebrigtsen  <larsi@menja.ifi.uio.no>
 
        * gnus.el: Pterodactyl Gnus v0.35 is released.
index 691d1a2..0bb90f5 100644 (file)
@@ -567,8 +567,25 @@ displayed by the first non-nil matching CONTENT face."
     ("\264" "'"))
   "Table for MS-to-Latin1 translation.")
 
+(defcustom gnus-ignored-mime-types '("text/x-vcard")
+  "List of MIME types that should be ignored by Gnus."
+  :group 'gnus-mime
+  :type '(repeat regexp))
+
+(defcustom gnus-treat-body-highlight-signature t
+  "Highlight the signature."
+  :group 'gnus-article
+  :type '(choice (const :tag "Off" nil)
+                (const :tag "On" t)
+                (const :tag "Last" last)
+                (integer :tag "Less")))
+
 ;;; Internal variables
 
+(defvar gnus-treatment-function-alist ()
+  '((gnus-treat-body-highlight-signature gnus-article-highlight-signature nil)
+    ))
+
 (defvar gnus-article-mime-handle-alist nil)
 (defvar article-lapsed-timer nil)
 (defvar gnus-article-current-summary nil)
@@ -1192,21 +1209,10 @@ always hide."
       (while (re-search-forward "^[ \t]*\n" nil t)
        (replace-match "" t t)))))
 
-(defvar mime::preview/content-list)
-(defvar mime::preview-content-info/point-min)
 (defun gnus-article-narrow-to-signature ()
   "Narrow to the signature; return t if a signature is found, else nil."
   (widen)
   (let ((inhibit-point-motion-hooks t))
-    (when (and (boundp 'mime::preview/content-list)
-              mime::preview/content-list)
-      ;; We have a MIMEish article, so we use the MIME data to narrow.
-      (let ((pcinfo (car (last mime::preview/content-list))))
-       (ignore-errors
-         (narrow-to-region
-          (funcall (intern "mime::preview-content-info/point-min") pcinfo)
-          (point-max)))))
-
     (when (gnus-article-search-signature)
       (forward-line 1)
       ;; Check whether we have some limits to what we consider
@@ -1312,7 +1318,7 @@ means show, 0 means toggle."
            (text-property-any (1+ pos) (point-max) 'article-type type)))
     (if pos
        'hidden
-      'shown)))
+      nil)))
 
 (defun gnus-article-show-hidden-text (type &optional hide)
   "Show all hidden text of type TYPE.
@@ -2269,9 +2275,9 @@ If ALL-HEADERS is non-nil, no headers are hidden."
                         (mail-content-type-get (mm-handle-type handle)
                                                'filename)
                         "*decoded*")))))
-    (set-buffer-major-mode buffer)
     (switch-to-buffer buffer)
     (insert contents)
+    (normal-mode)
     (goto-char (point-min))))
 
 (defun gnus-mime-inline-part ()
@@ -2342,7 +2348,7 @@ If ALL-HEADERS is non-nil, no headers are hidden."
                 keymap ,gnus-mime-button-map
                 gnus-callback gnus-mm-display-part
                 gnus-part ,gnus-tmp-id
-                gnus-type annotation
+                article-type annotation
                 gnus-data ,handle))
     (setq e (point))
     (widget-convert-button 'link b e :action 'gnus-widget-press-button
@@ -2382,67 +2388,84 @@ If ALL-HEADERS is non-nil, no headers are hidden."
        (gnus-mime-display-single handle)))))
 
 (defun gnus-mime-display-single (handle)
-  (let (display)
-    (when (and (mm-automatic-display-p
-               (car (mm-handle-type handle)))
-              (mm-inlinable-part-p (car (mm-handle-type handle)))
-              (or (not (mm-handle-disposition handle))
-                  (equal (car (mm-handle-disposition handle))
-                         "inline")))
-      (setq display t))
-    (let ((id (1+ (length gnus-article-mime-handle-alist))))
-      (push (cons id handle) gnus-article-mime-handle-alist)
-      (gnus-insert-mime-button handle id (list display)))
-    (insert "\n\n")
-    (when display
-      (forward-line -2)
-      (mm-display-part handle t)
-      (goto-char (point-max)))))
-
-(defun gnus-mime-display-alternative (handles &optional preferred)
+  (let ((type (car (mm-handle-type handle)))
+       (ignored gnus-ignored-mime-types)
+       display text)
+    (catch 'ignored
+      (progn
+       (while ignored
+         (when (string-match (pop ignored) type)
+           (throw 'ignored nil)))
+       (if (and (mm-automatic-display-p type)
+                  (mm-inlinable-part-p type)
+                  (or (not (mm-handle-disposition handle))
+                      (equal (car (mm-handle-disposition handle))
+                             "inline")))
+           (setq display t)
+         (when (equal (car (split-string type "/"))
+                      "text")
+           (setq text t)))
+       (let ((id (1+ (length gnus-article-mime-handle-alist))))
+         (push (cons id handle) gnus-article-mime-handle-alist)
+         (gnus-insert-mime-button handle id (list (or display text))))
+       (insert "\n\n")
+       (cond
+        (display
+         (forward-line -2)
+         (mm-display-part handle t)
+         (goto-char (point-max)))
+        (text
+         (forward-line -2)
+         (insert "\n")
+         (mm-insert-inline handle (mm-get-part handle))
+         (goto-char (point-max))))))))
+
+(defun gnus-mime-display-alternative (handles &optional preferred ibegend)
   (let* ((preferred (mm-preferred-alternative handles preferred))
         (ihandles handles)
         (point (point))
-        handle buffer-read-only from)
-    (goto-char (point-min))
-    (search-forward "\n\n" nil t)
-    (delete-region (point) (point-max))
-    (when preferred
-      ;; Top-level call; we clean up.
-      (mm-remove-parts gnus-article-mime-handles)
-      (setq gnus-article-mime-handles handles
-           gnus-article-mime-handle-alist nil))
-    (while (setq handle (pop handles))
-      (gnus-add-text-properties
-       (setq from (point))
-       (progn
-        (insert (format "[%c] %-18s"
-                        (if (equal handle preferred) ?* ? )
-                        (if (stringp (car handle))
-                            (car handle)
-                          (car (mm-handle-type handle)))))
-        (point))
-       `(local-map ,gnus-mime-button-map
-                  ,gnus-mouse-face-prop ,gnus-article-mouse-face
-                  face ,gnus-article-button-face
-                  keymap ,gnus-mime-button-map
-                  gnus-callback
-                  (lambda (handles)
-                    (gnus-mime-display-alternative
-                     ',ihandles ,(if (stringp (car handle))
-                                     (car handle)
-                                   (car (mm-handle-type handle)))))
-                  gnus-data ,handle))
-      (widget-convert-button 'link from (point)
-                            :action 'gnus-widget-press-button
-                            :button-keymap gnus-widget-button-keymap)
-      (insert "  "))
-    (insert "\n\n")
-    (when preferred
-      (if (stringp (car preferred))
-         (gnus-display-mime preferred)
-       (mm-display-part preferred)))
-    (goto-char point)))
+        handle buffer-read-only from props begend)
+    (save-restriction
+      (when ibegend
+       (narrow-to-region (car ibegend) (cdr ibegend))
+       (delete-region (point-min) (point-max))
+       (mm-remove-parts handles))
+      (setq begend (list (point-marker)))
+      (while (setq handle (pop handles))
+       (gnus-add-text-properties
+        (setq from (point))
+        (progn
+          (insert (format "[%c] %-18s"
+                          (if (equal handle preferred) ?* ? )
+                          (if (stringp (car handle))
+                              (car handle)
+                            (car (mm-handle-type handle)))))
+          (point))
+        `(gnus-callback
+          (lambda (handles)
+            (gnus-mime-display-alternative
+             ',ihandles ,(if (stringp (car handle))
+                             (car handle)
+                           (car (mm-handle-type handle)))
+             ',begend))
+          local-map ,gnus-mime-button-map
+          ,gnus-mouse-face-prop ,gnus-article-mouse-face
+          face ,gnus-article-button-face
+          keymap ,gnus-mime-button-map
+          gnus-data ,handle))
+       (widget-convert-button 'link from (point)
+                              :action 'gnus-widget-press-button
+                              :button-keymap gnus-widget-button-keymap)
+       (insert "  "))
+      (insert "\n\n")
+      (when preferred
+       (if (stringp (car preferred))
+           (gnus-display-mime preferred)
+         (mm-display-part preferred)
+         (goto-char (point-max))
+         (setcdr begend (point-marker)))))
+    (when ibegend
+      (goto-char point))))
 
 (defun gnus-article-wash-status ()
   "Return a string which display status of article washing."
@@ -2456,7 +2479,7 @@ If ALL-HEADERS is non-nil, no headers are hidden."
          (signature (gnus-article-hidden-text-p 'signature))
          (overstrike (gnus-article-hidden-text-p 'overstrike))
          (emphasis (gnus-article-hidden-text-p 'emphasis)))
-      (format "%c%c%c%c%c%c%c"
+      (format "%c%c%c%c%c%c"
              (if cite ?c ? )
              (if (or headers boring) ?h ? )
              (if (or pgp pem) ?p ? )
@@ -3510,7 +3533,7 @@ forbidden in URL encoding."
      gnus-prev-page-line-format nil
      `(gnus-prev t local-map ,gnus-prev-page-map
                 gnus-callback gnus-article-button-prev-page
-                gnus-type annotation))))
+                article-type annotation))))
 
 (defvar gnus-next-page-map nil)
 (unless gnus-next-page-map
@@ -3541,7 +3564,7 @@ forbidden in URL encoding."
                      `(gnus-next
                        t local-map ,gnus-next-page-map
                        gnus-callback gnus-article-button-next-page
-                       gnus-type annotation))))
+                       article-type annotation))))
 
 (defun gnus-article-button-next-page (arg)
   "Go to the next page."
@@ -3559,6 +3582,44 @@ forbidden in URL encoding."
     (gnus-article-prev-page)
     (select-window win)))
 
+(defvar gnus-decode-header-methods
+  '(mail-decode-encoded-word-region)
+  "List of methods used to decode headers
+
+This variable is a list of FUNCTION or (REGEXP . FUNCTION). If item is
+FUNCTION, FUNCTION will be apply to all newsgroups. If item is a
+(REGEXP . FUNCTION), FUNCTION will be only apply to thes newsgroups
+whose names match REGEXP.
+
+For example: 
+((\"chinese\" . gnus-decode-encoded-word-region-by-guess)
+ mail-decode-encoded-word-region 
+ (\"chinese\" . rfc1843-decode-region))
+")
+
+(defvar gnus-decode-header-methods-cache nil)
+
+(defun gnus-multi-decode-header (start end)
+  "Apply the functions from `gnus-encoded-word-methods' that match."
+  (unless (and gnus-decode-header-methods-cache
+              (eq gnus-newsgroup-name 
+                  (car gnus-decode-header-methods-cache)))
+    (setq gnus-decode-header-methods-cache (list gnus-newsgroup-name))
+    (mapc '(lambda (x) 
+            (if (symbolp x)
+                (nconc gnus-decode-header-methods-cache (list x))
+              (if (and gnus-newsgroup-name 
+                       (string-match (car x) gnus-newsgroup-name))
+                  (nconc gnus-decode-header-methods-cache 
+                         (list (cdr x))))))
+         gnus-decode-header-methods))
+  (let ((xlist gnus-decode-header-methods-cache))
+    (pop xlist)
+    (save-restriction
+      (narrow-to-region start end)
+      (while xlist
+       (funcall (pop xlist) (point-min) (point-max))))))
+
 (gnus-ems-redefine)
 
 (provide 'gnus-art)
index aa25f3c..2438b31 100644 (file)
@@ -74,7 +74,7 @@
            (valstr (if (numberp val)
                        (int-to-string val) val)))
        (if (> (length valstr) (, max-width))
-          (truncate-string valstr (, max-width))
+          (truncate-string-to-width valstr (, max-width))
         valstr))))
 
 (eval-and-compile
       (while funcs
        (unless (fboundp (car funcs))
          (fset (car funcs) 'gnus-dummy-func))
-       (setq funcs (cdr funcs))))))
-  (unless (fboundp 'file-regular-p)
-    (defun file-regular-p (file)
-      (and (not (file-directory-p file))
-          (not (file-symlink-p file))
-          (file-exists-p file))))
-  (unless (fboundp 'face-list)
-    (defun face-list (&rest args))))
+       (setq funcs (cdr funcs)))))))
 
 (eval-and-compile
   (let ((case-fold-search t))
          (format "%4d: %-20s"
                  gnus-tmp-lines
                  (if (> (length gnus-tmp-name) 20)
-                     (truncate-string gnus-tmp-name 20)
+                     (truncate-string-to-width gnus-tmp-name 20)
                    gnus-tmp-name))
          gnus-tmp-closing-bracket)
         (point))
index b4e44e3..0cd6ed1 100644 (file)
                  (gnus-parse-format
                   new-format
                   (symbol-value
-                   (intern (format "gnus-%s-line-format-alist"
-                                   (if (eq type 'article-mode)
-                                       'summary-mode type))))
+                   (intern (format "gnus-%s-line-format-alist" type)))
                   (not (string-match "mode$" (symbol-name type))))))
          ;; Enter the new format spec into the list.
          (if entry
@@ -531,7 +529,7 @@ If PROPS, insert the result."
                       (not (eq 'byte-code (car form)))
                       ;; Under XEmacs, it's (funcall #<compiled-function ...>)
                       (not (and (eq 'funcall (car form))
-                                (compiled-function-p (cadr form)))))
+                                (byte-code-function-p (cadr form)))))
              (fset 'gnus-tmp-func `(lambda () ,form))
              (byte-compile 'gnus-tmp-func)
              (setcar (cddr entry) (gnus-byte-code 'gnus-tmp-func))))))
index 2956d33..eec5d5e 100644 (file)
@@ -1705,7 +1705,6 @@ newsgroup."
                (gnus-message 5 "%sdone" mesg))))))
        (setq methods (cdr methods))))))
 
-
 (defun gnus-ignored-newsgroups-has-to-p ()
   "Non-nil iff gnus-ignored-newsgroups includes \"^to\\\\.\" as an element."
   ;; note this regexp is the same as:
index deb4864..6d38a3b 100644 (file)
@@ -1008,22 +1008,42 @@ variable (string, integer, character, etc).")
 
 ;; MIME stuff.
 
-(defvar gnus-encoded-word-method-alist
-  '(("chinese" mail-decode-encoded-word-string rfc1843-decode-string)
-    (".*" mail-decode-encoded-word-string))
-  "Alist of regexps (to match group names) and lists of functions to be applied.")
+(defvar gnus-decode-encoded-word-methods
+  '(mail-decode-encoded-word-string)
+  "List of methods used to decode encoded words.
+
+This variable is a list of FUNCTION or (REGEXP . FUNCTION). If item is
+FUNCTION, FUNCTION will be apply to all newsgroups. If item is a
+(REGEXP . FUNCTION), FUNCTION will be only apply to thes newsgroups
+whose names match REGEXP.
+
+For example: 
+((\"chinese\" . gnus-decode-encoded-word-string-by-guess)
+ mail-decode-encoded-word-string 
+ (\"chinese\" . rfc1843-decode-string))
+")
+
+(defvar gnus-decode-encoded-word-methods-cache nil)
 
 (defun gnus-multi-decode-encoded-word-string (string)
-  "Apply the functions from `gnus-encoded-word-method-alist' that match."
-  (let ((alist gnus-encoded-word-method-alist)
-       elem)
-    (while (setq elem (pop alist))
-      (when (string-match (car elem) gnus-newsgroup-name)
-       (pop elem)
-       (while elem
-         (setq string (funcall (pop elem) string)))
-       (setq alist nil)))
-    string))
+  "Apply the functions from `gnus-encoded-word-methods' that match."
+  (unless (and gnus-decode-encoded-word-methods-cache
+              (eq gnus-newsgroup-name 
+                  (car gnus-decode-encoded-word-methods-cache)))
+    (setq gnus-decode-encoded-word-methods-cache (list gnus-newsgroup-name))
+    (mapc '(lambda (x) 
+            (if (symbolp x)
+                (nconc gnus-decode-encoded-word-methods-cache (list x))
+              (if (and gnus-newsgroup-name 
+                       (string-match (car x) gnus-newsgroup-name))
+                  (nconc gnus-decode-encoded-word-methods-cache 
+                         (list (cdr x))))))
+         gnus-decode-encoded-word-methods))
+  (let ((xlist gnus-decode-encoded-word-methods-cache))
+    (pop xlist)
+    (while xlist
+      (setq string (funcall (pop xlist) string))))
+  string)
 
 ;; Subject simplification.
 
@@ -4285,7 +4305,7 @@ If WHERE is `summary', the summary mode line format will be used."
          ;; We might have to chop a bit of the string off...
          (when (> (length mode-string) max-len)
            (setq mode-string
-                 (concat (truncate-string mode-string (- max-len 3))
+                 (concat (truncate-string-to-width mode-string (- max-len 3))
                          "...")))
          ;; Pad the mode string a bit.
          (setq mode-string (format (format "%%-%ds" max-len) mode-string))))
@@ -7866,19 +7886,19 @@ marked."
   (let ((forward (cdr (assq type gnus-summary-mark-positions)))
         (buffer-read-only nil))
     (re-search-backward "[\n\r]" (gnus-point-at-bol) 'move-to-limit)
-    (when (looking-at "\r")
-      (incf forward))
-    (when (and forward
-               (<= (+ forward (point)) (point-max)))
-      ;; Go to the right position on the line.
-      (goto-char (+ forward (point)))
-      ;; Replace the old mark with the new mark.
-      (subst-char-in-region (point) (1+ (point)) (char-after) mark)
-      ;; Optionally update the marks by some user rule.
-      (when (eq type 'unread)
-        (gnus-data-set-mark
-         (gnus-data-find (gnus-summary-article-number)) mark)
-        (gnus-summary-update-line (eq mark gnus-unread-mark))))))
+    (when forward
+      (when (looking-at "\r")
+       (incf forward))
+      (when (<= (+ forward (point)) (point-max))
+       ;; Go to the right position on the line.
+       (goto-char (+ forward (point)))
+       ;; Replace the old mark with the new mark.
+       (subst-char-in-region (point) (1+ (point)) (char-after) mark)
+       ;; Optionally update the marks by some user rule.
+       (when (eq type 'unread)
+         (gnus-data-set-mark
+          (gnus-data-find (gnus-summary-article-number)) mark)
+         (gnus-summary-update-line (eq mark gnus-unread-mark)))))))
 
 (defun gnus-mark-article-as-read (article &optional mark)
   "Enter ARTICLE in the pertinent lists and remove it from others."
@@ -8682,6 +8702,7 @@ save those articles instead."
 (defun gnus-valid-move-group-p (group)
   (and (boundp group)
        (symbol-name group)
+       (symbol-value group)
        (memq 'respool
             (assoc (symbol-name
                     (car (gnus-find-method-for-group
index 9f4714e..30b2cde 100644 (file)
@@ -647,7 +647,7 @@ with potentially long computations."
   (setq filename (expand-file-name filename))
   (setq rmail-default-rmail-file filename)
   (let ((artbuf (current-buffer))
-       (tmpbuf (gnus-get-buffer-create " *Gnus-output*")))
+       (tmpbuf (get-buffer-create " *Gnus-output*")))
     (save-excursion
       (or (get-file-buffer filename)
          (file-exists-p filename)
@@ -698,7 +698,7 @@ with potentially long computations."
   "Append the current article to a mail file named FILENAME."
   (setq filename (expand-file-name filename))
   (let ((artbuf (current-buffer))
-       (tmpbuf (gnus-get-buffer-create " *Gnus-output*")))
+       (tmpbuf (get-buffer-create " *Gnus-output*")))
     (save-excursion
       ;; Create the file, if it doesn't exist.
       (when (and (not (get-file-buffer filename))
index 87aa453..6f99327 100644 (file)
@@ -434,7 +434,7 @@ call it with the value of the `gnus-data' text property."
   (defun gnus-byte-code (func)
     "Return a form that can be `eval'ed based on FUNC."
     (let ((fval (indirect-function func)))
-      (if (compiled-function-p fval)
+      (if (byte-code-function-p fval)
          (list 'funcall fval)
        (cons 'progn (cdr (cdr fval))))))
 
@@ -806,7 +806,6 @@ XEmacs compatibility workaround."
     (goto-char (event-point event))
     (funcall (event-function response) (event-object response))))
 
-
 (provide 'gnus-xmas)
 
 ;;; gnus-xmas.el ends here
index 59a9578..792404c 100644 (file)
@@ -245,12 +245,16 @@ is restarted, and sometimes reloaded."
   :link '(custom-manual "(gnus)Various Various")
   :group 'gnus)
 
+(defgroup gnus-mime nil
+  "Variables for controlling the Gnus MIME interface."
+  :group 'gnus)
+
 (defgroup gnus-exit nil
   "Exiting gnus."
   :link '(custom-manual "(gnus)Exiting Gnus")
   :group 'gnus)
 
-(defconst gnus-version-number "0.38"
+(defconst gnus-version-number "0.39"
   "Version number for this version of Gnus.")
 
 (defconst gnus-version (format "Pterodactyl Gnus v%s" gnus-version-number)
@@ -1548,7 +1552,6 @@ want."
   '((gnus-group-mode "(gnus)The Group Buffer")
     (gnus-summary-mode "(gnus)The Summary Buffer")
     (gnus-article-mode "(gnus)The Article Buffer")
-    (mime/viewer-mode "(gnus)The Article Buffer")
     (gnus-server-mode "(gnus)The Server Buffer")
     (gnus-browse-mode "(gnus)Browse Foreign Server")
     (gnus-tree-mode "(gnus)Tree Display"))
@@ -1643,9 +1646,9 @@ gnus-newsrc-hashtb should be kept so that both hold the same information.")
       message-send-and-exit message-yank-original)
      ("nnmail" nnmail-split-fancy nnmail-article-group)
      ("nnvirtual" nnvirtual-catchup-group nnvirtual-convert-headers)
-     ("rmailout" rmail-output)
+     ("rmailout" rmail-output rmail-output-to-rmail-file)
      ("rmail" rmail-insert-rmail-file-header rmail-count-new-messages
-      rmail-show-message rmail-output-to-rmail-file)
+      rmail-show-message)
      ("gnus-audio" :interactive t gnus-audio-play)
      ("gnus-xmas" gnus-xmas-splash)
      ("gnus-soup" :interactive t
@@ -1713,7 +1716,7 @@ gnus-newsrc-hashtb should be kept so that both hold the same information.")
       gnus-uu-decode-uu-and-save-view gnus-uu-decode-unshar-view
       gnus-uu-decode-unshar-and-save-view gnus-uu-decode-save-view
       gnus-uu-decode-binhex-view gnus-uu-unmark-thread
-      gnus-uu-mark-over)
+      gnus-uu-mark-over gnus-uu-post-news)
      ("gnus-uu" gnus-uu-delete-work-dir gnus-uu-unmark-thread)
      ("gnus-msg" (gnus-summary-send-map keymap)
       gnus-article-mail gnus-copy-article-buffer gnus-extended-version)
index 74cf2bf..6e85b13 100644 (file)
@@ -442,7 +442,9 @@ If FORCE, re-parse even if already parsed."
        (test (assq 'test info))        ; The test clause
        )
     (setq status (and test (split-string (cdr test) " ")))
-    (if (and (assoc "needsx11" info) (not (getenv "DISPLAY")))
+    (if (and (or (assoc "needsterm" info)
+                (assoc "needsx11" info))
+            (not (getenv "DISPLAY")))
        (setq status nil)
       (cond
        ((and (equal (nth 0 status) "test")
index 93f6e08..b7611c3 100644 (file)
@@ -121,7 +121,8 @@ If no encoding was done, nil is returned."
        (funcall encoding (point-min) (point-max))
       (error nil)))
    (t
-    (error "Can't decode encoding %s" encoding))))
+    (message "Unknown encoding %s; defaulting to 8bit" encoding)
+    )))
 
 (defun mm-decode-body (charset &optional encoding)
   "Decode the current article that has been encoded with ENCODING.
index bac00f6..6344209 100644 (file)
          (when (or user-method
                    method
                    (not no-default))
-           (mm-display-external
-            handle (or user-method method 'mailcap-save-binary-file))))))))
+           (if (and (not user-method)
+                    (not method)
+                    (equal "text" (car (split-string type))))
+               (mm-insert-inline handle (mm-get-part handle))
+             (mm-display-external
+              handle (or user-method method
+                         'mailcap-save-binary-file)))))))))
 
 (defun mm-display-external (handle method)
   "Display HANDLE using METHOD."
     (if (functionp method)
        (let ((cur (current-buffer)))
          (if (eq method 'mailcap-save-binary-file)
-             (set-buffer (generate-new-buffer "*mm*"))
+             (progn
+               (set-buffer (generate-new-buffer "*mm*"))
+               (setq method nil))
            (let ((win (get-buffer-window cur t)))
              (when win
                (select-window win)))
          (message "Viewing with %s" method)
          (let ((mm (current-buffer)))
            (unwind-protect
-               (funcall method)
+               (if method
+                   (funcall method)
+                 (mm-save-part handle))
              (mm-handle-set-undisplayer handle mm))))
       (let* ((dir (make-temp-name (expand-file-name "emm." mm-tmp-directory)))
             (filename (mail-content-type-get
index b8efebe..03aa0c6 100644 (file)
@@ -2,7 +2,7 @@
 ;; Copyright (c) 1998 by Shenghuo Zhu <zsh@cs.rochester.edu>
 
 ;; Author: Shenghuo Zhu <zsh@cs.rochester.edu>
-;; $Revision: 5.1 $
+;; $Revision: 5.2 $
 ;; Keywords: news postscript uudecode binhex shar
   
 ;; This file is not part of GNU Emacs, but the same permissions
@@ -76,6 +76,7 @@
     (save-restriction
       (mail-narrow-to-head)
       (goto-char (point-max)))
+    (forward-line)
     (let ((text-start (point)) start-char end-char 
          type file-name end-line result)
       (while (re-search-forward mm-uu-begin-line nil t)
@@ -94,6 +95,7 @@
                        (intern (concat "mm-uu-" (symbol-name type) 
                                       "-end-line"))))
        (when (re-search-forward end-line nil t)
+         (forward-line)
          (setq end-char (point))
          (when (or (not (eq type 'binhex))
                    (setq file-name 
             result)
            (setq text-start end-char))))
       (when result
-       (if (> start-char text-start)
+       (if (> (point-max) (1+ text-start))
            (push
             (list (mm-uu-copy-to-buffer text-start (point-max)) 
                   '("text/plain") nil nil nil nil) 
index 010121c..302924d 100644 (file)
@@ -269,7 +269,7 @@ on your system, you could say something like:
                  (nnheader-header-value)))
           
           ;; Extra.
-          (when gnus-extra-headers
+          (when nnmail-extra-headers
             (let ((extra nnmail-extra-headers)
                   out)
               (while extra
index 4f92163..8847ae3 100644 (file)
@@ -225,6 +225,7 @@ all.  This may very well take some time.")
   t)
 
 (deffoo nnml-request-create-group (group &optional server args)
+  (nnml-possibly-change-directory nil server)
   (nnmail-activate 'nnml)
   (cond
    ((assoc group nnml-group-alist)
@@ -574,15 +575,9 @@ all.  This may very well take some time.")
       (file-exists-p nnml-current-directory))))
 
 (defun nnml-possibly-create-directory (group)
-  (let (dir dirs)
-    (setq dir (nnmail-group-pathname group nnml-directory))
-    (while (not (file-directory-p dir))
-      (push dir dirs)
-      (setq dir (file-name-directory (directory-file-name dir))))
-    (while dirs
-      (make-directory (directory-file-name (car dirs)))
-      (nnheader-message 5 "Creating mail directory %s" (car dirs))
-      (setq dirs (cdr dirs)))))
+  (let ((dir (nnmail-group-pathname group nnml-directory)))
+    (make-directory (directory-file-name dir) t)
+    (nnheader-message 5 "Creating mail directory %s" dir)))
 
 (defun nnml-save-mail (group-art)
   "Called narrowed to an article."
index 2e36e08..b90cd03 100644 (file)
@@ -1,10 +1,10 @@
 ;;; pop3.el --- Post Office Protocol (RFC 1460) interface
 
-;; Copyright (C) 1996,1997 Free Software Foundation, Inc.
+;; Copyright (C) 1996,1997,1998 Free Software Foundation, Inc.
 
 ;; Author: Richard L. Pieri <ratinox@peorth.gweep.net>
 ;; Keywords: mail, pop3
-;; Version: 1.3l
+;; Version: 1.3m
 
 ;; This file is part of GNU Emacs.
 
@@ -37,7 +37,7 @@
 (require 'mail-utils)
 (provide 'pop3)
 
-(defconst pop3-version "1.3l")
+(defconst pop3-version "1.3m")
 
 (defvar pop3-maildrop (or (user-login-name) (getenv "LOGNAME") (getenv "USER") nil)
   "*POP3 maildrop.")
@@ -112,12 +112,14 @@ Returns the process associated with the connection."
   (let ((process-buffer
         (get-buffer-create (format "trace of POP session to %s" mailhost)))
        (process)
-        (coding-system-for-read 'no-conversion)
-        (coding-system-for-write 'no-conversion))
+       (coding-system-for-read 'no-conversion)   ;; because FSF Emacs 20
+       (coding-system-for-write 'no-conversion)  ;; is st00pid
+    )
     (save-excursion
       (set-buffer process-buffer)
       (erase-buffer)
-      (setq pop3-read-point (point-min)))
+      (setq pop3-read-point (point-min))
+      )
     (setq process
          (open-network-stream "POP" process-buffer mailhost port))
     (let ((response (pop3-read-response process t)))
index 187c9c6..51be9d0 100644 (file)
@@ -1,3 +1,7 @@
+1998-10-25 01:51:56  Lars Magne Ingebrigtsen  <larsi@gnus.org>
+
+       * gnus.texi (Headers): Addition.
+
 1998-10-24 08:37:12  Lars Magne Ingebrigtsen  <larsi@gnus.org>
 
        * gnus.texi (Summary Buffer Lines): Addition.
index 5c1cfa6..240437a 100644 (file)
@@ -1,7 +1,7 @@
 \input texinfo                  @c -*-texinfo-*-
 
 @setfilename gnus
-@settitle Pterodactyl Gnus 0.38 Manual
+@settitle Pterodactyl Gnus 0.39 Manual
 @synindex fn cp
 @synindex vr cp
 @synindex pg cp
@@ -318,7 +318,7 @@ into another language, under the above conditions for modified versions.
 @tex
 
 @titlepage
-@title Pterodactyl Gnus 0.38 Manual
+@title Pterodactyl Gnus 0.39 Manual
 
 @author by Lars Magne Ingebrigtsen
 @page
@@ -354,7 +354,7 @@ can be gotten by any nefarious means you can think of---@sc{nntp}, local
 spool or your mbox file.  All at the same time, if you want to push your
 luck.
 
-This manual corresponds to Pterodactyl Gnus 0.38.
+This manual corresponds to Pterodactyl Gnus 0.39.
 
 @end ifinfo
 
@@ -6910,6 +6910,17 @@ View all the @sc{mime} parts in the current article
 
 @end table
 
+Relevant variables:
+
+@table @code
+@item gnus-ignored-mime-types
+@vindex gnus-ignored-mime-types
+This is a list of regexps.  @sc{mime} types that match a regexp from
+this list will be completely ignored by Gnus.  The default value is
+@code{("text/x-vcard")}.
+
+@end table
+
 
 @node Article Commands
 @section Article Commands
@@ -16143,6 +16154,10 @@ Luis Fernandes---design and graphics.
 @item
 Erik Naggum---help, ideas, support, code and stuff.
 
+@item
+Shenghuo Zhu---uudecode.el, mm-uu.el, rfc1843.el and many other things
+connected with @sc{mime} and other types of en/decoding.
+
 @item
 Wes Hardaker---@file{gnus-picon.el} and the manual section on
 @dfn{picons} (@pxref{Picons}).
@@ -16378,10 +16393,9 @@ Stefan Waldherr,
 Pete Ware,
 Barry A. Warsaw,
 Christoph Wedler,
-Joe Wells,
-Katsumi Yamaoka, @c Yamaoka
+Joe Wells
 and
-Shenghuo Zhu. @c Zhu
+Katsumi Yamaoka, @c Yamaoka.
 
 For a full overview of what each person has done, the ChangeLogs
 included in the Gnus alpha distributions should give ample reading
@@ -18270,10 +18284,6 @@ exits the group.
 @item
 The jingle is only played on the second invocation of Gnus.
 
-@item
-gnus-ignored-mime-types to avoid seeing buttons for Vcards and the
-like.
-
 @item
 Bouncing articles should do MIME.
 
@@ -19800,12 +19810,12 @@ basically, with each header (ouch) having one slot.
 
 These slots are, in order: @code{number}, @code{subject}, @code{from},
 @code{date}, @code{id}, @code{references}, @code{chars}, @code{lines},
-@code{xref}.  There are macros for accessing and setting these
-slots---they all have predictable names beginning with
+@code{xref}, and @code{extra}.  There are macros for accessing and
+setting these slots---they all have predictable names beginning with
 @code{mail-header-} and @code{mail-header-set-}, respectively.
 
-The @code{xref} slot is really a @code{misc} slot.  Any extra info will
-be put in there.
+All these slots contain strings, except the @code{extra} slot, which
+contains an alist of header/value pairs (@pxref{To From Newsgroups}).
 
 
 @node Ranges
index 2eeac69..237dd93 100644 (file)
@@ -1,7 +1,7 @@
 \input texinfo                  @c -*-texinfo-*-
 
 @setfilename message
-@settitle Pterodactyl Message 0.38 Manual
+@settitle Pterodactyl Message 0.39 Manual
 @synindex fn cp
 @synindex vr cp
 @synindex pg cp
@@ -42,7 +42,7 @@ into another language, under the above conditions for modified versions.
 @tex
 
 @titlepage
-@title Pterodactyl Message 0.38 Manual
+@title Pterodactyl Message 0.39 Manual
 
 @author by Lars Magne Ingebrigtsen
 @page
@@ -83,7 +83,7 @@ Message mode buffers.
 * Key Index::         List of Message mode keys.
 @end menu
 
-This manual corresponds to Pterodactyl Message 0.38.  Message is
+This manual corresponds to Pterodactyl Message 0.39.  Message is
 distributed with the Gnus distribution bearing the same version number
 as this manual.