*** pub/sgnus/lisp/gnus-cache.el Tue Mar 12 03:30:50 1996 --- sgnus/lisp/gnus-cache.el Wed Mar 13 05:59:36 1996 *************** *** 241,283 **** (defun gnus-cache-retrieve-headers (articles group &optional fetch-old) "Retrieve the headers for ARTICLES in GROUP." ! (let* ((cached ! (setq gnus-newsgroup-cached (gnus-cache-articles-in-group group))) ! (uncached-articles (gnus-sorted-intersection ! (gnus-sorted-complement articles cached) ! articles)) ! (cache-file (gnus-cache-file-name group ".overview")) ! type) ! ;; We first retrieve all the headers that we don't have in ! ;; the cache. ! (let ((gnus-use-cache nil)) ! (setq type (and articles ! (gnus-retrieve-headers ! uncached-articles group fetch-old)))) ! (gnus-cache-save-buffers) ! ;; Then we insert the cached headers. ! (save-excursion ! (cond ! ((not (file-exists-p cache-file)) ! ;; There are no cached headers. ! type) ! ((null type) ! ;; There were no uncached headers (or retrieval was ! ;; unsuccessful), so we use the cached headers exclusively. ! (set-buffer nntp-server-buffer) ! (erase-buffer) ! (insert-file-contents cache-file) ! 'nov) ! ((eq type 'nov) ! ;; We have both cached and uncached NOV headers, so we ! ;; braid them. ! (gnus-cache-braid-nov group cached) ! type) ! (t ! ;; We braid HEADs. ! (gnus-cache-braid-heads group (gnus-sorted-intersection ! cached articles)) ! type))))) (defun gnus-cache-enter-article (&optional n) "Enter the next N articles into the cache. --- 241,288 ---- (defun gnus-cache-retrieve-headers (articles group &optional fetch-old) "Retrieve the headers for ARTICLES in GROUP." ! (let ((cached ! (setq gnus-newsgroup-cached (gnus-cache-articles-in-group group)))) ! (if (not cached) ! ;; No cached articles here, so we just retrieve them ! ;; the normal way. ! (let ((gnus-use-cache nil)) ! (gnus-retrieve-headers articles group fetch-old)) ! (let ((uncached-articles (gnus-sorted-intersection ! (gnus-sorted-complement articles cached) ! articles)) ! (cache-file (gnus-cache-file-name group ".overview")) ! type) ! ;; We first retrieve all the headers that we don't have in ! ;; the cache. ! (let ((gnus-use-cache nil)) ! (setq type (and articles ! (gnus-retrieve-headers ! uncached-articles group fetch-old)))) ! (gnus-cache-save-buffers) ! ;; Then we insert the cached headers. ! (save-excursion ! (cond ! ((not (file-exists-p cache-file)) ! ;; There are no cached headers. ! type) ! ((null type) ! ;; There were no uncached headers (or retrieval was ! ;; unsuccessful), so we use the cached headers exclusively. ! (set-buffer nntp-server-buffer) ! (erase-buffer) ! (insert-file-contents cache-file) ! 'nov) ! ((eq type 'nov) ! ;; We have both cached and uncached NOV headers, so we ! ;; braid them. ! (gnus-cache-braid-nov group cached) ! type) ! (t ! ;; We braid HEADs. ! (gnus-cache-braid-heads group (gnus-sorted-intersection ! cached articles)) ! type))))))) (defun gnus-cache-enter-article (&optional n) "Enter the next N articles into the cache. *************** *** 455,461 **** (erase-buffer) (insert-file-contents (gnus-cache-file-name group (car cached))) (goto-char (point-min)) ! (insert "220 " (int-to-string (car cached)) " Article retrieved.\n") (search-forward "\n\n" nil 'move) (delete-region (point) (point-max)) (forward-char -1) --- 460,468 ---- (erase-buffer) (insert-file-contents (gnus-cache-file-name group (car cached))) (goto-char (point-min)) ! (insert "220 ") ! (princ (car cached) (current-buffer)) ! (insert " Article retrieved.\n") (search-forward "\n\n" nil 'move) (delete-region (point) (point-max)) (forward-char -1) *** pub/sgnus/lisp/gnus-gl.el Tue Mar 12 03:30:50 1996 --- sgnus/lisp/gnus-gl.el Sat Mar 16 15:46:21 1996 *************** *** 127,132 **** --- 127,136 ---- "%U%R%z%l%I%(%[%4L: %-20,20n%]%) %s\n" "*The line format spec in summary GroupLens mode buffers.") + (defvar gnus-summary-grouplens-lab-line-format + "%U%R%z%uL%I%(%[%4L: %-20,20n%]%) %s\n" + "*The line format spec in summary GroupLens mode buffers.") + (defvar grouplens-pseudonym "" "User's pseudonym. This pseudonym is obtained during the registration process") *************** *** 515,524 **** (let* ((rate-string (make-string 12 ? )) (mid (aref header (nth 1 (assoc "message-id" gnus-header-index)))) (hashent (gethash mid grouplens-current-hashtable)) ! (pred (nth 0 hashent)) (low (nth 1 hashent)) (high (nth 2 hashent))) - (gnus-message 5 (concat "mid = " mid)) ;; Init rate-string (aset rate-string 0 ?|) (aset rate-string 11 ?|) --- 519,527 ---- (let* ((rate-string (make-string 12 ? )) (mid (aref header (nth 1 (assoc "message-id" gnus-header-index)))) (hashent (gethash mid grouplens-current-hashtable)) ! (pred (or (nth 0 hashent) 0)) (low (nth 1 hashent)) (high (nth 2 hashent))) ;; Init rate-string (aset rate-string 0 ?|) (aset rate-string 11 ?|) *************** *** 759,765 **** ;; BUG REPORTING ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ! (defconst gnus-gl-version "gnus-gl.el 2.9") (defconst gnus-gl-maintainer-address "grouplens-bug@cs.umn.edu") (defun gnus-gl-submit-bug-report () "Submit via mail a bug report on gnus-gl" --- 762,768 ---- ;; BUG REPORTING ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ! (defconst gnus-gl-version "gnus-gl.el 2.10") (defconst gnus-gl-maintainer-address "grouplens-bug@cs.umn.edu") (defun gnus-gl-submit-bug-report () "Submit via mail a bug report on gnus-gl" *************** *** 843,849 **** '(lambda() (bbb-build-mid-scores-alist gnus-newsgroup-name)))) (make-local-variable 'gnus-summary-line-format) ! (setq gnus-summary-line-format gnus-summary-grouplens-line-format) (make-local-variable 'gnus-summary-line-format-spec) ;; Set up the menu. --- 846,854 ---- '(lambda() (bbb-build-mid-scores-alist gnus-newsgroup-name)))) (make-local-variable 'gnus-summary-line-format) ! (if gnus-grouplens-override-scoring ! ! (setq gnus-summary-line-format gnus-summary-grouplens-lab-line-format)) (make-local-variable 'gnus-summary-line-format-spec) ;; Set up the menu. *************** *** 860,863 **** (provide 'gnus-gl) ;;; end gnus-gl.el - --- 865,867 ---- *** pub/sgnus/lisp/gnus-msg.el Tue Mar 12 03:30:54 1996 --- sgnus/lisp/gnus-msg.el Sat Mar 16 15:40:55 1996 *************** *** 2333,2342 **** (save-excursion (gnus-copy-article-buffer) (mail-yank-original nil) ! (setq end (point))) (or mail-yank-hooks mail-citation-hook (run-hooks 'news-reply-header-hook)) (goto-char end) (setq yank (cdr yank)))) (goto-char last)) (gnus-configure-windows 'followup-yank 'force)) --- 2333,2343 ---- (save-excursion (gnus-copy-article-buffer) (mail-yank-original nil) ! (setq end (set-marker (make-marker) (point)))) (or mail-yank-hooks mail-citation-hook (run-hooks 'news-reply-header-hook)) (goto-char end) + (set-marker end nil) (setq yank (cdr yank)))) (goto-char last)) (gnus-configure-windows 'followup-yank 'force)) *************** *** 2615,2632 **** (insert "------------------ Environment follows ------------------\n\n")) (while olist (if (boundp (car olist)) ! (insert ! (condition-case () ! (pp-to-string ! `(setq ,(car olist) ! ,(if (or (consp (setq sym (symbol-value (car olist)))) ! (and (symbolp sym) ! (not (or (eq sym nil) ! (eq sym t))))) ! (list 'quote (symbol-value (car olist))) ! (symbol-value (car olist))))) ! (error ! (format "(setq %s 'whatever)\n" (car olist))))) (insert ";; (makeunbound '" (symbol-name (car olist)) ")\n")) (setq olist (cdr olist))) (insert "\n\n") --- 2616,2632 ---- (insert "------------------ Environment follows ------------------\n\n")) (while olist (if (boundp (car olist)) ! (condition-case () ! (pp `(setq ,(car olist) ! ,(if (or (consp (setq sym (symbol-value (car olist)))) ! (and (symbolp sym) ! (not (or (eq sym nil) ! (eq sym t))))) ! (list 'quote (symbol-value (car olist))) ! (symbol-value (car olist)))) ! (current-buffer)) ! (error ! (format "(setq %s 'whatever)\n" (car olist)))) (insert ";; (makeunbound '" (symbol-name (car olist)) ")\n")) (setq olist (cdr olist))) (insert "\n\n") *************** *** 2805,2811 **** ;; If the group doesn't exist, we assume ;; it's an archive group... gnus-message-archive-method) ! (t (gnus-find-method-for-group group))))) (unless (gnus-request-group group t method) (gnus-request-create-group group method)) (gnus-check-server method) --- 2805,2811 ---- ;; If the group doesn't exist, we assume ;; it's an archive group... gnus-message-archive-method) ! (t (gnus-group-method group))))) (unless (gnus-request-group group t method) (gnus-request-create-group group method)) (gnus-check-server method) *** pub/sgnus/lisp/gnus-nocem.el Tue Mar 12 03:30:54 1996 --- sgnus/lisp/gnus-nocem.el Wed Mar 13 03:48:03 1996 *************** *** 185,199 **** (when (and gnus-nocem-alist gnus-nocem-touched-alist) (nnheader-temp-write (gnus-nocem-cache-file) ! (insert (prin1-to-string ! `(setq gnus-nocem-alist ',gnus-nocem-alist)))) (setq gnus-nocem-touched-alist nil))) (defun gnus-nocem-save-active () "Save the NoCeM active file." (nnheader-temp-write (gnus-nocem-active-file) ! (insert (prin1-to-string ! `(setq gnus-nocem-active ',gnus-nocem-active))))) (defun gnus-nocem-alist-to-hashtb () "Create a hashtable from the Message-IDs we have." --- 185,197 ---- (when (and gnus-nocem-alist gnus-nocem-touched-alist) (nnheader-temp-write (gnus-nocem-cache-file) ! (prin1 `(setq gnus-nocem-alist ',gnus-nocem-alist) (current-buffer))) (setq gnus-nocem-touched-alist nil))) (defun gnus-nocem-save-active () "Save the NoCeM active file." (nnheader-temp-write (gnus-nocem-active-file) ! (prin1 `(setq gnus-nocem-active ',gnus-nocem-active) (current-buffer)))) (defun gnus-nocem-alist-to-hashtb () "Create a hashtable from the Message-IDs we have." *** pub/sgnus/lisp/gnus-score.el Tue Mar 12 03:30:56 1996 --- sgnus/lisp/gnus-score.el Sat Mar 16 15:40:52 1996 *************** *** 1290,1296 **** (save-restriction (let* ((buffer-read-only nil) (articles gnus-scores-articles) ! (last (mail-header-number (caar gnus-scores-articles))) (all-scores scores) (request-func (cond ((string= "head" (downcase header)) 'gnus-request-head) --- 1290,1298 ---- (save-restriction (let* ((buffer-read-only nil) (articles gnus-scores-articles) ! (last (if (caar gnus-scores-articles) ! (mail-header-number (caar gnus-scores-articles)) ! 0)) (all-scores scores) (request-func (cond ((string= "head" (downcase header)) 'gnus-request-head) *************** *** 1833,1839 **** (defun gnus-score-edit-insert-date () "Insert date in numerical format." (interactive) ! (insert (int-to-string (gnus-day-number (current-time-string))))) (defun gnus-score-pretty-print () "Format the current score file." --- 1835,1841 ---- (defun gnus-score-edit-insert-date () "Insert date in numerical format." (interactive) ! (princ (gnus-day-number (current-time-string)) (current-buffer))) (defun gnus-score-pretty-print () "Format the current score file." *** pub/sgnus/lisp/gnus-topic.el Tue Mar 12 03:30:56 1996 --- sgnus/lisp/gnus-topic.el Fri Mar 15 08:27:06 1996 *************** *** 1,4 **** ! ;;; gnus-topic.el --- a folding minor mode for Gnus group buffers ;; Copyright (C) 1995,96 Free Software Foundation, Inc. ;; Author: Ilja Weis --- 1,4 ---- ! ;; gnus-topic.el --- a folding minor mode for Gnus group buffers ;; Copyright (C) 1995,96 Free Software Foundation, Inc. ;; Author: Ilja Weis *************** *** 78,84 **** (defun gnus-group-topic-name () "The name of the topic on the current line." ! (get-text-property (gnus-point-at-bol) 'gnus-topic)) (defun gnus-group-topic-level () "The level of the topic on the current line." --- 78,85 ---- (defun gnus-group-topic-name () "The name of the topic on the current line." ! (let ((group (get-text-property (gnus-point-at-bol) 'gnus-topic))) ! (and group (symbol-name group)))) (defun gnus-group-topic-level () "The level of the topic on the current line." *************** *** 218,226 **** (<= clevel level) (>= clevel lowest) ; Is inside the level we want. (or all ! (and gnus-group-list-inactive-groups ! (eq unread t)) ! (> unread 0) (and gnus-list-groups-with-ticked-articles (cdr (assq 'tick (gnus-info-marks info)))) ; Has right readedness. --- 219,227 ---- (<= clevel level) (>= clevel lowest) ; Is inside the level we want. (or all ! (if (eq unread t) ! gnus-group-list-inactive-groups ! (> unread 0)) (and gnus-list-groups-with-ticked-articles (cdr (assq 'tick (gnus-info-marks info)))) ; Has right readedness. *************** *** 273,279 **** (defun gnus-group-topic-p () "Return non-nil if the current line is a topic." ! (get-text-property (gnus-point-at-bol) 'gnus-topic)) (defun gnus-topic-visible-p () "Return non-nil if the current topic is visible." --- 274,280 ---- (defun gnus-group-topic-p () "Return non-nil if the current line is a topic." ! (gnus-group-topic-name)) (defun gnus-topic-visible-p () "Return non-nil if the current topic is visible." *************** *** 293,299 **** (prog1 (1+ (point)) (eval gnus-topic-line-format-spec) (gnus-topic-remove-excess-properties)) ! (list 'gnus-topic name 'gnus-topic-level level 'gnus-active active-topic 'gnus-topic-visible visiblep)))) --- 294,300 ---- (prog1 (1+ (point)) (eval gnus-topic-line-format-spec) (gnus-topic-remove-excess-properties)) ! (list 'gnus-topic (intern name) 'gnus-topic-level level 'gnus-active active-topic 'gnus-topic-visible visiblep)))) *************** *** 414,427 **** out)) (defun gnus-topic-goto-topic (topic) ! (let ((orig (point))) ! (goto-char (point-min)) ! (while (and (not (equal topic (gnus-group-topic-name))) ! (zerop (forward-line 1)))) ! (or (gnus-group-topic-name) ! (progn ! (goto-char orig) ! nil)))) (defun gnus-topic-update-topic () "Update all parent topics to the current group." --- 415,423 ---- out)) (defun gnus-topic-goto-topic (topic) ! (when topic ! (gnus-goto-char (text-property-any (point-min) (point-max) ! 'gnus-topic (intern topic))))) (defun gnus-topic-update-topic () "Update all parent topics to the current group." *************** *** 800,806 **** (defun gnus-topic-goto-next-group (group props) "Go to group or the next group after group." (if (null group) ! (gnus-topic-goto-topic (cadr (memq 'gnus-topic props))) (if (gnus-group-goto-group group) t ;; The group is no longer visible. --- 796,802 ---- (defun gnus-topic-goto-next-group (group props) "Go to group or the next group after group." (if (null group) ! (gnus-topic-goto-topic (symbol-name (cadr (memq 'gnus-topic props)))) (if (gnus-group-goto-group group) t ;; The group is no longer visible. *** pub/sgnus/lisp/gnus-vis.el Tue Mar 12 03:30:59 1996 --- sgnus/lisp/gnus-vis.el Sat Mar 16 15:40:59 1996 *************** *** 1332,1339 **** (widen) (re-search-backward gnus-signature-separator nil t) (let ((start (match-beginning 0)) ! (end (set-marker (make-marker) (match-end 0)))) ! (gnus-article-add-button start end 'gnus-signature-toggle end))))))) (defun gnus-article-add-buttons (&optional force) --- 1332,1339 ---- (widen) (re-search-backward gnus-signature-separator nil t) (let ((start (match-beginning 0)) ! (end (set-marker (make-marker) (1+ (match-end 0))))) ! (gnus-article-add-button start (1- end) 'gnus-signature-toggle end))))))) (defun gnus-article-add-buttons (&optional force) *************** *** 1434,1441 **** (let ((buffer-read-only nil) (inhibit-point-motion-hooks t)) (if (get-text-property end 'invisible) ! (remove-text-properties end (point-max) gnus-hidden-properties) ! (add-text-properties end (point-max) gnus-hidden-properties))))) (defun gnus-button-entry () ;; Return the first entry in `gnus-button-alist' matching this place. --- 1434,1441 ---- (let ((buffer-read-only nil) (inhibit-point-motion-hooks t)) (if (get-text-property end 'invisible) ! (gnus-unhide-text end (point-max)) ! (gnus-hide-text end (point-max) gnus-hidden-properties))))) (defun gnus-button-entry () ;; Return the first entry in `gnus-button-alist' matching this place. *** pub/sgnus/lisp/gnus.el Tue Mar 12 03:31:03 1996 --- sgnus/lisp/gnus.el Sat Mar 16 15:40:57 1996 *************** *** 1715,1721 **** "gnus-bug@ifi.uio.no (The Gnus Bugfixing Girls + Boys)" "The mail address of the Gnus maintainers.") ! (defconst gnus-version "September Gnus v0.52" "Version number for this version of Gnus.") (defvar gnus-info-nodes --- 1715,1721 ---- "gnus-bug@ifi.uio.no (The Gnus Bugfixing Girls + Boys)" "The mail address of the Gnus maintainers.") ! (defconst gnus-version "September Gnus v0.53" "Version number for this version of Gnus.") (defvar gnus-info-nodes *************** *** 2157,2162 **** --- 2157,2167 ---- (substring subject (match-end 0)) subject)) + (defsubst gnus-functionp (form) + "Return non-nil if FORM is funcallable." + (or (and (symbolp form) (fboundp form)) + (and (listp form) (eq (car form) 'lambda)))) + (defsubst gnus-goto-char (point) (and point (goto-char point))) *************** *** 2510,2515 **** --- 2515,2522 ---- (push (list type new-format val) gnus-format-specs)) (set (intern (format "gnus-%s-line-format-spec" type)) val)))) + (push (cons 'version emacs-version) gnus-format-specs) + (gnus-update-group-mark-positions) (gnus-update-summary-mark-positions)) *************** *** 3351,3397 **** (gnus-configure-frame split (get-buffer-window (current-buffer)))))) (defun gnus-all-windows-visible-p (split) ! (when (vectorp split) ! (setq split (append split nil))) ! (when (or (consp (car split)) ! (vectorp (car split))) ! (push 1.0 split) ! (push 'vertical split)) ! ;; The SPLIT might be something that is to be evaled to ! ;; return a new SPLIT. ! (while (and (not (assq (car split) gnus-window-to-buffer)) ! (gnus-functionp (car split))) ! (setq split (eval split))) ! (let* ((type (elt split 0))) ! (cond ! ((null split) ! t) ! ((not (or (eq type 'horizontal) (eq type 'vertical) (eq type 'frame))) ! (let ((buffer (cond ((stringp type) type) ! (t (cdr (assq type gnus-window-to-buffer))))) ! win buf) (unless buffer (error "Illegal buffer type: %s" type)) ! (when (setq buf (get-buffer (if (symbolp buffer) (symbol-value buffer) buffer))) (setq win (get-buffer-window buf t))) ! (when win ! (if (memq 'point split) ! win ! t)))) ! (t ! (when (eq type 'frame) ! (setq gnus-frame-split-p t)) ! (let ((n (mapcar 'gnus-all-windows-visible-p ! (cddr split))) ! (win t)) ! (while n ! (cond ((windowp (car n)) ! (setq win (car n))) ! ((null (car n)) ! (setq win nil))) ! (setq n (cdr n))) ! win))))) (defun gnus-window-top-edge (&optional window) (nth 1 (window-edges window))) --- 3358,3408 ---- (gnus-configure-frame split (get-buffer-window (current-buffer)))))) (defun gnus-all-windows-visible-p (split) ! "Say whether all buffers in SPLIT are currently visible. ! In particular, the value returned will be the window that ! should have point." ! (let ((stack (list split)) ! (all-visible t) ! type buffer win buf) ! (while (and (setq split (pop stack)) ! all-visible) ! ;; Be backwards compatible. ! (when (vectorp split) ! (setq split (append split nil))) ! (when (or (consp (car split)) ! (vectorp (car split))) ! (push 1.0 split) ! (push 'vertical split)) ! ;; The SPLIT might be something that is to be evaled to ! ;; return a new SPLIT. ! (while (and (not (assq (car split) gnus-window-to-buffer)) ! (gnus-functionp (car split))) ! (setq split (eval split))) ! ! (setq type (elt split 0)) ! (cond ! ;; Nothing here. ! ((null split) t) ! ;; A buffer. ! ((not (memq type '(horizontal vertical frame))) ! (setq buffer (cond ((stringp type) type) ! (t (cdr (assq type gnus-window-to-buffer))))) (unless buffer (error "Illegal buffer type: %s" type)) ! (when (setq buf (get-buffer (if (symbolp buffer) ! (symbol-value buffer) buffer))) (setq win (get-buffer-window buf t))) ! (if win ! (when (memq 'point split) ! (setq all-visible win)) ! (setq all-visible nil))) ! (t ! (when (eq type 'frame) ! (setq gnus-frame-split-p t)) ! (setq stack (append (cddr split) stack))))) ! (unless (eq all-visible t) ! all-visible))) (defun gnus-window-top-edge (&optional window) (nth 1 (window-edges window))) *************** *** 3655,3665 **** ;; from `message'. (apply 'format args))) - (defun gnus-functionp (form) - "Return non-nil if FORM is funcallable." - (or (and (symbolp form) (fboundp form)) - (and (listp form) (eq (car form) 'lambda)))) - ;; Generate a unique new group name. (defun gnus-generate-new-group-name (leaf) (let ((name leaf) --- 3666,3671 ---- *************** *** 3668,3673 **** --- 3674,3695 ---- (setq name (concat leaf "<" (int-to-string (setq num (1+ num))) ">"))) name)) + (defsubst gnus-hide-text (b e props) + "Set text PROPS on the B to E region, extending `intangble' 1 past B." + (add-text-properties b e props) + (when (memq 'intangible props) + (put-text-property (1- b) b 'intangible (cddr (memq 'intangible props))))) + + (defsubst gnus-unhide-text (b e) + "Remove hidden text properties from region between B and E." + (remove-text-properties b e gnus-hidden-properties) + (when (memq 'intangible gnus-hidden-properties) + (put-text-property (1- b) b 'intangible nil))) + + (defun gnus-hide-text-type (b e type) + "Hide text of TYPE between B and E." + (gnus-hide-text b e (cons 'gnus-type (cons type gnus-hidden-properties)))) + ;; Find out whether the gnus-visual TYPE is wanted. (defun gnus-visual-p (&optional type class) (and gnus-visual ; Has to be non-nil, at least. *************** *** 4427,4435 **** (<= (setq clevel (gnus-info-level info)) level) (>= clevel lowest) (or all ; We list all groups? ! (and gnus-group-list-inactive-groups ! (eq unread t)) ; We list unactivated groups ! (> unread 0) ; We list groups with unread articles (and gnus-list-groups-with-ticked-articles (cdr (assq 'tick (gnus-info-marks info)))) ; And groups with tickeds --- 4449,4457 ---- (<= (setq clevel (gnus-info-level info)) level) (>= clevel lowest) (or all ; We list all groups? ! (if (eq unread t) ; Unactivated? ! gnus-group-list-inactive-groups ; We list unactivated ! (> unread 0)) ; We list groups with unread articles (and gnus-list-groups-with-ticked-articles (cdr (assq 'tick (gnus-info-marks info)))) ; And groups with tickeds *************** *** 6374,6387 **** (string-match regexp (symbol-name group)) (setq groups (cons (symbol-name group) groups)))) gnus-active-hashtb) ! ;; Go through all descriptions that are known to Gnus. ! (if search-description ! (mapatoms ! (lambda (group) ! (and (string-match regexp (symbol-value group)) ! (gnus-active (symbol-name group)) ! (setq groups (cons (symbol-name group) groups)))) ! gnus-description-hashtb)) (if (not groups) (gnus-message 3 "No groups matched \"%s\"." regexp) ;; Print out all the groups. --- 6396,6409 ---- (string-match regexp (symbol-name group)) (setq groups (cons (symbol-name group) groups)))) gnus-active-hashtb) ! ;; Also go through all descriptions that are known to Gnus. ! (when search-description ! (mapatoms ! (lambda (group) ! (and (string-match regexp (symbol-value group)) ! (gnus-active (symbol-name group)) ! (setq groups (cons (symbol-name group) groups)))) ! gnus-description-hashtb)) (if (not groups) (gnus-message 3 "No groups matched \"%s\"." regexp) ;; Print out all the groups. *************** *** 7293,7301 **** (defvar gnus-thread-indent-array-level gnus-thread-indent-level) (defun gnus-make-thread-indent-array () (let ((n 200)) ! (if (and gnus-thread-indent-array ! (= gnus-thread-indent-level gnus-thread-indent-array-level)) ! nil (setq gnus-thread-indent-array (make-vector 201 "") gnus-thread-indent-array-level gnus-thread-indent-level) (while (>= n 0) --- 7315,7322 ---- (defvar gnus-thread-indent-array-level gnus-thread-indent-level) (defun gnus-make-thread-indent-array () (let ((n 200)) ! (unless (and gnus-thread-indent-array ! (= gnus-thread-indent-level gnus-thread-indent-array-level)) (setq gnus-thread-indent-array (make-vector 201 "") gnus-thread-indent-array-level gnus-thread-indent-level) (while (>= n 0) *************** *** 7721,7735 **** (when (and (setq references (mail-header-references header)) (not (string= references ""))) (insert references) ! (setq child (downcase (mail-header-id header)) subject (mail-header-subject header)) (setq generation 0) (while (search-backward ">" nil t) (setq end (1+ (point))) (when (search-backward "<" nil t) (push (list (incf generation) ! child (setq child (downcase ! (buffer-substring (point) end))) subject) relations))) (push (list (1+ generation) child nil subject) relations) --- 7742,7755 ---- (when (and (setq references (mail-header-references header)) (not (string= references ""))) (insert references) ! (setq child (mail-header-id header) subject (mail-header-subject header)) (setq generation 0) (while (search-backward ">" nil t) (setq end (1+ (point))) (when (search-backward "<" nil t) (push (list (incf generation) ! child (setq child (buffer-substring (point) end)) subject) relations))) (push (list (1+ generation) child nil subject) relations) *************** *** 7868,7874 **** (defun gnus-id-to-thread (id) "Return the (sub-)thread where ID appears." ! (gnus-gethash (downcase id) gnus-newsgroup-dependencies)) (defun gnus-id-to-article (id) "Return the article number of ID." --- 7888,7894 ---- (defun gnus-id-to-thread (id) "Return the (sub-)thread where ID appears." ! (gnus-gethash id gnus-newsgroup-dependencies)) (defun gnus-id-to-article (id) "Return the article number of ID." *************** *** 7897,7905 **** (defun gnus-root-id (id) "Return the id of the root of the thread where ID appears." (let (last-id prev) ! (while (and id (setq prev (car (gnus-gethash ! (downcase id) ! gnus-newsgroup-dependencies)))) (setq last-id id id (gnus-parent-id (mail-header-references prev)))) last-id)) --- 7917,7924 ---- (defun gnus-root-id (id) "Return the id of the root of the thread where ID appears." (let (last-id prev) ! (while (and id (setq prev (car (gnus-gethash ! id gnus-newsgroup-dependencies)))) (setq last-id id id (gnus-parent-id (mail-header-references prev)))) last-id)) *************** *** 7940,7946 **** (if thread (unless dont-remove (setq gnus-newsgroup-threads (delq thread gnus-newsgroup-threads))) ! (setq thread (gnus-gethash (downcase last-id) dep))) (when thread (prog1 thread ; We return this thread. --- 7959,7965 ---- (if thread (unless dont-remove (setq gnus-newsgroup-threads (delq thread gnus-newsgroup-threads))) ! (setq thread (gnus-gethash last-id dep))) (when thread (prog1 thread ; We return this thread. *************** *** 8102,8108 **** (or (cdr (assq (mail-header-number root) gnus-newsgroup-scored)) gnus-summary-default-score 0) (mapcar 'gnus-thread-total-score ! (cdr (gnus-gethash (downcase (mail-header-id root)) gnus-newsgroup-dependencies))))) ;; Added by Per Abrahamsen . --- 8121,8127 ---- (or (cdr (assq (mail-header-number root) gnus-newsgroup-scored)) gnus-summary-default-score 0) (mapcar 'gnus-thread-total-score ! (cdr (gnus-gethash (mail-header-id root) gnus-newsgroup-dependencies))))) ;; Added by Per Abrahamsen . *************** *** 8957,8971 **** (setq end (match-end 0)) (save-excursion (setq ref ! (downcase ! (buffer-substring ! (progn ! (end-of-line) ! (search-backward ">" end t) ! (1+ (point))) ! (progn ! (search-backward "<" end t) ! (point))))))) ;; Get the references from the in-reply-to header if there ;; were no references and the in-reply-to header looks ;; promising. --- 8976,8989 ---- (setq end (match-end 0)) (save-excursion (setq ref ! (buffer-substring ! (progn ! (end-of-line) ! (search-backward ">" end t) ! (1+ (point))) ! (progn ! (search-backward "<" end t) ! (point)))))) ;; Get the references from the in-reply-to header if there ;; were no references and the in-reply-to header looks ;; promising. *************** *** 8975,8981 **** (prog1 (setq ref (substring in-reply-to (match-beginning 0) (match-end 0))) ! (setq ref (downcase ref)))) (setq ref ""))) ;; Chars. 0 --- 8993,8999 ---- (prog1 (setq ref (substring in-reply-to (match-beginning 0) (match-end 0))) ! (setq ref ref))) (setq ref ""))) ;; Chars. 0 *************** *** 8996,9002 **** ;; the same hash table. Some tippy-toeing around has to be ;; done in case an article has arrived before the article ;; which it refers to. ! (if (boundp (setq id-dep (intern (downcase id) dependencies))) (if (and (car (symbol-value id-dep)) (not force-new)) ;; An article with this Message-ID has already --- 9014,9020 ---- ;; the same hash table. Some tippy-toeing around has to be ;; done in case an article has arrived before the article ;; which it refers to. ! (if (boundp (setq id-dep (intern id dependencies))) (if (and (car (symbol-value id-dep)) (not force-new)) ;; An article with this Message-ID has already *************** *** 9102,9113 **** (search-forward "\t" eol) (if (search-backward ">" beg t) (setq ref ! (downcase ! (buffer-substring ! (1+ (point)) ! (progn ! (search-backward "<" beg t) ! (point))))) (setq ref nil)))) (gnus-nov-field)) ; refs (gnus-nov-read-integer) ; chars --- 9120,9128 ---- (search-forward "\t" eol) (if (search-backward ">" beg t) (setq ref ! (buffer-substring ! (1+ (point)) ! (search-backward "<" beg t))) (setq ref nil)))) (gnus-nov-field)) ; refs (gnus-nov-read-integer) ; chars *************** *** 9126,9132 **** ;; We build the thread tree. (when header ! (if (boundp (setq id-dep (intern (downcase id) dependencies))) (if (and (car (symbol-value id-dep)) (not force-new)) ;; An article with this Message-ID has already been seen, --- 9141,9147 ---- ;; We build the thread tree. (when header ! (if (boundp (setq id-dep (intern id dependencies))) (if (and (car (symbol-value id-dep)) (not force-new)) ;; An article with this Message-ID has already been seen, *************** *** 10728,10734 **** (setq message-id (concat "<" message-id))) (unless (string-match ">$" message-id) (setq message-id (concat message-id ">"))) ! (let ((header (car (gnus-gethash (downcase message-id) gnus-newsgroup-dependencies)))) (if header ;; The article is present in the buffer, to we just go to it. --- 10743,10749 ---- (setq message-id (concat "<" message-id))) (unless (string-match ">$" message-id) (setq message-id (concat message-id ">"))) ! (let ((header (car (gnus-gethash message-id gnus-newsgroup-dependencies)))) (if header ;; The article is present in the buffer, to we just go to it. *************** *** 12322,12327 **** --- 12337,12362 ---- "Go to the same level (or less) next thread. If PREVIOUS is non-nil, go to previous thread instead. Return the article number moved to, or nil if moving was impossible." + (let ((level (gnus-summary-thread-level)) + (way (if previous -1 1)) + (beg (point))) + (forward-line way) + (while (and (not (eobp)) + (< level (gnus-summary-thread-level))) + (forward-line way)) + (if (eobp) + (progn + (goto-char beg) + nil) + (setq beg (point)) + (prog1 + (gnus-summary-article-number) + (goto-char beg))))) + + (defun gnus-summary-go-to-next-thread-old (&optional previous) + "Go to the same level (or less) next thread. + If PREVIOUS is non-nil, go to previous thread instead. + Return the article number moved to, or nil if moving was impossible." (if (and (eq gnus-summary-make-false-root 'dummy) (gnus-summary-article-intangible-p)) (let ((beg (point))) *************** *** 12359,12374 **** (n (abs n)) old dum int) (while (and (> n 0) ! (setq old (save-excursion ! (forward-line 1) ! (setq int (gnus-summary-article-intangible-p)) ! (point))) ! (or int ! (gnus-summary-go-to-next-thread backward))) ! (when (and (eq gnus-summary-make-false-root 'dummy) ! (setq dum (text-property-not-all ! old (point) 'gnus-intangible nil))) ! (goto-char dum)) (decf n)) (unless silent (gnus-summary-position-point)) --- 12394,12400 ---- (n (abs n)) old dum int) (while (and (> n 0) ! (gnus-summary-go-to-next-thread backward)) (decf n)) (unless silent (gnus-summary-position-point)) *************** *** 13260,13275 **** (goto-char (point-max)) (insert ".\n") (goto-char (point-min)) ! (insert "211 " ! (int-to-string ! (cond ! ((numberp id) ! id) ! ((cdr where) ! (cdr where)) ! (t ! gnus-reffed-article-number))) ! " Article retrieved.\n")) (if (not (setq header (car (gnus-get-newsgroup-headers)))) () ; Malformed head. (if (and (stringp id) --- 13286,13298 ---- (goto-char (point-max)) (insert ".\n") (goto-char (point-min)) ! (insert "211 ") ! (princ (cond ! ((numberp id) id) ! ((cdr where) (cdr where)) ! (t gnus-reffed-article-number)) ! (current-buffer)) ! (insert " Article retrieved.\n")) (if (not (setq header (car (gnus-get-newsgroup-headers)))) () ; Malformed head. (if (and (stringp id) *************** *** 13409,13416 **** (gnus-article-setup-buffer) (set-buffer gnus-article-buffer) (let ((buffer-read-only nil)) ! (remove-text-properties (point-min) (point-max) ! gnus-hidden-properties)))) (defun gnus-article-hide-headers-if-wanted () "Hide unwanted headers if `gnus-have-all-headers' is nil. --- 13432,13438 ---- (gnus-article-setup-buffer) (set-buffer gnus-article-buffer) (let ((buffer-read-only nil)) ! (gnus-unhide-text (point-min) (point-max))))) (defun gnus-article-hide-headers-if-wanted () "Hide unwanted headers if `gnus-have-all-headers' is nil. *************** *** 13431,13436 **** --- 13453,13460 ---- (set-buffer gnus-article-buffer) (save-restriction (let ((buffer-read-only nil) + (props (nconc (list 'gnus-type 'headers) + gnus-hidden-properties)) (ignored (when (not (stringp gnus-visible-headers)) (cond ((stringp gnus-ignored-headers) gnus-ignored-headers) *************** *** 13451,13459 **** (while (looking-at "From ") (forward-line 1)) (unless (bobp) ! (add-text-properties ! (point-min) (point) ! (nconc (list 'gnus-type 'headers) gnus-hidden-properties))) ;; Then treat the rest of the header lines. (narrow-to-region (point) --- 13475,13481 ---- (while (looking-at "From ") (forward-line 1)) (unless (bobp) ! (gnus-hide-text (point-min) (point) props)) ;; Then treat the rest of the header lines. (narrow-to-region (point) *************** *** 13490,13499 **** (if delete (delete-region (point-min) (point-max)) ;; Suggested by Sudish Joseph . ! (add-text-properties ! (point) (point-max) ! (nconc (list 'gnus-type 'headers) ! gnus-hidden-properties))))))))) (defsubst gnus-article-header-rank (header) "Give the rank of the string HEADER as given by `gnus-sorted-header-list'." --- 13512,13518 ---- (if delete (delete-region (point-min) (point-max)) ;; Suggested by Sudish Joseph . ! (gnus-hide-text-type (point) (point-max) 'headers)))))))) (defsubst gnus-article-header-rank (header) "Give the rank of the string HEADER as given by `gnus-sorted-header-list'." *************** *** 13533,13547 **** ((eq elem 'empty) (while (re-search-forward "^[^:]+:[ \t]\n[^ \t]" nil t) (forward-line -1) ! (add-text-properties (progn (beginning-of-line) (point)) (progn (end-of-line) (if (re-search-forward "^[^ \t]" nil t) (match-beginning 0) (point-max))) ! (nconc (list 'gnus-type 'boring-headers) ! gnus-hidden-properties)))) ;; Hide boring Newsgroups header. ((eq elem 'newsgroups) (when (equal (mail-fetch-field "newsgroups") --- 13552,13565 ---- ((eq elem 'empty) (while (re-search-forward "^[^:]+:[ \t]\n[^ \t]" nil t) (forward-line -1) ! (gnus-hide-text-type (progn (beginning-of-line) (point)) (progn (end-of-line) (if (re-search-forward "^[^ \t]" nil t) (match-beginning 0) (point-max))) ! 'boring-headers))) ;; Hide boring Newsgroups header. ((eq elem 'newsgroups) (when (equal (mail-fetch-field "newsgroups") *************** *** 13571,13585 **** (save-excursion (goto-char (point-min)) (when (re-search-forward (concat "^" header ":") nil t) ! (add-text-properties (progn (beginning-of-line) (point)) (progn (end-of-line) (if (re-search-forward "^[^ \t]" nil t) (match-beginning 0) (point-max))) ! (nconc (list 'gnus-type 'boring-headers) ! gnus-hidden-properties))))) ;; Written by Per Abrahamsen . (defun gnus-article-treat-overstrike () --- 13589,13602 ---- (save-excursion (goto-char (point-min)) (when (re-search-forward (concat "^" header ":") nil t) ! (gnus-hide-text-type (progn (beginning-of-line) (point)) (progn (end-of-line) (if (re-search-forward "^[^ \t]" nil t) (match-beginning 0) (point-max))) ! 'boring-headers)))) ;; Written by Per Abrahamsen . (defun gnus-article-treat-overstrike () *************** *** 13755,13766 **** (goto-char (point-min)) ;; Hide the "header". (and (search-forward "\n-----BEGIN PGP SIGNED MESSAGE-----\n" nil t) ! (add-text-properties (match-beginning 0) (match-end 0) props)) (setq beg (point)) ;; Hide the actual signature. (and (search-forward "\n-----BEGIN PGP SIGNATURE-----\n" nil t) (setq end (match-beginning 0)) ! (add-text-properties (match-beginning 0) (if (search-forward "\n-----END PGP SIGNATURE-----\n" nil t) (match-end 0) --- 13772,13783 ---- (goto-char (point-min)) ;; Hide the "header". (and (search-forward "\n-----BEGIN PGP SIGNED MESSAGE-----\n" nil t) ! (gnus-hide-text (match-beginning 0) (match-end 0) props)) (setq beg (point)) ;; Hide the actual signature. (and (search-forward "\n-----BEGIN PGP SIGNATURE-----\n" nil t) (setq end (match-beginning 0)) ! (gnus-hide-text (match-beginning 0) (if (search-forward "\n-----END PGP SIGNATURE-----\n" nil t) (match-end 0) *************** *** 13773,13779 **** (narrow-to-region beg end) (goto-char (point-min)) (while (re-search-forward "^- " nil t) ! (add-text-properties (match-beginning 0) (match-end 0) props)) (widen)))))) (defun gnus-article-hide-signature (&optional arg) --- 13790,13796 ---- (narrow-to-region beg end) (goto-char (point-min)) (while (re-search-forward "^- " nil t) ! (gnus-hide-text (match-beginning 0) (match-end 0) props)) (widen)))))) (defun gnus-article-hide-signature (&optional arg) *************** *** 13787,13796 **** (save-restriction (let ((buffer-read-only nil)) (when (gnus-narrow-to-signature) ! (add-text-properties ! (point-min) (point-max) ! (nconc (list 'gnus-type 'signature) ! gnus-hidden-properties)))))))) (defun gnus-article-strip-leading-blank-lines () "Remove all blank lines from the beginning of the article." --- 13804,13810 ---- (save-restriction (let ((buffer-read-only nil)) (when (gnus-narrow-to-signature) ! (gnus-hide-text-type (point-min) (point-max) 'signature))))))) (defun gnus-article-strip-leading-blank-lines () "Remove all blank lines from the beginning of the article." *************** *** 13863,13870 **** (setq beg (point)) (forward-char) (if hide ! (add-text-properties beg (point) gnus-hidden-properties) ! (remove-text-properties beg (point) gnus-hidden-properties)) (setq beg (point))) t))) --- 13877,13884 ---- (setq beg (point)) (forward-char) (if hide ! (gnus-hide-text beg (point) gnus-hidden-properties) ! (gnus-unhide-text beg (point))) (setq beg (point))) t))) *************** *** 14565,14570 **** --- 14579,14586 ---- (defun gnus-open-server (method) "Open a connection to METHOD." + (when (stringp method) + (setq method (gnus-server-to-method method))) (let ((elem (assoc method gnus-opened-servers))) ;; If this method was previously denied, we just return nil. (if (eq (nth 1 elem) 'denied) *************** *** 14586,14608 **** --- 14602,14634 ---- (defun gnus-close-server (method) "Close the connection to METHOD." + (when (stringp method) + (setq method (gnus-server-to-method method))) (funcall (gnus-get-function method 'close-server) (nth 1 method))) (defun gnus-request-list (method) "Request the active file from METHOD." + (when (stringp method) + (setq method (gnus-server-to-method method))) (funcall (gnus-get-function method 'request-list) (nth 1 method))) (defun gnus-request-list-newsgroups (method) "Request the newsgroups file from METHOD." + (when (stringp method) + (setq method (gnus-server-to-method method))) (funcall (gnus-get-function method 'request-list-newsgroups) (nth 1 method))) (defun gnus-request-newgroups (date method) "Request all new groups since DATE from METHOD." + (when (stringp method) + (setq method (gnus-server-to-method method))) (funcall (gnus-get-function method 'request-newgroups) date (nth 1 method))) (defun gnus-server-opened (method) "Check whether a connection to METHOD has been opened." + (when (stringp method) + (setq method (gnus-server-to-method method))) (funcall (gnus-get-function method 'server-opened) (nth 1 method))) (defun gnus-status-message (method) *************** *** 14616,14621 **** --- 14642,14649 ---- (defun gnus-request-group (group &optional dont-check method) "Request GROUP. If DONT-CHECK, no information is required." (let ((method (or method (gnus-find-method-for-group group)))) + (when (stringp method) + (setq method (gnus-server-to-method method))) (funcall (gnus-get-function method 'request-group) (gnus-group-real-name group) (nth 1 method) dont-check))) *************** *** 14660,14665 **** --- 14688,14695 ---- (defun gnus-retrieve-groups (groups method) "Request active information on GROUPS from METHOD." + (when (stringp method) + (setq method (gnus-server-to-method method))) (funcall (gnus-get-function method 'retrieve-groups) groups (nth 1 method))) (defun gnus-request-type (group &optional article) *************** *** 14700,14705 **** --- 14730,14737 ---- (defun gnus-request-post (method) "Post the current buffer using METHOD." + (when (stringp method) + (setq method (gnus-server-to-method method))) (funcall (gnus-get-function method 'request-post) (nth 1 method))) (defun gnus-request-scan (group method) *************** *** 14711,14716 **** --- 14743,14750 ---- (defsubst gnus-request-update-info (info method) "Request that METHOD update INFO." + (when (stringp method) + (setq method (gnus-server-to-method method))) (when (gnus-check-backend-function 'request-update-info (car method)) (funcall (gnus-get-function method 'request-update-info) (gnus-group-real-name (gnus-info-group info)) *************** *** 14731,14736 **** --- 14765,14772 ---- (defun gnus-request-accept-article (group &optional last method) ;; Make sure there's a newline at the end of the article. + (when (stringp method) + (setq method (gnus-server-to-method method))) (goto-char (point-max)) (unless (bolp) (insert "\n")) *************** *** 14757,14762 **** --- 14793,14800 ---- article (gnus-group-real-name group) (nth 1 method)))) (defun gnus-request-create-group (group &optional method) + (when (stringp method) + (setq method (gnus-server-to-method method))) (let ((method (or method (gnus-find-method-for-group group)))) (funcall (gnus-get-function method 'request-create-group) (gnus-group-real-name group) (nth 1 method)))) *************** *** 14780,14785 **** --- 14818,14825 ---- (defun gnus-method-option-p (method option) "Return non-nil if select METHOD has OPTION as a parameter." + (when (stringp method) + (setq method (gnus-server-to-method method))) (memq option (assoc (format "%s" (car method)) gnus-valid-select-methods))) *************** *** 14894,14899 **** --- 14934,14943 ---- (gnus-check-server gnus-select-method)) (gnus-find-new-newsgroups)) + ;; We might read in new NoCeM messages here. + (when gnus-use-nocem + (gnus-nocem-scan-groups)) + ;; Find the number of unread articles in each non-dead group. (let ((gnus-read-active-file (and (not level) gnus-read-active-file))) (gnus-get-unread-articles level)) *************** *** 15357,15368 **** (setq gnus-killed-hashtb (gnus-make-hashtable (+ (length gnus-killed-list) (length gnus-zombie-list)))) ! (while lists ! (setq list (symbol-value (car lists))) ! (setq lists (cdr lists)) (while list ! (gnus-sethash (car list) (car list) gnus-killed-hashtb) ! (setq list (cdr list)))))) (defun gnus-get-unread-articles-in-group (info active &optional update) (when active --- 15401,15409 ---- (setq gnus-killed-hashtb (gnus-make-hashtable (+ (length gnus-killed-list) (length gnus-zombie-list)))) ! (while (setq list (symbol-value (pop lists))) (while list ! (gnus-sethash (car list) (pop list) gnus-killed-hashtb))))) (defun gnus-get-unread-articles-in-group (info active &optional update) (when active *************** *** 16213,16219 **** (set-buffer (create-file-buffer gnus-current-startup-file)) (let ((newsrc (cdr gnus-newsrc-alist)) (standard-output (current-buffer)) ! info ranges range) (setq buffer-file-name gnus-current-startup-file) (buffer-disable-undo (current-buffer)) (erase-buffer) --- 16254,16260 ---- (set-buffer (create-file-buffer gnus-current-startup-file)) (let ((newsrc (cdr gnus-newsrc-alist)) (standard-output (current-buffer)) ! info ranges range method) (setq buffer-file-name gnus-current-startup-file) (buffer-disable-undo (current-buffer)) (erase-buffer) *************** *** 16222,16228 **** ;; Write subscribed and unsubscribed. (while (setq info (pop newsrc)) ;; Don't write foreign groups to .newsrc. ! (when (gnus-server-equal (gnus-info-method info) gnus-select-method) (insert (gnus-info-group info) (if (> (gnus-info-level info) gnus-level-subscribed) "!" ":")) --- 16263,16271 ---- ;; Write subscribed and unsubscribed. (while (setq info (pop newsrc)) ;; Don't write foreign groups to .newsrc. ! (when (or (null (setq method (gnus-info-method info))) ! (equal method "native") ! (gnus-server-equal method gnus-select-method)) (insert (gnus-info-group info) (if (> (gnus-info-level info) gnus-level-subscribed) "!" ":")) *************** *** 16234,16242 **** (princ (car ranges)) (insert "-") (princ (cdr ranges))) ! (while ranges ! (setq range (car ranges) ! ranges (cdr ranges)) (if (or (atom range) (= (car range) (cdr range))) (princ (or (and (atom range) range) (car range))) (princ (car range)) --- 16277,16283 ---- (princ (car ranges)) (insert "-") (princ (cdr ranges))) ! (while (setq range (pop ranges)) (if (or (atom range) (= (car range) (cdr range))) (princ (or (and (atom range) range) (car range))) (princ (car range)) *** pub/sgnus/lisp/nnmail.el Tue Mar 12 03:31:03 1996 --- sgnus/lisp/nnmail.el Thu Mar 14 06:30:06 1996 *************** *** 688,714 **** (list (list group "")) nnmail-split-methods))) (save-excursion - ;; Open the message-id cache. - (nnmail-cache-open) ;; Insert the incoming file. (set-buffer (get-buffer-create " *nnmail incoming*")) (buffer-disable-undo (current-buffer)) (erase-buffer) (insert-file-contents incoming) ! (goto-char (point-min)) ! (save-excursion (run-hooks 'nnmail-prepare-incoming-hook)) ! ;; Handle both babyl, MMDF and unix mail formats, since movemail will ! ;; use the former when fetching from a mailbox, the latter when ! ;; fetches from a file. ! (cond ((or (looking-at "\^L") ! (looking-at "BABYL OPTIONS:")) ! (nnmail-process-babyl-mail-format func)) ! ((looking-at "\^A\^A\^A\^A") ! (nnmail-process-mmdf-mail-format func)) ! (t ! (nnmail-process-unix-mail-format func))) ! ;; Close the message-id cache. ! (nnmail-cache-close) (if exit-func (funcall exit-func)) (kill-buffer (current-buffer))))) --- 688,711 ---- (list (list group "")) nnmail-split-methods))) (save-excursion ;; Insert the incoming file. (set-buffer (get-buffer-create " *nnmail incoming*")) (buffer-disable-undo (current-buffer)) (erase-buffer) (insert-file-contents incoming) ! (unless (zerop (buffer-size)) ! (goto-char (point-min)) ! (save-excursion (run-hooks 'nnmail-prepare-incoming-hook)) ! ;; Handle both babyl, MMDF and unix mail formats, since movemail will ! ;; use the former when fetching from a mailbox, the latter when ! ;; fetches from a file. ! (cond ((or (looking-at "\^L") ! (looking-at "BABYL OPTIONS:")) ! (nnmail-process-babyl-mail-format func)) ! ((looking-at "\^A\^A\^A\^A") ! (nnmail-process-mmdf-mail-format func)) ! (t ! (nnmail-process-unix-mail-format func)))) (if exit-func (funcall exit-func)) (kill-buffer (current-buffer))))) *************** *** 1083,1088 **** --- 1080,1087 ---- (nnmail-activate method) ;; Allow the user to hook. (run-hooks 'nnmail-pre-get-new-mail-hook) + ;; Open the message-id cache. + (nnmail-cache-open) ;; The we go through all the existing spool files and split the ;; mail from each. (while spools *************** *** 1123,1128 **** --- 1122,1129 ---- (funcall exit-func)) (run-hooks 'nnmail-read-incoming-hook) (nnheader-message 3 "%s: Reading incoming mail...done" method)) + ;; Close the message-id cache. + (nnmail-cache-close) ;; Allow the user to hook. (run-hooks 'nnmail-post-get-new-mail-hook) ;; Delete all the temporary files. *** pub/sgnus/lisp/nnmbox.el Tue Mar 12 03:31:03 1996 --- sgnus/lisp/nnmbox.el Sat Mar 16 08:15:30 1996 *************** *** 315,320 **** --- 315,321 ---- (setq result (nnmbox-save-mail (and (stringp group) group)))) (save-excursion (set-buffer nnmbox-mbox-buffer) + (goto-char (point-max)) (insert-buffer-substring buf) (and last (save-buffer)) result) *** pub/sgnus/lisp/nnsoup.el Tue Mar 12 03:31:04 1996 --- sgnus/lisp/nnsoup.el Wed Mar 13 05:58:55 1996 *************** *** 77,82 **** --- 77,83 ---- (defvar nnsoup-replies-list nil) (defvar nnsoup-buffers nil) (defvar nnsoup-current-group nil) + (defvar nnsoup-group-alist-touched nil) *************** *** 96,101 **** --- 97,103 ---- (nnsoup-packet-directory ,nnsoup-packet-directory) (nnsoup-unpacker ,nnsoup-unpacker) (nnsoup-packer ,nnsoup-packer) + (nnsoup-group-alist-touched nil) (nnsoup-replies-index-type ,nnsoup-replies-index-type) (nnsoup-replies-format-type ,nnsoup-replies-format-type) (nnsoup-replies-directory ,nnsoup-replies-directory) *************** *** 213,218 **** --- 215,221 ---- (defun nnsoup-close-server (&optional server) (setq nnsoup-current-server nil + nnsoup-group-alist-touched nil nnsoup-group-alist nil) t) *************** *** 228,233 **** --- 231,237 ---- (buffer-name buffer) (kill-buffer buffer)))) (setq nnsoup-group-alist nil + nnsoup-group-alist-touched nil nnsoup-current-group nil nnsoup-current-server nil nnsoup-server-alist nil *************** *** 294,303 **** (set-buffer nntp-server-buffer) (erase-buffer) (let ((alist nnsoup-group-alist) entry) (while (setq entry (pop alist)) ! (insert (format "%s %d %d y\n" (car entry) ! (cdadr entry) (caadr entry)))) t))) (defun nnsoup-request-scan (group &optional server) --- 298,311 ---- (set-buffer nntp-server-buffer) (erase-buffer) (let ((alist nnsoup-group-alist) + (standard-output (current-buffer)) entry) (while (setq entry (pop alist)) ! (insert (car entry) " ") ! (princ (cdadr entry)) ! (insert " ") ! (princ (caadr entry)) ! (insert " y\n")) t))) (defun nnsoup-request-scan (group &optional server) *************** *** 357,363 **** (if (cddr total-infolist) (setcar active (caaadr (cdr total-infolist))) (setcar active (1+ (cdr active)))) ! (nnsoup-write-active-file) ;; Return the articles that weren't expired. articles)) --- 365,371 ---- (if (cddr total-infolist) (setcar active (caaadr (cdr total-infolist))) (setcar active (1+ (cdr active)))) ! (nnsoup-write-active-file t) ;; Return the articles that weren't expired. articles)) *************** *** 373,379 **** (setq nnsoup-group-alist) (when (file-exists-p nnsoup-active-file) (condition-case () ! (load nnsoup-active-file) (error nil)) ;; Be backwards compatible. (when (and nnsoup-group-alist --- 381,387 ---- (setq nnsoup-group-alist) (when (file-exists-p nnsoup-active-file) (condition-case () ! (load nnsoup-active-file t t t) (error nil)) ;; Be backwards compatible. (when (and nnsoup-group-alist *************** *** 385,405 **** (while (cdr e) (setq e (cdr e))) (setq max (cdaar e)) ! (setcdr entry (cons (cons min max) (cdr entry)))))) nnsoup-group-alist)) ! (defun nnsoup-write-active-file () ! (when nnsoup-group-alist ! (save-excursion ! (set-buffer (get-buffer-create " *nnsoup work*")) ! (buffer-disable-undo (current-buffer)) ! (erase-buffer) ! (insert (format "(setq nnsoup-group-alist '%S)\n" nnsoup-group-alist)) ! (insert (format "(setq nnsoup-current-prefix %d)\n" ! nnsoup-current-prefix)) ! (write-region (point-min) (point-max) nnsoup-active-file ! nil 'silent) ! (kill-buffer (current-buffer))))) (defun nnsoup-next-prefix () "Return the next free prefix." --- 393,411 ---- (while (cdr e) (setq e (cdr e))) (setq max (cdaar e)) ! (setcdr entry (cons (cons min max) (cdr entry))))) ! (setq nnsoup-group-alist-touched t)) nnsoup-group-alist)) ! (defun nnsoup-write-active-file (&optional force) ! (when (and nnsoup-group-alist ! (or force ! nnsoup-group-alist-touched)) ! (setq nnsoup-group-alist-touched nil) ! (nnheader-temp-write nnsoup-active-file ! (let ((standard-output (current-buffer))) ! (prin1 `(setq nnsoup-group-alist ',nnsoup-group-alist)) ! (prin1 `(setq nnsoup-current-prefix ,nnsoup-current-prefix)))))) (defun nnsoup-next-prefix () "Return the next free prefix." *************** *** 447,453 **** (+ lnum number)) area))) (setcdr (cadr entry) (+ lnum number)))))) ! (nnsoup-write-active-file) (delete-file (concat nnsoup-tmp-directory "AREAS")))) (defun nnsoup-number-of-articles (area) --- 453,459 ---- (+ lnum number)) area))) (setcdr (cadr entry) (+ lnum number)))))) ! (nnsoup-write-active-file t) (delete-file (concat nnsoup-tmp-directory "AREAS")))) (defun nnsoup-number-of-articles (area) *************** *** 748,754 **** (while active (setcdr (car active) (nreverse (cdar active))) (setq active (cdr active))) ! (nnsoup-write-active-file))) (defun nnsoup-delete-unreferenced-message-files () "Delete any *.MSG and *.IDX files that aren't known by nnsoup." --- 754,760 ---- (while active (setcdr (car active) (nreverse (cdar active))) (setq active (cdr active))) ! (nnsoup-write-active-file t))) (defun nnsoup-delete-unreferenced-message-files () "Delete any *.MSG and *.IDX files that aren't known by nnsoup." *** pub/sgnus/lisp/nnspool.el Tue Mar 12 03:31:04 1996 --- sgnus/lisp/nnspool.el Thu Mar 14 18:22:30 1996 *************** *** 124,129 **** --- 124,130 ---- (when (nnspool-possibly-change-directory group) (let* ((number (length articles)) (count 0) + (default-directory nnspool-current-directory) (do-message (and (numberp nnspool-large-newsgroup) (> number nnspool-large-newsgroup))) file beg article ag) *************** *** 132,139 **** ;; We successfully retrieved the NOV headers. 'nov ;; No NOV headers here, so we do it the hard way. ! (while articles ! (setq article (pop articles)) (if (stringp article) ;; This is a Message-ID. (setq ag (nnspool-find-id article) --- 133,139 ---- ;; We successfully retrieved the NOV headers. 'nov ;; No NOV headers here, so we do it the hard way. ! (while (setq article (pop articles)) (if (stringp article) ;; This is a Message-ID. (setq ag (nnspool-find-id article) *************** *** 141,154 **** (car ag) (cdr ag))) article (cdr ag)) ;; This is an article in the current group. ! (setq file (nnspool-article-pathname ! nnspool-current-group article))) ;; Insert the head of the article. (when (and file (file-exists-p file)) ! (insert (format "221 %d Article retrieved.\n" article)) (setq beg (point)) ! (nnheader-insert-head file) (goto-char beg) (search-forward "\n\n" nil t) (forward-char -1) --- 141,155 ---- (car ag) (cdr ag))) article (cdr ag)) ;; This is an article in the current group. ! (setq file (int-to-string article))) ;; Insert the head of the article. (when (and file (file-exists-p file)) ! (insert "221 ") ! (princ article (current-buffer)) ! (insert " Article retrieved.\n") (setq beg (point)) ! (inline (nnheader-insert-head file)) (goto-char beg) (search-forward "\n\n" nil t) (forward-char -1) *** pub/sgnus/lisp/nntp.el Tue Mar 12 03:31:04 1996 --- sgnus/lisp/nntp.el Sat Mar 16 08:15:42 1996 *************** *** 1043,1049 **** (defun nntp-send-xover-command (beg end &optional wait-for-reply) "Send the XOVER command to the server." ! (let ((range (format "%d-%d" beg end))) (if (stringp nntp-server-xover) ;; If `nntp-server-xover' is a string, then we just send this ;; command. --- 1043,1049 ---- (defun nntp-send-xover-command (beg end &optional wait-for-reply) "Send the XOVER command to the server." ! (let ((range (format "%d-%d" (or beg 1) (or end beg 1)))) (if (stringp nntp-server-xover) ;; If `nntp-server-xover' is a string, then we just send this ;; command. *** pub/sgnus/lisp/nnvirtual.el Tue Mar 12 03:31:04 1996 --- sgnus/lisp/nnvirtual.el Thu Mar 14 06:29:40 1996 *************** *** 274,279 **** --- 274,285 ---- (nnvirtual-possibly-change-group group server t) (let ((gnus-group-marked nnvirtual-component-groups) (gnus-expert-user t)) + ;; Make sure all groups are activated. + (mapcar + (lambda (g) + (when (not (numberp (car (gnus-gethash g gnus-newsrc-hashtb)))) + (gnus-activate-group g))) + nnvirtual-component-groups) (save-excursion (set-buffer gnus-group-buffer) (gnus-group-catchup-current nil all)))) *** pub/sgnus/lisp/ChangeLog Tue Mar 12 03:31:11 1996 --- sgnus/lisp/ChangeLog Sat Mar 16 16:16:56 1996 *************** *** 1,4 **** --- 1,77 ---- + Sat Mar 16 14:46:29 1996 Brad Miller + + * gnus-gl.el: New version. + + Sat Mar 16 13:28:57 1996 Lars Magne Ingebrigtsen + + * gnus-score.el (gnus-score-body): Would break on nil + `gnus-scores-articles'? + + * gnus.el: All the backend interface functions should take virtual + server names. + + * gnus-msg.el (gnus-post-method): Find the real method. + + * gnus.el (gnus-summary-go-to-next-thread): New definition. + (gnus-summary-next-thread): Use it. + (gnus-prefix-to-server): New function. + + * gnus-vis.el (gnus-signature-toggle): Use new substs. + (gnus-article-highlight-signature): Would make check point wrong. + + * gnus.el (gnus-hide-text): New subst. + (gnus-hide-text-type): New function. + (gnus-unhide-text): New subst. + (gnus-article-show-all-headers, gnus-article-hide-headers, + gnus-article-hide-pgp, gnus-article-hide-header, + gnus-article-hide-boring-headers): Use them. + + Fri Mar 15 07:39:10 1996 Lars Magne Ingebrigtsen + + * nntp.el (nntp-send-xover-command): Would bug out on + single-article groups. + + * gnus.el (gnus-group-prepare-flat): Deal with unactivated groups. + * gnus-topic.el (gnus-topic-find-groups): Ditto. + + Thu Mar 14 05:24:42 1996 Lars Magne Ingebrigtsen + + * nnspool.el (nnspool-retrieve-headers): Use default-directory to + avoid creating so many garbage strings. + + * nnmail.el (nnmail-split-incoming): Make sure the buffer isn't + empty before starting treatment. + (nnmail-get-new-mail): Open/close cache here. + + * gnus-msg.el (gnus-news-followup): Use markers for positions. + + * gnus.el (gnus-setup-news): Read NoCeM. + + Wed Mar 13 03:26:44 1996 Lars Magne Ingebrigtsen + + * gnus.el (gnus-functionp): Made into a subst. + (gnus-all-windows-visible-p): Non-recursive implementation. + + * nnsoup.el (nnsoup-request-list): Don't use `format'. + + * gnus.el (gnus-update-format-specifications): Would recompute all + specs every time. + (gnus-gnus-to-newsrc-format): Don't call `gnus-server-equal' for + each group. + + * nnspool.el (nnspool-retrieve-headers): Don't call so many + functions. + + * gnus-cache.el (gnus-cache-retrieve-headers): Would do too much + work. + + * gnus-topic.el (gnus-topic-goto-topic): Faster. + + * gnus.el: Don't downcase Message-IDs before threading. + Tue Mar 12 01:42:11 1996 Lars Magne Ingebrigtsen + + * gnus.el: September Gnus v0.52 is released. * gnus.el (gnus-article-strip-leading-blank-lines): New command. *** pub/sgnus/texi/gnus.texi Tue Mar 12 03:31:13 1996 --- sgnus/texi/gnus.texi Wed Mar 13 00:10:40 1996 *************** *** 2566,2572 **** * Saving Articles:: Ways of customizing article saving. * Decoding Articles:: Gnus can treat series of (uu)encoded articles. * Article Treatment:: The article buffer can be mangled at will. ! * Summary Sorting:: You can sort the summary buffer four ways. * Finding the Parent:: No child support? Get the parent. * Alternative Approaches:: Reading using non-default summaries. * Tree Display:: A more visual display of threads. --- 2566,2572 ---- * Saving Articles:: Ways of customizing article saving. * Decoding Articles:: Gnus can treat series of (uu)encoded articles. * Article Treatment:: The article buffer can be mangled at will. ! * Summary Sorting:: Sorting the summary buffer in various ways. * Finding the Parent:: No child support? Get the parent. * Alternative Approaches:: Reading using non-default summaries. * Tree Display:: A more visual display of threads.