* gnus-art.el (gnus-picon-databases): Moved here.
authorLars Magne Ingebrigtsen <larsi@gnus.org>
Sat, 12 Jan 2002 18:20:17 +0000 (18:20 +0000)
committerLars Magne Ingebrigtsen <larsi@gnus.org>
Sat, 12 Jan 2002 18:20:17 +0000 (18:20 +0000)
(gnus-picons-installed-p): Moved here.
(gnus-article-reply-with-original): Use `mark'.

* gnus.el (gnus-picon): Moved here and renamed.

* gnus-art.el (gnus-treat-from-picon): Only be on if picons are
installed.
(gnus-treat-mail-picon): Ditto.
(gnus-treat-newsgroups-picon): Ditto.

* gnus-picon.el (gnus-picons-installed-p): New function.

lisp/ChangeLog
lisp/gnus-art.el
lisp/gnus-picon.el
lisp/gnus.el
lisp/nnmail.el
lisp/nnvirtual.el

index 50ecdd4..c31fc63 100644 (file)
@@ -1,3 +1,18 @@
+2002-01-12  Lars Magne Ingebrigtsen  <larsi@gnus.org>
+
+       * gnus-art.el (gnus-picon-databases): Moved here.
+       (gnus-picons-installed-p): Moved here.
+       (gnus-article-reply-with-original): Use `mark'.
+
+       * gnus.el (gnus-picon): Moved here and renamed.
+
+       * gnus-art.el (gnus-treat-from-picon): Only be on if picons are
+       installed.
+       (gnus-treat-mail-picon): Ditto.
+       (gnus-treat-newsgroups-picon): Ditto.
+
+       * gnus-picon.el (gnus-picons-installed-p): New function.
+
 2002-01-12  ShengHuo ZHU  <zsh@cs.rochester.edu>
 
        * gnus-agent.el (gnus-agent-go-online): Fix doc.
index c6894a6..8f70946 100644 (file)
@@ -704,6 +704,21 @@ be controlled by `gnus-treat-body-boundary'."
   :type '(choice (item :tag "None" :value nil)
                 string))
 
+(defcustom gnus-picon-databases '("/usr/lib/picon" "/usr/local/faces")
+  "*Defines the location of the faces database.
+For information on obtaining this database of pretty pictures, please
+see http://www.cs.indiana.edu/picons/ftp/index.html"
+  :type 'directory
+  :group 'gnus-picon)
+
+(defun gnus-picons-installed-p ()
+  "Say whether picons are installed on your machine."
+  (let ((installed nil))
+    (dolist (database gnus-picon-databases)
+      (when (file-exists-p database)
+       (setq installed t)))
+    installed))
+
 (defcustom gnus-article-mime-part-function nil
   "Function called with a MIME handle as the argument.
 This is meant for people who want to do something automatic based
@@ -1079,7 +1094,8 @@ See Info node `(gnus)Customizing Articles' and Info node
 (put 'gnus-treat-display-smileys 'highlight t)
 
 (defcustom gnus-treat-from-picon
-  (if (gnus-image-type-available-p 'xpm)
+  (if (and (gnus-image-type-available-p 'xpm)
+          (gnus-picons-installed-p))
       'head nil)
   "Display picons in the From header.
 Valid values are nil, t, `head', `last', an integer or a predicate.
@@ -1090,7 +1106,8 @@ See Info node `(gnus)Customizing Articles' and Info node
 (put 'gnus-treat-from-picon 'highlight t)
 
 (defcustom gnus-treat-mail-picon
-  (if (gnus-image-type-available-p 'xpm)
+  (if (and (gnus-image-type-available-p 'xpm)
+          (gnus-picons-installed-p))
       'head nil)
   "Display picons in To and Cc headers.
 Valid values are nil, t, `head', `last', an integer or a predicate.
@@ -1101,7 +1118,8 @@ See Info node `(gnus)Customizing Articles' and Info node
 (put 'gnus-treat-mail-picon 'highlight t)
 
 (defcustom gnus-treat-newsgroups-picon
-  (if (gnus-image-type-available-p 'xpm)
+  (if (and (gnus-image-type-available-p 'xpm)
+          (gnus-picons-installed-p))
       'head nil)
   "Display picons in the Newsgroups and Followup-To headers.
 Valid values are nil, t, `head', `last', an integer or a predicate.
@@ -4680,7 +4698,7 @@ The text in the region will be yanked.  If the region isn't active,
 the entire article will be yanked."
   (interactive "P")
   (let ((article (cdr gnus-article-current)) cont)
-    (if (not mark-active)
+    (if (not (mark))
        (gnus-summary-reply (list (list article)) wide)
       (setq cont (buffer-substring (point) (mark)))
       ;; Deactivate active regions.
index f27ab4e..1780aca 100644 (file)
 
 ;;; User variables:
 
-(defgroup picon nil
-  "Show pictures of people, domains, and newsgroups."
-  :group 'gnus-visual)
-
-(defcustom gnus-picon-databases '("/usr/lib/picon" "/usr/local/faces")
-  "*Defines the location of the faces database.
-For information on obtaining this database of pretty pictures, please
-see http://www.cs.indiana.edu/picons/ftp/index.html"
-  :type 'directory
-  :group 'picon)
-
 (defcustom gnus-picon-news-directories '("news")
   "*List of directories to search for newsgroups faces."
   :type '(repeat string)
-  :group 'picon)
+  :group 'gnus-picon)
 
 (defcustom gnus-picon-user-directories '("users" "usenix" "local" "misc")
   "*List of directories to search for user faces."
   :type '(repeat string)
-  :group 'picon)
+  :group 'gnus-picon)
 
 (defcustom gnus-picon-domain-directories '("domains")
   "*List of directories to search for domain faces.
 Some people may want to add \"unknown\" to this list."
   :type '(repeat string)
-  :group 'picon)
+  :group 'gnus-picon)
 
 (defcustom gnus-picon-file-types
   (let ((types (list "xbm")))
@@ -80,15 +69,15 @@ Some people may want to add \"unknown\" to this list."
     types)
   "*List of suffixes on picon file names to try."
   :type '(repeat string)
-  :group 'picon)
+  :group 'gnus-picon)
 
 (defface gnus-picon-xbm-face '((t (:foreground "black" :background "white")))
   "Face to show xbm picon in."
-  :group 'picon)
+  :group 'gnus-picon)
 
 (defface gnus-picon-face '((t (:foreground "black" :background "white")))
   "Face to show picon in."
-  :group 'picon)
+  :group 'gnus-picon)
 
 ;;; Internal variables:
 
index b0698a2..125e1e1 100644 (file)
   :link '(custom-manual "(gnus)Summary Maneuvering")
   :group 'gnus-summary)
 
+(defgroup gnus-picon nil
+  "Show pictures of people, domains, and newsgroups."
+  :group 'gnus-visual)
+
 (defgroup gnus-summary-mail nil
   "Mail group commands."
   :link '(custom-manual "(gnus)Mail Group Commands")
index 3403176..f669d7d 100644 (file)
@@ -702,7 +702,7 @@ If SOURCE is a directory spec, try to return the group name component."
 
 (defsubst nnmail-search-unix-mail-delim ()
   "Put point at the beginning of the next Unix mbox message."
-  ;; Algorithm used to find the the next article in the
+  ;; Algorithm used to find the next article in the
   ;; brain-dead Unix mbox format:
   ;;
   ;; 1) Search for "^From ".
@@ -731,7 +731,7 @@ If SOURCE is a directory spec, try to return the group name component."
 
 (defun nnmail-search-unix-mail-delim-backward ()
   "Put point at the beginning of the current Unix mbox message."
-  ;; Algorithm used to find the the next article in the
+  ;; Algorithm used to find the next article in the
   ;; brain-dead Unix mbox format:
   ;;
   ;; 1) Search for "^From ".
@@ -1266,10 +1266,10 @@ See the documentation for the variable `nnmail-split-fancy' for documentation."
            (push (cdr cached-pair) nnmail-split-trace))
          (let ((split-rest (cddr split))
                (end (match-end 0))
-             ;; The searched regexp is \(\(FIELD\).*\)\(VALUE\).  So,
-               ;; start-of-value is the the point just before the
-              ;; beginning of the value, whereas after-header-name is
-               ;; the point just after the field name.
+               ;; The searched regexp is \(\(FIELD\).*\)\(VALUE\).
+               ;; So, start-of-value is the point just before the
+               ;; beginning of the value, whereas after-header-name
+               ;; is the point just after the field name.
                (start-of-value (match-end 1))
                (after-header-name (match-end 2)))
            ;; Start the next search just before the beginning of the
index bd45c7d..046c470 100644 (file)
@@ -521,14 +521,15 @@ If UPDATE-P is not nil, call gnus-group-update-group on the components."
 
 
 ;;; We map between virtual articles and real articles in a manner
-;;; which keeps the size of the virtual active list the same as
-;;; the sum of the component active lists.
-;;; To achieve fair mixing of the groups, the last article in
-;;; each of N component groups will be in the the last N articles
-;;; in the virtual group.
-
-;;; If you have 3 components A, B and C, with articles 1-8, 1-5, and 6-7
-;;; resprectively, then the virtual article numbers look like:
+;;; which keeps the size of the virtual active list the same as the
+;;; sum of the component active lists.
+
+;;; To achieve fair mixing of the groups, the last article in each of
+;;; N component groups will be in the last N articles in the virtual
+;;; group.
+
+;;; If you have 3 components A, B and C, with articles 1-8, 1-5, and
+;;; 6-7 resprectively, then the virtual article numbers look like:
 ;;;
 ;;;  1  2  3  4  5  6  7  8  9  10 11 12 13 14 15
 ;;;  A1 A2 A3 A4 B1 A5 B2 A6 B3 A7 B4 C6 A8 B5 C7