annotate lisp/gnus/gnus-vis.el @ 7:c153ca296910

Added tag r19-15b4 for changeset 27bc7f280385
author cvs
date Mon, 13 Aug 2007 08:47:16 +0200
parents ac2d302a0011
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1 ;;; gnus-vis.el --- display-oriented parts of Gnus
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
2 ;; Copyright (C) 1995,96 Free Software Foundation, Inc.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
3
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
4 ;; Author: Lars Magne Ingebrigtsen <larsi@ifi.uio.no>
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
5 ;; Per Abrahamsen <abraham@iesd.auc.dk>
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
6 ;; Keywords: news
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
7
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
8 ;; This file is part of GNU Emacs.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
9
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
10 ;; GNU Emacs is free software; you can redistribute it and/or modify
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
11 ;; it under the terms of the GNU General Public License as published by
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
12 ;; the Free Software Foundation; either version 2, or (at your option)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
13 ;; any later version.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
14
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
15 ;; GNU Emacs is distributed in the hope that it will be useful,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
16 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
17 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
18 ;; GNU General Public License for more details.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
19
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
20 ;; You should have received a copy of the GNU General Public License
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
21 ;; along with GNU Emacs; see the file COPYING. If not, write to the
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
22 ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
23 ;; Boston, MA 02111-1307, USA.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
24
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
25 ;;; Commentary:
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
26
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
27 ;;; Code:
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
28
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
29 (require 'gnus)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
30 (require 'gnus-ems)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
31 (require 'easymenu)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
32 (require 'custom)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
33 (require 'browse-url)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
34 (require 'gnus-score)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
35 (eval-when-compile (require 'cl))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
36
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
37 (defvar gnus-group-menu-hook nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
38 "*Hook run after the creation of the group mode menu.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
39
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
40 (defvar gnus-summary-menu-hook nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
41 "*Hook run after the creation of the summary mode menu.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
42
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
43 (defvar gnus-article-menu-hook nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
44 "*Hook run after the creation of the article mode menu.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
45
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
46 ;;; Summary highlights.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
47
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
48 ;(defvar gnus-summary-highlight-properties
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
49 ; '((unread "ForestGreen" "green")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
50 ; (ticked "Firebrick" "pink")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
51 ; (read "black" "white")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
52 ; (low italic italic)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
53 ; (high bold bold)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
54 ; (canceled "yellow/black" "black/yellow")))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
55
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
56 ;(defvar gnus-summary-highlight-translation
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
57 ; '(((unread (= mark gnus-unread-mark))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
58 ; (ticked (or (= mark gnus-ticked-mark) (= mark gnus-dormant-mark)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
59 ; (read (not (or (= mark gnus-unread-mark) (= mark gnus-dormant-mark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
60 ; (= mark gnus-ticked-mark) (= mark gnus-canceled-mark))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
61 ; (canceled (= mark gnus-canceled-mark)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
62 ; ((low (< score gnus-summary-default-score))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
63 ; (high (> score gnus-summary-default-score)))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
64
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
65 ;(defun gnus-visual-map-face-translation ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
66 ; (let ((props gnus-summary-highlight-properties)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
67 ; (trans gnus-summary-highlight-translation)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
68 ; map)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
69 ; (while props)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
70
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
71 ;see gnus-cus.el
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
72 ;(defvar gnus-summary-selected-face 'underline
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
73 ; "*Face used for highlighting the current article in the summary buffer.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
74
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
75 ;see gnus-cus.el
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
76 ;(defvar gnus-summary-highlight
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
77 ; (cond ((not (eq gnus-display-type 'color))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
78 ; '(((> score default) . bold)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
79 ; ((< score default) . italic)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
80 ; ((eq gnus-background-mode 'dark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
81 ; (list (cons '(= mark gnus-canceled-mark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
82 ; (custom-face-lookup "yellow" "black" nil nil nil nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
83 ; (cons '(and (> score default)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
84 ; (or (= mark gnus-dormant-mark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
85 ; (= mark gnus-ticked-mark)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
86 ; (custom-face-lookup "pink" nil nil t nil nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
87 ; (cons '(and (< score default)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
88 ; (or (= mark gnus-dormant-mark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
89 ; (= mark gnus-ticked-mark)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
90 ; (custom-face-lookup "pink" nil nil nil t nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
91 ; (cons '(or (= mark gnus-dormant-mark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
92 ; (= mark gnus-ticked-mark))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
93 ; (custom-face-lookup "pink" nil nil nil nil nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
94
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
95 ; (cons '(and (> score default) (= mark gnus-ancient-mark))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
96 ; (custom-face-lookup "SkyBlue" nil nil t nil nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
97 ; (cons '(and (< score default) (= mark gnus-ancient-mark))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
98 ; (custom-face-lookup "SkyBlue" nil nil nil t nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
99 ; (cons '(= mark gnus-ancient-mark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
100 ; (custom-face-lookup "SkyBlue" nil nil nil nil nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
101
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
102 ; (cons '(and (> score default) (= mark gnus-unread-mark))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
103 ; (custom-face-lookup "white" nil nil t nil nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
104 ; (cons '(and (< score default) (= mark gnus-unread-mark))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
105 ; (custom-face-lookup "white" nil nil nil t nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
106 ; (cons '(= mark gnus-unread-mark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
107 ; (custom-face-lookup "white" nil nil nil nil nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
108
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
109 ; (cons '(> score default) 'bold)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
110 ; (cons '(< score default) 'italic)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
111 ; (t
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
112 ; (list (cons '(= mark gnus-canceled-mark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
113 ; (custom-face-lookup "yellow" "black" nil nil nil nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
114 ; (cons '(and (> score default)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
115 ; (or (= mark gnus-dormant-mark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
116 ; (= mark gnus-ticked-mark)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
117 ; (custom-face-lookup "firebrick" nil nil t nil nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
118 ; (cons '(and (< score default)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
119 ; (or (= mark gnus-dormant-mark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
120 ; (= mark gnus-ticked-mark)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
121 ; (custom-face-lookup "firebrick" nil nil nil t nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
122 ; (cons '(or (= mark gnus-dormant-mark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
123 ; (= mark gnus-ticked-mark))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
124 ; (custom-face-lookup "firebrick" nil nil nil nil nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
125
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
126 ; (cons '(and (> score default) (= mark gnus-ancient-mark))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
127 ; (custom-face-lookup "RoyalBlue" nil nil t nil nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
128 ; (cons '(and (< score default) (= mark gnus-ancient-mark))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
129 ; (custom-face-lookup "RoyalBlue" nil nil nil t nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
130 ; (cons '(= mark gnus-ancient-mark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
131 ; (custom-face-lookup "RoyalBlue" nil nil nil nil nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
132
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
133 ; (cons '(and (> score default) (/= mark gnus-unread-mark))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
134 ; (custom-face-lookup "DarkGreen" nil nil t nil nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
135 ; (cons '(and (< score default) (/= mark gnus-unread-mark))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
136 ; (custom-face-lookup "DarkGreen" nil nil nil t nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
137 ; (cons '(/= mark gnus-unread-mark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
138 ; (custom-face-lookup "DarkGreen" nil nil nil nil nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
139
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
140 ; (cons '(> score default) 'bold)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
141 ; (cons '(< score default) 'italic))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
142 ; "*Alist of `(FORM . FACE)'.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
143 ;Summary lines are highlighted with the FACE for the first FORM which
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
144 ;evaluate to a non-nil value.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
145
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
146 ;Point will be at the beginning of the line when FORM is evaluated.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
147 ;The following can be used for convenience:
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
148
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
149 ;score: (gnus-summary-article-score)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
150 ;default: gnus-summary-default-score
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
151 ;below: gnus-summary-mark-below
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
152 ;mark: (gnus-summary-article-mark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
153
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
154 ;The latter can be used like this:
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
155 ; ((= mark gnus-replied-mark) . underline)")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
156
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
157 ;;; article highlights
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
158
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
159 ;see gnus-cus.el
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
160 ;(defvar gnus-header-face-alist
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
161 ; (cond ((not (eq gnus-display-type 'color))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
162 ; '(("" bold italic)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
163 ; ((eq gnus-background-mode 'dark)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
164 ; (list (list "From" nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
165 ; (custom-face-lookup "SkyBlue" nil nil t t nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
166 ; (list "Subject" nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
167 ; (custom-face-lookup "pink" nil nil t t nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
168 ; (list "Newsgroups:.*," nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
169 ; (custom-face-lookup "yellow" nil nil t t nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
170 ; (list ""
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
171 ; (custom-face-lookup "cyan" nil nil t nil nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
172 ; (custom-face-lookup "green" nil nil nil t nil))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
173 ; (t
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
174 ; (list (list "From" nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
175 ; (custom-face-lookup "RoyalBlue" nil nil t t nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
176 ; (list "Subject" nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
177 ; (custom-face-lookup "firebrick" nil nil t t nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
178 ; (list "Newsgroups:.*," nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
179 ; (custom-face-lookup "red" nil nil t t nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
180 ; (list ""
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
181 ; (custom-face-lookup "DarkGreen" nil nil t nil nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
182 ; (custom-face-lookup "DarkGreen" nil nil nil t nil)))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
183 ; "Alist of headers and faces used for highlighting them.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
184 ;The entries in the list has the form `(REGEXP NAME CONTENT)', where
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
185 ;REGEXP is a regular expression matching the beginning of the header,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
186 ;NAME is the face used for highlighting the header name and CONTENT is
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
187 ;the face used for highlighting the header content.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
188
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
189 ;The first non-nil NAME or CONTENT with a matching REGEXP in the list
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
190 ;will be used.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
191
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
192
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
193 ;see gnus-cus.el
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
194 ;(defvar gnus-make-foreground t
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
195 ; "Non nil means foreground color to highlight citations.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
196
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
197 ;see gnus-cus.el
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
198 ;(defvar gnus-article-button-face 'bold
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
199 ; "Face used for text buttons.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
200
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
201 ;see gnus-cus.el
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
202 ;(defvar gnus-article-mouse-face (if (boundp 'gnus-mouse-face)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
203 ; gnus-mouse-face
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
204 ; 'highlight)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
205 ; "Face used when the mouse is over the button.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
206
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
207 ;see gnus-cus.el
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
208 ;(defvar gnus-signature-face 'italic
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
209 ; "Face used for signature.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
210
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
211 (defvar gnus-button-url-regexp "\\b\\(s?https?\\|ftp\\|file\\|gopher\\|news\\|telnet\\|wais\\|mailto\\):\\(//[-a-zA-Z0-9_.]+:[0-9]*\\)?[-\\wa-zA-Z0-9_=!?#$@~`%&*+|\\/.,]*[-\\wa-zA-Z0-9_=#$@~`%&*+|\\/]"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
212 "*Regular expression that matches URLs.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
213
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
214 (defvar gnus-button-alist
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
215 `(("\\bin\\( +article\\)? +\\(<\\([^\n @<>]+@[^\n @<>]+\\)>\\)" 2
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
216 t gnus-button-message-id 3)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
217 ("\\(<?\\(url: ?\\)?news:\\([^>\n\t ]*\\)>?\\)" 1 t
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
218 gnus-button-message-id 3)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
219 ("\\(<URL: *\\)?mailto: *\\([^> \n\t]+\\)>?" 0 t gnus-button-reply 2)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
220 ;; This is how URLs _should_ be embedded in text...
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
221 ("<URL: *\\([^\n\r>]*\\)>" 0 t gnus-button-url 1)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
222 ;; Next regexp stolen from highlight-headers.el.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
223 ;; Modified by Vladimir Alexiev.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
224 (,gnus-button-url-regexp 0 t gnus-button-url 0))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
225 "Alist of regexps matching buttons in article bodies.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
226
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
227 Each entry has the form (REGEXP BUTTON FORM CALLBACK PAR...), where
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
228 REGEXP: is the string matching text around the button,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
229 BUTTON: is the number of the regexp grouping actually matching the button,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
230 FORM: is a lisp expression which must eval to true for the button to
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
231 be added,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
232 CALLBACK: is the function to call when the user push this button, and each
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
233 PAR: is a number of a regexp grouping whose text will be passed to CALLBACK.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
234
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
235 CALLBACK can also be a variable, in that case the value of that
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
236 variable it the real callback function.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
237
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
238 (defvar gnus-header-button-alist
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
239 `(("^\\(References\\|Message-I[Dd]\\):" "<[^>]+>"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
240 0 t gnus-button-message-id 0)
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
241 ("^\\(From\\|Reply-To\\):" ": *\\(.+\\)$" 1 t gnus-button-reply 1)
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
242 ("^\\(Cc\\|To\\):" "[^ \t\n<>,()\"]+@[^ \t\n<>,()\"]+"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
243 0 t gnus-button-mailto 0)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
244 ("^X-[Uu][Rr][Ll]:" ,gnus-button-url-regexp 0 t gnus-button-url 0)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
245 ("^[^:]+:" ,gnus-button-url-regexp 0 t gnus-button-url 0)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
246 ("^[^:]+:" "\\(<\\(url: \\)?news:\\([^>\n ]*\\)>\\)" 1 t
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
247 gnus-button-message-id 3))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
248 "Alist of headers and regexps to match buttons in article heads.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
249
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
250 This alist is very similar to `gnus-button-alist', except that each
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
251 alist has an additional HEADER element first in each entry:
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
252
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
253 \(HEADER REGEXP BUTTON FORM CALLBACK PAR)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
254
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
255 HEADER is a regexp to match a header. For a fuller explanation, see
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
256 `gnus-button-alist'.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
257
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
258 ;see gnus-cus.el
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
259 ;(eval-when-compile
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
260 ; (defvar browse-url-browser-function))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
261
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
262 ;;; Group mode highlighting.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
263
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
264 ;see gnus-cus.el
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
265 ;(defvar gnus-group-highlight nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
266 ; "Group lines are highlighted with the FACE for the first FORM which
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
267 ;evaluate to a non-nil value.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
268 ;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
269 ;Point will be at the beginning of the line when FORM is evaluated.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
270 ;Variables bound when these forms are evaluated include:
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
271 ;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
272 ;group: The group name.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
273 ;unread: The number of unread articles.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
274 ;method: The select method.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
275 ;mailp: Whether the select method is a mail method.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
276 ;level: The level of the group.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
277 ;score: The score of the group.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
278 ;ticked: The number of ticked articles in the group.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
279 ;")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
280
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
281
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
282 ;;; Internal variables.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
283
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
284 (defvar gnus-button-marker-list nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
285
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
286
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
287
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
288 (eval-and-compile
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
289 (autoload 'nnkiboze-generate-groups "nnkiboze")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
290 (autoload 'gnus-cite-parse-maybe "gnus-cite" nil t))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
291
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
292 ;;;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
293 ;;; gnus-menu
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
294 ;;;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
295
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
296 (defun gnus-visual-turn-off-edit-menu (type)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
297 (define-key (symbol-value (intern (format "gnus-%s-mode-map" type)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
298 [menu-bar edit] 'undefined))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
299
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
300 ;; Newsgroup buffer
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
301
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
302 (defun gnus-group-make-menu-bar ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
303 (gnus-visual-turn-off-edit-menu 'group)
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
304 (unless (boundp 'gnus-group-reading-menu)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
305
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
306 (easy-menu-define
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
307 gnus-group-reading-menu gnus-group-mode-map ""
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
308 '("Group"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
309 ["Read" gnus-group-read-group (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
310 ["Select" gnus-group-select-group (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
311 ["See old articles" (gnus-group-select-group 'all)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
312 :keys "C-u SPC" :active (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
313 ["Catch up" gnus-group-catchup-current (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
314 ["Catch up all articles" gnus-group-catchup-current-all
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
315 (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
316 ["Check for new articles" gnus-group-get-new-news-this-group
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
317 (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
318 ["Toggle subscription" gnus-group-unsubscribe-current-group
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
319 (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
320 ["Kill" gnus-group-kill-group (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
321 ["Yank" gnus-group-yank-group gnus-list-of-killed-groups]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
322 ["Describe" gnus-group-describe-group (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
323 ["Fetch FAQ" gnus-group-fetch-faq (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
324 ["Edit kill file" gnus-group-edit-local-kill
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
325 (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
326 ;; Actually one should check, if any of the marked groups gives t for
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
327 ;; (gnus-check-backend-function 'request-expire-articles ...)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
328 ["Expire articles" gnus-group-expire-articles
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
329 (or (and (gnus-group-group-name)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
330 (gnus-check-backend-function
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
331 'request-expire-articles
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
332 (gnus-group-group-name))) gnus-group-marked)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
333 ["Set group level" gnus-group-set-current-level
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
334 (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
335 ["Select quick" gnus-group-quick-select-group (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
336 ))
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
337
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
338 (easy-menu-define
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
339 gnus-group-group-menu gnus-group-mode-map ""
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
340 '("Groups"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
341 ("Listing"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
342 ["List unread subscribed groups" gnus-group-list-groups t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
343 ["List (un)subscribed groups" gnus-group-list-all-groups t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
344 ["List killed groups" gnus-group-list-killed gnus-killed-list]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
345 ["List zombie groups" gnus-group-list-zombies gnus-zombie-list]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
346 ["List level..." gnus-group-list-level t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
347 ["Describe all groups" gnus-group-describe-all-groups t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
348 ["Group apropos..." gnus-group-apropos t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
349 ["Group and description apropos..." gnus-group-description-apropos t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
350 ["List groups matching..." gnus-group-list-matching t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
351 ["List all groups matching..." gnus-group-list-all-matching t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
352 ["List active file" gnus-group-list-active t])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
353 ("Sort"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
354 ["Default sort" gnus-group-sort-groups
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
355 (or (not (boundp 'gnus-topic-mode)) (not gnus-topic-mode))]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
356 ["Sort by method" gnus-group-sort-groups-by-method
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
357 (or (not (boundp 'gnus-topic-mode)) (not gnus-topic-mode))]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
358 ["Sort by rank" gnus-group-sort-groups-by-rank
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
359 (or (not (boundp 'gnus-topic-mode)) (not gnus-topic-mode))]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
360 ["Sort by score" gnus-group-sort-groups-by-score
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
361 (or (not (boundp 'gnus-topic-mode)) (not gnus-topic-mode))]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
362 ["Sort by level" gnus-group-sort-groups-by-level
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
363 (or (not (boundp 'gnus-topic-mode)) (not gnus-topic-mode))]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
364 ["Sort by unread" gnus-group-sort-groups-by-unread
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
365 (or (not (boundp 'gnus-topic-mode)) (not gnus-topic-mode))]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
366 ["Sort by name" gnus-group-sort-groups-by-alphabet
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
367 (or (not (boundp 'gnus-topic-mode)) (not gnus-topic-mode))])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
368 ("Mark"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
369 ["Mark group" gnus-group-mark-group
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
370 (and (gnus-group-group-name)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
371 (not (memq (gnus-group-group-name) gnus-group-marked)))]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
372 ["Unmark group" gnus-group-unmark-group
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
373 (and (gnus-group-group-name)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
374 (memq (gnus-group-group-name) gnus-group-marked))]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
375 ["Unmark all" gnus-group-unmark-all-groups gnus-group-marked]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
376 ["Mark regexp..." gnus-group-mark-regexp t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
377 ["Mark region" gnus-group-mark-region t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
378 ["Mark buffer" gnus-group-mark-buffer t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
379 ["Execute command" gnus-group-universal-argument
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
380 (or gnus-group-marked (gnus-group-group-name))])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
381 ("Subscribe"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
382 ["Subscribe to a group" gnus-group-unsubscribe-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
383 ["Kill all newsgroups in region" gnus-group-kill-region t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
384 ["Kill all zombie groups" gnus-group-kill-all-zombies
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
385 gnus-zombie-list]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
386 ["Kill all groups on level..." gnus-group-kill-level t])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
387 ("Foreign groups"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
388 ["Make a foreign group" gnus-group-make-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
389 ["Add a directory group" gnus-group-make-directory-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
390 ["Add the help group" gnus-group-make-help-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
391 ["Add the archive group" gnus-group-make-archive-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
392 ["Make a doc group" gnus-group-make-doc-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
393 ["Make a kiboze group" gnus-group-make-kiboze-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
394 ["Make a virtual group" gnus-group-make-empty-virtual t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
395 ["Add a group to a virtual" gnus-group-add-to-virtual t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
396 ["Rename group" gnus-group-rename-group
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
397 (gnus-check-backend-function
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
398 'request-rename-group (gnus-group-group-name))]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
399 ["Delete group" gnus-group-delete-group
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
400 (gnus-check-backend-function
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
401 'request-delete-group (gnus-group-group-name))])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
402 ("Editing groups"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
403 ["Parameters" gnus-group-edit-group-parameters
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
404 (gnus-group-group-name)]
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
405 ["Select method" gnus-group-edit-group-method
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
406 (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
407 ["Info" gnus-group-edit-group (gnus-group-group-name)])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
408 ("Score file"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
409 ["Flush cache" gnus-score-flush-cache
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
410 (or gnus-score-cache gnus-short-name-score-file-cache)])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
411 ("Move"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
412 ["Next" gnus-group-next-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
413 ["Previous" gnus-group-prev-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
414 ["Next unread" gnus-group-next-unread-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
415 ["Previous unread" gnus-group-prev-unread-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
416 ["Next unread same level" gnus-group-next-unread-group-same-level t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
417 ["Previous unread same level"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
418 gnus-group-previous-unread-group-same-level t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
419 ["Jump to group" gnus-group-jump-to-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
420 ["First unread group" gnus-group-first-unread-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
421 ["Best unread group" gnus-group-best-unread-group t])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
422 ["Transpose" gnus-group-transpose-groups
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
423 (gnus-group-group-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
424 ["Read a directory as a group..." gnus-group-enter-directory t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
425 ))
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
426
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
427 (easy-menu-define
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
428 gnus-group-misc-menu gnus-group-mode-map ""
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
429 '("Misc"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
430 ["Send a bug report" gnus-bug t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
431 ["Send a mail" gnus-group-mail t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
432 ["Post an article..." gnus-group-post-news t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
433 ["Customize score file" gnus-score-customize t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
434 ["Check for new news" gnus-group-get-new-news t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
435 ["Activate all groups" gnus-activate-all-groups t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
436 ["Delete bogus groups" gnus-group-check-bogus-groups t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
437 ["Find new newsgroups" gnus-find-new-newsgroups t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
438 ["Restart Gnus" gnus-group-restart t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
439 ["Read init file" gnus-group-read-init-file t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
440 ["Browse foreign server" gnus-group-browse-foreign-server t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
441 ["Enter server buffer" gnus-group-enter-server-mode t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
442 ["Expire all expirable articles" gnus-group-expire-all-groups t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
443 ["Generate any kiboze groups" nnkiboze-generate-groups t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
444 ["Gnus version" gnus-version t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
445 ["Save .newsrc files" gnus-group-save-newsrc t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
446 ["Suspend Gnus" gnus-group-suspend t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
447 ["Clear dribble buffer" gnus-group-clear-dribble t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
448 ["Edit global kill file" gnus-group-edit-global-kill t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
449 ["Read manual" gnus-info-find-node t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
450 ["Toggle topics" gnus-topic-mode t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
451 ("SOUP"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
452 ["Pack replies" nnsoup-pack-replies (fboundp 'nnsoup-request-group)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
453 ["Send replies" gnus-soup-send-replies
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
454 (fboundp 'gnus-soup-pack-packet)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
455 ["Pack packet" gnus-soup-pack-packet (fboundp 'gnus-soup-pack-packet)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
456 ["Save areas" gnus-soup-save-areas (fboundp 'gnus-soup-pack-packet)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
457 ["Brew SOUP" gnus-soup-brew-soup (fboundp 'gnus-soup-pack-packet)])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
458 ["Exit from Gnus" gnus-group-exit t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
459 ["Exit without saving" gnus-group-quit t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
460 ))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
461
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
462 (run-hooks 'gnus-group-menu-hook)
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
463 ))
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
464
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
465 ;; Summary buffer
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
466 (defun gnus-summary-make-menu-bar ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
467 (gnus-visual-turn-off-edit-menu 'summary)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
468
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
469 (unless (boundp 'gnus-summary-misc-menu)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
470
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
471 (easy-menu-define
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
472 gnus-summary-kill-menu gnus-summary-mode-map ""
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
473 (cons
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
474 "Score"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
475 (nconc
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
476 (list
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
477 ["Enter score..." gnus-summary-score-entry t])
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
478 (gnus-visual-score-map 'increase)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
479 (gnus-visual-score-map 'lower)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
480 '(("Mark"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
481 ["Kill below" gnus-summary-kill-below t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
482 ["Mark above" gnus-summary-mark-above t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
483 ["Tick above" gnus-summary-tick-above t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
484 ["Clear above" gnus-summary-clear-above t])
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
485 ["Current score" gnus-summary-current-score t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
486 ["Set score" gnus-summary-set-score t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
487 ["Customize score file" gnus-score-customize t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
488 ["Switch current score file..." gnus-score-change-score-file t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
489 ["Set mark below..." gnus-score-set-mark-below t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
490 ["Set expunge below..." gnus-score-set-expunge-below t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
491 ["Edit current score file" gnus-score-edit-current-scores t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
492 ["Edit score file" gnus-score-edit-file t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
493 ["Trace score" gnus-score-find-trace t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
494 ["Rescore buffer" gnus-summary-rescore t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
495 ["Increase score..." gnus-summary-increase-score t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
496 ["Lower score..." gnus-summary-lower-score t]))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
497
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
498 '(("Default header"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
499 ["Ask" (gnus-score-set-default 'gnus-score-default-header nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
500 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
501 :selected (null gnus-score-default-header)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
502 ["From" (gnus-score-set-default 'gnus-score-default-header 'a)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
503 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
504 :selected (eq gnus-score-default-header 'a)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
505 ["Subject" (gnus-score-set-default 'gnus-score-default-header 's)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
506 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
507 :selected (eq gnus-score-default-header 's)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
508 ["Article body"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
509 (gnus-score-set-default 'gnus-score-default-header 'b)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
510 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
511 :selected (eq gnus-score-default-header 'b )]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
512 ["All headers"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
513 (gnus-score-set-default 'gnus-score-default-header 'h)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
514 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
515 :selected (eq gnus-score-default-header 'h )]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
516 ["Message-Id" (gnus-score-set-default 'gnus-score-default-header 'i)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
517 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
518 :selected (eq gnus-score-default-header 'i )]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
519 ["Thread" (gnus-score-set-default 'gnus-score-default-header 't)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
520 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
521 :selected (eq gnus-score-default-header 't )]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
522 ["Crossposting"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
523 (gnus-score-set-default 'gnus-score-default-header 'x)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
524 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
525 :selected (eq gnus-score-default-header 'x )]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
526 ["Lines" (gnus-score-set-default 'gnus-score-default-header 'l)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
527 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
528 :selected (eq gnus-score-default-header 'l )]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
529 ["Date" (gnus-score-set-default 'gnus-score-default-header 'd)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
530 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
531 :selected (eq gnus-score-default-header 'd )]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
532 ["Followups to author"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
533 (gnus-score-set-default 'gnus-score-default-header 'f)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
534 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
535 :selected (eq gnus-score-default-header 'f )])
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
536 ("Default type"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
537 ["Ask" (gnus-score-set-default 'gnus-score-default-type nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
538 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
539 :selected (null gnus-score-default-type)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
540 ;; The `:active' key is commented out in the following,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
541 ;; because the GNU Emacs hack to support radio buttons use
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
542 ;; active to indicate which button is selected.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
543 ["Substring" (gnus-score-set-default 'gnus-score-default-type 's)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
544 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
545 ;; :active (not (memq gnus-score-default-header '(l d)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
546 :selected (eq gnus-score-default-type 's)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
547 ["Regexp" (gnus-score-set-default 'gnus-score-default-type 'r)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
548 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
549 ;; :active (not (memq gnus-score-default-header '(l d)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
550 :selected (eq gnus-score-default-type 'r)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
551 ["Exact" (gnus-score-set-default 'gnus-score-default-type 'e)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
552 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
553 ;; :active (not (memq gnus-score-default-header '(l d)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
554 :selected (eq gnus-score-default-type 'e)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
555 ["Fuzzy" (gnus-score-set-default 'gnus-score-default-type 'f)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
556 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
557 ;; :active (not (memq gnus-score-default-header '(l d)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
558 :selected (eq gnus-score-default-type 'f)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
559 ["Before date" (gnus-score-set-default 'gnus-score-default-type 'b)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
560 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
561 ;; :active (eq (gnus-score-default-header 'd))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
562 :selected (eq gnus-score-default-type 'b)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
563 ["At date" (gnus-score-set-default 'gnus-score-default-type 'n)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
564 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
565 ;; :active (eq (gnus-score-default-header 'd))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
566 :selected (eq gnus-score-default-type 'n)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
567 ["After date" (gnus-score-set-default 'gnus-score-default-type 'a)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
568 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
569 ;; :active (eq (gnus-score-default-header 'd))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
570 :selected (eq gnus-score-default-type 'a)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
571 ["Less than number"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
572 (gnus-score-set-default 'gnus-score-default-type '<)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
573 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
574 ;; :active (eq (gnus-score-default-header 'l))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
575 :selected (eq gnus-score-default-type '<)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
576 ["Equal to number"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
577 (gnus-score-set-default 'gnus-score-default-type '=)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
578 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
579 ;; :active (eq (gnus-score-default-header 'l))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
580 :selected (eq gnus-score-default-type '=)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
581 ["Greater than number"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
582 (gnus-score-set-default 'gnus-score-default-type '>)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
583 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
584 ;; :active (eq (gnus-score-default-header 'l))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
585 :selected (eq gnus-score-default-type '>)])
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
586 ["Default fold" gnus-score-default-fold-toggle
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
587 :style toggle
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
588 :selected gnus-score-default-fold]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
589 ("Default duration"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
590 ["Ask" (gnus-score-set-default 'gnus-score-default-duration nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
591 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
592 :selected (null gnus-score-default-duration)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
593 ["Permanent"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
594 (gnus-score-set-default 'gnus-score-default-duration 'p)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
595 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
596 :selected (eq gnus-score-default-duration 'p)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
597 ["Temporary"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
598 (gnus-score-set-default 'gnus-score-default-duration 't)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
599 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
600 :selected (eq gnus-score-default-duration 't)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
601 ["Immediate"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
602 (gnus-score-set-default 'gnus-score-default-duration 'i)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
603 :style radio
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
604 :selected (eq gnus-score-default-duration 'i)]))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
605
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
606 (easy-menu-define
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
607 gnus-summary-article-menu gnus-summary-mode-map ""
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
608 '("Article"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
609 ("Hide"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
610 ["All" gnus-article-hide t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
611 ["Headers" gnus-article-hide-headers t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
612 ["Signature" gnus-article-hide-signature t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
613 ["Citation" gnus-article-hide-citation t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
614 ["PGP" gnus-article-hide-pgp t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
615 ["Boring headers" gnus-article-hide-boring-headers t])
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
616 ("Highlight"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
617 ["All" gnus-article-highlight t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
618 ["Headers" gnus-article-highlight-headers t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
619 ["Signature" gnus-article-highlight-signature t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
620 ["Citation" gnus-article-highlight-citation t])
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
621 ("Date"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
622 ["Local" gnus-article-date-local t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
623 ["UT" gnus-article-date-ut t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
624 ["Original" gnus-article-date-original t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
625 ["Lapsed" gnus-article-date-lapsed t])
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
626 ("Filter"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
627 ["Overstrike" gnus-article-treat-overstrike t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
628 ["Word wrap" gnus-article-fill-cited-article t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
629 ["CR" gnus-article-remove-cr t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
630 ["Trailing blank lines" gnus-article-remove-trailing-blank-lines t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
631 ["Show X-Face" gnus-article-display-x-face t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
632 ["Quoted-Printable" gnus-article-de-quoted-unreadable t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
633 ["Rot 13" gnus-summary-caesar-message t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
634 ["Add buttons" gnus-article-add-buttons t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
635 ["Add buttons to head" gnus-article-add-buttons-to-head t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
636 ["Stop page breaking" gnus-summary-stop-page-breaking t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
637 ["Toggle MIME" gnus-summary-toggle-mime t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
638 ["Verbose header" gnus-summary-verbose-headers t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
639 ["Toggle header" gnus-summary-toggle-header t])
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
640 ("Output"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
641 ["Save in default format" gnus-summary-save-article t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
642 ["Save in file" gnus-summary-save-article-file t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
643 ["Save in Unix mail format" gnus-summary-save-article-mail t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
644 ["Save in MH folder" gnus-summary-save-article-folder t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
645 ["Save in VM folder" gnus-summary-save-article-vm t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
646 ["Save in RMAIL mbox" gnus-summary-save-article-rmail t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
647 ["Save body in file" gnus-summary-save-article-body-file t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
648 ["Pipe through a filter" gnus-summary-pipe-output t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
649 ["Add to SOUP packet" gnus-soup-add-article t])
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
650 ("Backend"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
651 ["Respool article..." gnus-summary-respool-article t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
652 ["Move article..." gnus-summary-move-article
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
653 (gnus-check-backend-function
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
654 'request-move-article gnus-newsgroup-name)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
655 ["Copy article..." gnus-summary-copy-article t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
656 ["Crosspost article..." gnus-summary-crosspost-article
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
657 (gnus-check-backend-function
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
658 'request-replace-article gnus-newsgroup-name)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
659 ["Import file..." gnus-summary-import-article t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
660 ["Edit article" gnus-summary-edit-article
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
661 (not (gnus-group-read-only-p))]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
662 ["Delete article" gnus-summary-delete-article
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
663 (gnus-check-backend-function
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
664 'request-expire-articles gnus-newsgroup-name)]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
665 ["Query respool" gnus-summary-respool-query t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
666 ["Delete expirable articles" gnus-summary-expire-articles-now
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
667 (gnus-check-backend-function
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
668 'request-expire-articles gnus-newsgroup-name)])
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
669 ("Extract"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
670 ["Uudecode" gnus-uu-decode-uu t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
671 ["Uudecode and save" gnus-uu-decode-uu-and-save t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
672 ["Unshar" gnus-uu-decode-unshar t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
673 ["Unshar and save" gnus-uu-decode-unshar-and-save t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
674 ["Save" gnus-uu-decode-save t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
675 ["Binhex" gnus-uu-decode-binhex t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
676 ["Postscript" gnus-uu-decode-postscript t])
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
677 ["Enter digest buffer" gnus-summary-enter-digest-group t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
678 ["Isearch article..." gnus-summary-isearch-article t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
679 ["Search articles forward..." gnus-summary-search-article-forward t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
680 ["Search articles backward..." gnus-summary-search-article-backward t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
681 ["Beginning of the article" gnus-summary-beginning-of-article t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
682 ["End of the article" gnus-summary-end-of-article t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
683 ["Fetch parent of article" gnus-summary-refer-parent-article t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
684 ["Fetch referenced articles" gnus-summary-refer-references t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
685 ["Fetch article with id..." gnus-summary-refer-article t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
686 ["Redisplay" gnus-summary-show-article t]))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
687
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
688 (easy-menu-define
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
689 gnus-summary-thread-menu gnus-summary-mode-map ""
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
690 '("Threads"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
691 ["Toggle threading" gnus-summary-toggle-threads t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
692 ["Hide threads" gnus-summary-hide-all-threads t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
693 ["Show threads" gnus-summary-show-all-threads t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
694 ["Hide thread" gnus-summary-hide-thread t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
695 ["Show thread" gnus-summary-show-thread t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
696 ["Go to next thread" gnus-summary-next-thread t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
697 ["Go to previous thread" gnus-summary-prev-thread t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
698 ["Go down thread" gnus-summary-down-thread t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
699 ["Go up thread" gnus-summary-up-thread t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
700 ["Top of thread" gnus-summary-top-thread t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
701 ["Mark thread as read" gnus-summary-kill-thread t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
702 ["Lower thread score" gnus-summary-lower-thread t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
703 ["Raise thread score" gnus-summary-raise-thread t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
704 ["Rethread current" gnus-summary-rethread-current t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
705 ))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
706
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
707 (easy-menu-define
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
708 gnus-summary-post-menu gnus-summary-mode-map ""
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
709 '("Post"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
710 ["Post an article" gnus-summary-post-news t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
711 ["Followup" gnus-summary-followup t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
712 ["Followup and yank" gnus-summary-followup-with-original t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
713 ["Supersede article" gnus-summary-supersede-article t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
714 ["Cancel article" gnus-summary-cancel-article t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
715 ["Reply" gnus-summary-reply t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
716 ["Reply and yank" gnus-summary-reply-with-original t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
717 ["Mail forward" gnus-summary-mail-forward t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
718 ["Post forward" gnus-summary-post-forward t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
719 ["Digest and mail" gnus-uu-digest-mail-forward t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
720 ["Digest and post" gnus-uu-digest-post-forward t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
721 ["Resend message" gnus-summary-resend-message t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
722 ["Send bounced mail" gnus-summary-resend-bounced-mail t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
723 ["Send a mail" gnus-summary-mail-other-window t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
724 ["Uuencode and post" gnus-uu-post-news t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
725 ;;("Draft"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
726 ;;["Send" gnus-summary-send-draft t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
727 ;;["Send bounced" gnus-resend-bounced-mail t])
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
728 ))
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
729
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
730 (easy-menu-define
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
731 gnus-summary-misc-menu gnus-summary-mode-map ""
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
732 '("Misc"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
733 ("Mark"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
734 ("Read"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
735 ["Mark as read" gnus-summary-mark-as-read-forward t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
736 ["Mark same subject and select"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
737 gnus-summary-kill-same-subject-and-select t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
738 ["Mark same subject" gnus-summary-kill-same-subject t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
739 ["Catchup" gnus-summary-catchup t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
740 ["Catchup all" gnus-summary-catchup-all t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
741 ["Catchup to here" gnus-summary-catchup-to-here t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
742 ["Catchup region" gnus-summary-mark-region-as-read t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
743 ["Mark excluded" gnus-summary-limit-mark-excluded-as-read t])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
744 ("Various"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
745 ["Tick" gnus-summary-tick-article-forward t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
746 ["Mark as dormant" gnus-summary-mark-as-dormant t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
747 ["Remove marks" gnus-summary-clear-mark-forward t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
748 ["Set expirable mark" gnus-summary-mark-as-expirable t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
749 ["Set bookmark" gnus-summary-set-bookmark t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
750 ["Remove bookmark" gnus-summary-remove-bookmark t])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
751 ("Limit"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
752 ["Marks..." gnus-summary-limit-to-marks t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
753 ["Subject..." gnus-summary-limit-to-subject t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
754 ["Author..." gnus-summary-limit-to-author t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
755 ["Score" gnus-summary-limit-to-score t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
756 ["Unread" gnus-summary-limit-to-unread t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
757 ["Non-dormant" gnus-summary-limit-exclude-dormant t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
758 ["Articles" gnus-summary-limit-to-articles t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
759 ["Pop limit" gnus-summary-pop-limit t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
760 ["Show dormant" gnus-summary-limit-include-dormant t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
761 ["Hide childless dormant"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
762 gnus-summary-limit-exclude-childless-dormant t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
763 ;;["Hide thread" gnus-summary-limit-exclude-thread t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
764 ["Show expunged" gnus-summary-show-all-expunged t])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
765 ("Process mark"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
766 ["Set mark" gnus-summary-mark-as-processable t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
767 ["Remove mark" gnus-summary-unmark-as-processable t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
768 ["Remove all marks" gnus-summary-unmark-all-processable t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
769 ["Mark above" gnus-uu-mark-over t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
770 ["Mark series" gnus-uu-mark-series t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
771 ["Mark region" gnus-uu-mark-region t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
772 ["Mark by regexp..." gnus-uu-mark-by-regexp t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
773 ["Mark all" gnus-uu-mark-all t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
774 ["Mark buffer" gnus-uu-mark-buffer t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
775 ["Mark sparse" gnus-uu-mark-sparse t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
776 ["Mark thread" gnus-uu-mark-thread t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
777 ["Unmark thread" gnus-uu-unmark-thread t]))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
778 ("Scroll article"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
779 ["Page forward" gnus-summary-next-page t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
780 ["Page backward" gnus-summary-prev-page t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
781 ["Line forward" gnus-summary-scroll-up t])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
782 ("Move"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
783 ["Next unread article" gnus-summary-next-unread-article t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
784 ["Previous unread article" gnus-summary-prev-unread-article t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
785 ["Next article" gnus-summary-next-article t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
786 ["Previous article" gnus-summary-prev-article t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
787 ["Next unread subject" gnus-summary-next-unread-subject t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
788 ["Previous unread subject" gnus-summary-prev-unread-subject t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
789 ["Next article same subject" gnus-summary-next-same-subject t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
790 ["Previous article same subject" gnus-summary-prev-same-subject t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
791 ["First unread article" gnus-summary-first-unread-article t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
792 ["Best unread article" gnus-summary-best-unread-article t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
793 ["Go to subject number..." gnus-summary-goto-subject t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
794 ["Go to article number..." gnus-summary-goto-article t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
795 ["Go to the last article" gnus-summary-goto-last-article t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
796 ["Pop article off history" gnus-summary-pop-article t])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
797 ("Sort"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
798 ["Sort by number" gnus-summary-sort-by-number t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
799 ["Sort by author" gnus-summary-sort-by-author t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
800 ["Sort by subject" gnus-summary-sort-by-subject t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
801 ["Sort by date" gnus-summary-sort-by-date t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
802 ["Sort by score" gnus-summary-sort-by-score t])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
803 ("Help"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
804 ["Fetch group FAQ" gnus-summary-fetch-faq t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
805 ["Describe group" gnus-summary-describe-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
806 ["Read manual" gnus-info-find-node t])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
807 ("Cache"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
808 ["Enter article" gnus-cache-enter-article t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
809 ["Remove article" gnus-cache-remove-article t])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
810 ("Modes"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
811 ["Pick and read" gnus-pick-mode t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
812 ["Binary" gnus-binary-mode t])
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
813 ["Filter articles..." gnus-summary-execute-command t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
814 ["Run command on subjects..." gnus-summary-universal-argument t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
815 ["Toggle line truncation" gnus-summary-toggle-truncation t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
816 ["Expand window" gnus-summary-expand-window t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
817 ["Expire expirable articles" gnus-summary-expire-articles
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
818 (gnus-check-backend-function
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
819 'request-expire-articles gnus-newsgroup-name)]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
820 ["Edit local kill file" gnus-summary-edit-local-kill t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
821 ["Edit main kill file" gnus-summary-edit-global-kill t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
822 ("Exit"
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
823 ["Catchup and exit" gnus-summary-catchup-and-exit t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
824 ["Catchup all and exit" gnus-summary-catchup-and-exit t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
825 ["Catchup and goto next" gnus-summary-catchup-and-goto-next-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
826 ["Exit group" gnus-summary-exit t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
827 ["Exit group without updating" gnus-summary-exit-no-update t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
828 ["Exit and goto next group" gnus-summary-next-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
829 ["Exit and goto prev group" gnus-summary-prev-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
830 ["Reselect group" gnus-summary-reselect-current-group t]
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
831 ["Rescan group" gnus-summary-rescan-group t])))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
832
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
833 (run-hooks 'gnus-summary-menu-hook)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
834 ))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
835
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
836 (defun gnus-score-set-default (var value)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
837 "A version of set that updates the GNU Emacs menu-bar."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
838 (set var value)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
839 ;; It is the message that forces the active status to be updated.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
840 (message ""))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
841
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
842 (defun gnus-visual-score-map (type)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
843 (if t
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
844 nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
845 (let ((headers '(("author" "from" string)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
846 ("subject" "subject" string)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
847 ("article body" "body" string)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
848 ("article head" "head" string)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
849 ("xref" "xref" string)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
850 ("lines" "lines" number)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
851 ("followups to author" "followup" string)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
852 (types '((number ("less than" <)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
853 ("greater than" >)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
854 ("equal" =))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
855 (string ("substring" s)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
856 ("exact string" e)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
857 ("fuzzy string" f)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
858 ("regexp" r))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
859 (perms '(("temporary" (current-time-string))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
860 ("permanent" nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
861 ("immediate" now)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
862 header)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
863 (list
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
864 (apply
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
865 'nconc
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
866 (list
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
867 (if (eq type 'lower)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
868 "Lower score"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
869 "Increase score"))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
870 (let (outh)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
871 (while headers
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
872 (setq header (car headers))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
873 (setq outh
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
874 (cons
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
875 (apply
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
876 'nconc
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
877 (list (car header))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
878 (let ((ts (cdr (assoc (nth 2 header) types)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
879 outt)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
880 (while ts
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
881 (setq outt
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
882 (cons
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
883 (apply
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
884 'nconc
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
885 (list (caar ts))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
886 (let ((ps perms)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
887 outp)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
888 (while ps
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
889 (setq outp
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
890 (cons
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
891 (vector
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
892 (caar ps)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
893 (list
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
894 'gnus-summary-score-entry
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
895 (nth 1 header)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
896 (if (or (string= (nth 1 header)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
897 "head")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
898 (string= (nth 1 header)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
899 "body"))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
900 ""
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
901 (list 'gnus-summary-header
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
902 (nth 1 header)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
903 (list 'quote (nth 1 (car ts)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
904 (list 'gnus-score-default nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
905 (nth 1 (car ps))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
906 t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
907 t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
908 outp))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
909 (setq ps (cdr ps)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
910 (list (nreverse outp))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
911 outt))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
912 (setq ts (cdr ts)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
913 (list (nreverse outt))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
914 outh))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
915 (setq headers (cdr headers)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
916 (list (nreverse outh))))))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
917
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
918 ;; Article buffer
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
919 (defun gnus-article-make-menu-bar ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
920 (gnus-visual-turn-off-edit-menu 'summary)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
921 (or
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
922 (boundp 'gnus-article-article-menu)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
923 (progn
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
924 (easy-menu-define
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
925 gnus-article-article-menu gnus-article-mode-map ""
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
926 '("Article"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
927 ["Scroll forwards" gnus-article-goto-next-page t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
928 ["Scroll backwards" gnus-article-goto-prev-page t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
929 ["Show summary" gnus-article-show-summary t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
930 ["Fetch Message-ID at point" gnus-article-refer-article t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
931 ["Mail to address at point" gnus-article-mail t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
932 ))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
933
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
934 (easy-menu-define
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
935 gnus-article-treatment-menu gnus-article-mode-map ""
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
936 '("Treatment"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
937 ["Hide headers" gnus-article-hide-headers t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
938 ["Hide signature" gnus-article-hide-signature t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
939 ["Hide citation" gnus-article-hide-citation t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
940 ["Treat overstrike" gnus-article-treat-overstrike t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
941 ["Remove carriage return" gnus-article-remove-cr t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
942 ["Remove quoted-unreadable" gnus-article-de-quoted-unreadable t]
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
943 ))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
944 (run-hooks 'gnus-article-menu-hook))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
945
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
946 ;;;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
947 ;;; summary highlights
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
948 ;;;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
949
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
950 (defun gnus-highlight-selected-summary ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
951 ;; Added by Per Abrahamsen <amanda@iesd.auc.dk>.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
952 ;; Highlight selected article in summary buffer
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
953 (if gnus-summary-selected-face
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
954 (save-excursion
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
955 (let* ((beg (progn (beginning-of-line) (point)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
956 (end (progn (end-of-line) (point)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
957 ;; Fix by Mike Dugan <dugan@bucrf16.bu.edu>.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
958 (from (if (get-text-property beg gnus-mouse-face-prop)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
959 beg
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
960 (1+ (or (next-single-property-change
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
961 beg gnus-mouse-face-prop nil end)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
962 beg))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
963 (to (1- (or (next-single-property-change
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
964 from gnus-mouse-face-prop nil end)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
965 end))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
966 ;; If no mouse-face prop on line (e.g. xemacs) we
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
967 ;; will have to = from = end, so we highlight the
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
968 ;; entire line instead.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
969 (if (= (+ to 2) from)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
970 (progn
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
971 (setq from beg)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
972 (setq to end)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
973 (if gnus-newsgroup-selected-overlay
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
974 (gnus-move-overlay gnus-newsgroup-selected-overlay
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
975 from to (current-buffer))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
976 (setq gnus-newsgroup-selected-overlay (gnus-make-overlay from to))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
977 (gnus-overlay-put gnus-newsgroup-selected-overlay 'face
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
978 gnus-summary-selected-face))))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
979
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
980 ;; New implementation by Christian Limpach <Christian.Limpach@nice.ch>.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
981 (defun gnus-summary-highlight-line ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
982 "Highlight current line according to `gnus-summary-highlight'."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
983 (let* ((list gnus-summary-highlight)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
984 (p (point))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
985 (end (progn (end-of-line) (point)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
986 ;; now find out where the line starts and leave point there.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
987 (beg (progn (beginning-of-line) (point)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
988 (article (gnus-summary-article-number))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
989 (score (or (cdr (assq (or article gnus-current-article)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
990 gnus-newsgroup-scored))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
991 gnus-summary-default-score 0))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
992 (mark (or (gnus-summary-article-mark) gnus-unread-mark))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
993 (inhibit-read-only t))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
994 ;; Eval the cars of the lists until we find a match.
2
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
995 (let ((default gnus-summary-default-score))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
996 (while (and list
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
997 (not (eval (caar list))))
ac2d302a0011 Import from CVS: tag r19-15b2
cvs
parents: 0
diff changeset
998 (setq list (cdr list))))
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
999 (let ((face (cdar list)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1000 (unless (eq face (get-text-property beg 'face))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1001 (gnus-put-text-property
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1002 beg end 'face
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1003 (setq face (if (boundp face) (symbol-value face) face)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1004 (when gnus-summary-highlight-line-function
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1005 (funcall gnus-summary-highlight-line-function article face))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1006 (goto-char p)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1007
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1008 (defun gnus-group-highlight-line ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1009 "Highlight the current line according to `gnus-group-highlight'."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1010 (let* ((list gnus-group-highlight)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1011 (p (point))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1012 (end (progn (end-of-line) (point)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1013 ;; now find out where the line starts and leave point there.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1014 (beg (progn (beginning-of-line) (point)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1015 (group (gnus-group-group-name))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1016 (entry (gnus-group-entry group))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1017 (unread (if (numberp (car entry)) (car entry) 0))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1018 (info (nth 2 entry))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1019 (method (gnus-server-get-method group (gnus-info-method info)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1020 (marked (gnus-info-marks info))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1021 (mailp (memq 'mail (assoc (symbol-name
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1022 (car (or method gnus-select-method)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1023 gnus-valid-select-methods)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1024 (level (or (gnus-info-level info) 9))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1025 (score (or (gnus-info-score info) 0))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1026 (ticked (gnus-range-length (cdr (assq 'tick marked))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1027 (inhibit-read-only t))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1028 ;; Eval the cars of the lists until we find a match.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1029 (while (and list
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1030 (not (eval (caar list))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1031 (setq list (cdr list)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1032 (let ((face (cdar list)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1033 (unless (eq face (get-text-property beg 'face))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1034 (gnus-put-text-property
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1035 beg end 'face
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1036 (setq face (if (boundp face) (symbol-value face) face)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1037 (gnus-extent-start-open beg)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1038 (goto-char p)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1039
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1040 ;;;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1041 ;;; gnus-carpal
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1042 ;;;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1043
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1044 (defvar gnus-carpal-group-buffer-buttons
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1045 '(("next" . gnus-group-next-unread-group)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1046 ("prev" . gnus-group-prev-unread-group)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1047 ("read" . gnus-group-read-group)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1048 ("select" . gnus-group-select-group)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1049 ("catch-up" . gnus-group-catchup-current)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1050 ("new-news" . gnus-group-get-new-news-this-group)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1051 ("toggle-sub" . gnus-group-unsubscribe-current-group)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1052 ("subscribe" . gnus-group-unsubscribe-group)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1053 ("kill" . gnus-group-kill-group)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1054 ("yank" . gnus-group-yank-group)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1055 ("describe" . gnus-group-describe-group)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1056 "list"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1057 ("subscribed" . gnus-group-list-groups)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1058 ("all" . gnus-group-list-all-groups)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1059 ("killed" . gnus-group-list-killed)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1060 ("zombies" . gnus-group-list-zombies)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1061 ("matching" . gnus-group-list-matching)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1062 ("post" . gnus-group-post-news)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1063 ("mail" . gnus-group-mail)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1064 ("rescan" . gnus-group-get-new-news)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1065 ("browse-foreign" . gnus-group-browse-foreign)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1066 ("exit" . gnus-group-exit)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1067
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1068 (defvar gnus-carpal-summary-buffer-buttons
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1069 '("mark"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1070 ("read" . gnus-summary-mark-as-read-forward)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1071 ("tick" . gnus-summary-tick-article-forward)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1072 ("clear" . gnus-summary-clear-mark-forward)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1073 ("expirable" . gnus-summary-mark-as-expirable)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1074 "move"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1075 ("scroll" . gnus-summary-next-page)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1076 ("next-unread" . gnus-summary-next-unread-article)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1077 ("prev-unread" . gnus-summary-prev-unread-article)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1078 ("first" . gnus-summary-first-unread-article)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1079 ("best" . gnus-summary-best-unread-article)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1080 "article"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1081 ("headers" . gnus-summary-toggle-header)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1082 ("uudecode" . gnus-uu-decode-uu)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1083 ("enter-digest" . gnus-summary-enter-digest-group)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1084 ("fetch-parent" . gnus-summary-refer-parent-article)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1085 "mail"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1086 ("move" . gnus-summary-move-article)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1087 ("copy" . gnus-summary-copy-article)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1088 ("respool" . gnus-summary-respool-article)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1089 "threads"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1090 ("lower" . gnus-summary-lower-thread)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1091 ("kill" . gnus-summary-kill-thread)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1092 "post"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1093 ("post" . gnus-summary-post-news)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1094 ("mail" . gnus-summary-mail)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1095 ("followup" . gnus-summary-followup-with-original)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1096 ("reply" . gnus-summary-reply-with-original)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1097 ("cancel" . gnus-summary-cancel-article)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1098 "misc"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1099 ("exit" . gnus-summary-exit)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1100 ("fed-up" . gnus-summary-catchup-and-goto-next-group)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1101
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1102 (defvar gnus-carpal-server-buffer-buttons
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1103 '(("add" . gnus-server-add-server)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1104 ("browse" . gnus-server-browse-server)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1105 ("list" . gnus-server-list-servers)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1106 ("kill" . gnus-server-kill-server)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1107 ("yank" . gnus-server-yank-server)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1108 ("copy" . gnus-server-copy-server)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1109 ("exit" . gnus-server-exit)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1110
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1111 (defvar gnus-carpal-browse-buffer-buttons
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1112 '(("subscribe" . gnus-browse-unsubscribe-current-group)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1113 ("exit" . gnus-browse-exit)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1114
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1115 (defvar gnus-carpal-group-buffer "*Carpal Group*")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1116 (defvar gnus-carpal-summary-buffer "*Carpal Summary*")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1117 (defvar gnus-carpal-server-buffer "*Carpal Server*")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1118 (defvar gnus-carpal-browse-buffer "*Carpal Browse*")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1119
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1120 (defvar gnus-carpal-attached-buffer nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1121
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1122 (defvar gnus-carpal-mode-hook nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1123 "*Hook run in carpal mode buffers.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1124
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1125 (defvar gnus-carpal-button-face 'bold
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1126 "*Face used on carpal buttons.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1127
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1128 (defvar gnus-carpal-header-face 'bold-italic
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1129 "*Face used on carpal buffer headers.")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1130
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1131 (defvar gnus-carpal-mode-map nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1132 (put 'gnus-carpal-mode 'mode-class 'special)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1133
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1134 (if gnus-carpal-mode-map
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1135 nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1136 (setq gnus-carpal-mode-map (make-keymap))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1137 (suppress-keymap gnus-carpal-mode-map)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1138 (define-key gnus-carpal-mode-map " " 'gnus-carpal-select)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1139 (define-key gnus-carpal-mode-map "\r" 'gnus-carpal-select)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1140 (define-key gnus-carpal-mode-map gnus-mouse-2 'gnus-carpal-mouse-select))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1141
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1142 (defun gnus-carpal-mode ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1143 "Major mode for clicking buttons.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1144
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1145 All normal editing commands are switched off.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1146 \\<gnus-carpal-mode-map>
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1147 The following commands are available:
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1148
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1149 \\{gnus-carpal-mode-map}"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1150 (interactive)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1151 (kill-all-local-variables)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1152 (setq mode-line-modified "-- ")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1153 (setq major-mode 'gnus-carpal-mode)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1154 (setq mode-name "Gnus Carpal")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1155 (setq mode-line-process nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1156 (use-local-map gnus-carpal-mode-map)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1157 (buffer-disable-undo (current-buffer))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1158 (setq buffer-read-only t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1159 (make-local-variable 'gnus-carpal-attached-buffer)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1160 (run-hooks 'gnus-carpal-mode-hook))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1161
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1162 (defun gnus-carpal-setup-buffer (type)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1163 (let ((buffer (symbol-value (intern (format "gnus-carpal-%s-buffer" type)))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1164 (if (get-buffer buffer)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1165 ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1166 (save-excursion
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1167 (set-buffer (get-buffer-create buffer))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1168 (gnus-carpal-mode)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1169 (setq gnus-carpal-attached-buffer
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1170 (intern (format "gnus-%s-buffer" type)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1171 (gnus-add-current-to-buffer-list)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1172 (let ((buttons (symbol-value
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1173 (intern (format "gnus-carpal-%s-buffer-buttons"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1174 type))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1175 (buffer-read-only nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1176 button)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1177 (while buttons
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1178 (setq button (car buttons)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1179 buttons (cdr buttons))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1180 (if (stringp button)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1181 (gnus-set-text-properties
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1182 (point)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1183 (prog2 (insert button) (point) (insert " "))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1184 (list 'face gnus-carpal-header-face))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1185 (gnus-set-text-properties
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1186 (point)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1187 (prog2 (insert (car button)) (point) (insert " "))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1188 (list 'gnus-callback (cdr button)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1189 'face gnus-carpal-button-face
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1190 gnus-mouse-face-prop 'highlight))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1191 (let ((fill-column (- (window-width) 2)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1192 (fill-region (point-min) (point-max)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1193 (set-window-point (get-buffer-window (current-buffer))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1194 (point-min)))))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1195
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1196 (defun gnus-carpal-select ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1197 "Select the button under point."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1198 (interactive)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1199 (let ((func (get-text-property (point) 'gnus-callback)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1200 (if (null func)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1201 ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1202 (pop-to-buffer (symbol-value gnus-carpal-attached-buffer))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1203 (call-interactively func))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1204
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1205 (defun gnus-carpal-mouse-select (event)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1206 "Select the button under the mouse pointer."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1207 (interactive "e")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1208 (mouse-set-point event)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1209 (gnus-carpal-select))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1210
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1211 ;;;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1212 ;;; article highlights
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1213 ;;;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1214
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1215 ;; Written by Per Abrahamsen <abraham@iesd.auc.dk>.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1216
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1217 ;;; Internal Variables:
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1218
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1219 (defvar gnus-button-regexp nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1220 ;; Regexp matching any of the regexps from `gnus-button-alist'.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1221
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1222 (defvar gnus-button-last nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1223 ;; The value of `gnus-button-alist' when `gnus-button-regexp' was build.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1224
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1225 ;;; Commands:
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1226
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1227 (defun gnus-article-push-button (event)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1228 "Check text under the mouse pointer for a callback function.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1229 If the text under the mouse pointer has a `gnus-callback' property,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1230 call it with the value of the `gnus-data' text property."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1231 (interactive "e")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1232 (set-buffer (window-buffer (posn-window (event-start event))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1233 (let* ((pos (posn-point (event-start event)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1234 (data (get-text-property pos 'gnus-data))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1235 (fun (get-text-property pos 'gnus-callback)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1236 (if fun (funcall fun data))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1237
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1238 (defun gnus-article-press-button ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1239 "Check text at point for a callback function.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1240 If the text at point has a `gnus-callback' property,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1241 call it with the value of the `gnus-data' text property."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1242 (interactive)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1243 (let* ((data (get-text-property (point) 'gnus-data))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1244 (fun (get-text-property (point) 'gnus-callback)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1245 (if fun (funcall fun data))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1246
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1247 (defun gnus-article-prev-button (n)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1248 "Move point to N buttons backward.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1249 If N is negative, move forward instead."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1250 (interactive "p")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1251 (gnus-article-next-button (- n)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1252
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1253 (defun gnus-article-next-button (n)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1254 "Move point to N buttons forward.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1255 If N is negative, move backward instead."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1256 (interactive "p")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1257 (let ((function (if (< n 0) 'previous-single-property-change
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1258 'next-single-property-change))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1259 (inhibit-point-motion-hooks t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1260 (backward (< n 0))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1261 (limit (if (< n 0) (point-min) (point-max))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1262 (setq n (abs n))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1263 (while (and (not (= limit (point)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1264 (> n 0))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1265 ;; Skip past the current button.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1266 (when (get-text-property (point) 'gnus-callback)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1267 (goto-char (funcall function (point) 'gnus-callback nil limit)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1268 ;; Go to the next (or previous) button.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1269 (gnus-goto-char (funcall function (point) 'gnus-callback nil limit))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1270 ;; Put point at the start of the button.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1271 (when (and backward (not (get-text-property (point) 'gnus-callback)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1272 (goto-char (funcall function (point) 'gnus-callback nil limit)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1273 ;; Skip past intangible buttons.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1274 (when (get-text-property (point) 'intangible)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1275 (incf n))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1276 (decf n))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1277 (unless (zerop n)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1278 (gnus-message 5 "No more buttons"))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1279 n))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1280
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1281 (defun gnus-article-highlight (&optional force)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1282 "Highlight current article.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1283 This function calls `gnus-article-highlight-headers',
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1284 `gnus-article-highlight-citation',
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1285 `gnus-article-highlight-signature', and `gnus-article-add-buttons' to
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1286 do the highlighting. See the documentation for those functions."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1287 (interactive (list 'force))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1288 (gnus-article-highlight-headers)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1289 (gnus-article-highlight-citation force)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1290 (gnus-article-highlight-signature)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1291 (gnus-article-add-buttons force)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1292 (gnus-article-add-buttons-to-head))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1293
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1294 (defun gnus-article-highlight-some (&optional force)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1295 "Highlight current article.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1296 This function calls `gnus-article-highlight-headers',
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1297 `gnus-article-highlight-signature', and `gnus-article-add-buttons' to
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1298 do the highlighting. See the documentation for those functions."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1299 (interactive (list 'force))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1300 (gnus-article-highlight-headers)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1301 (gnus-article-highlight-signature)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1302 (gnus-article-add-buttons))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1303
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1304 (defun gnus-article-highlight-headers ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1305 "Highlight article headers as specified by `gnus-header-face-alist'."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1306 (interactive)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1307 (save-excursion
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1308 (set-buffer gnus-article-buffer)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1309 (save-restriction
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1310 (let ((alist gnus-header-face-alist)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1311 (buffer-read-only nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1312 (case-fold-search t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1313 (inhibit-point-motion-hooks t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1314 entry regexp header-face field-face from hpoints fpoints)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1315 (goto-char (point-min))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1316 (when (search-forward "\n\n" nil t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1317 (narrow-to-region (1- (point)) (point-min))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1318 (while (setq entry (pop alist))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1319 (goto-char (point-min))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1320 (setq regexp (concat "^\\("
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1321 (if (string-equal "" (nth 0 entry))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1322 "[^\t ]"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1323 (nth 0 entry))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1324 "\\)")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1325 header-face (nth 1 entry)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1326 field-face (nth 2 entry))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1327 (while (and (re-search-forward regexp nil t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1328 (not (eobp)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1329 (beginning-of-line)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1330 (setq from (point))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1331 (or (search-forward ":" nil t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1332 (forward-char 1))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1333 (when (and header-face
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1334 (not (memq (point) hpoints)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1335 (push (point) hpoints)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1336 (gnus-put-text-property from (point) 'face header-face))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1337 (when (and field-face
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1338 (not (memq (setq from (point)) fpoints)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1339 (push from fpoints)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1340 (if (re-search-forward "^[^ \t]" nil t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1341 (forward-char -2)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1342 (goto-char (point-max)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1343 (gnus-put-text-property from (point) 'face field-face)))))))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1344
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1345 (defun gnus-article-highlight-signature ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1346 "Highlight the signature in an article.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1347 It does this by highlighting everything after
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1348 `gnus-signature-separator' using `gnus-signature-face'."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1349 (interactive)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1350 (save-excursion
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1351 (set-buffer gnus-article-buffer)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1352 (let ((buffer-read-only nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1353 (inhibit-point-motion-hooks t))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1354 (save-restriction
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1355 (when (and gnus-signature-face
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1356 (gnus-narrow-to-signature))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1357 (gnus-overlay-put (gnus-make-overlay (point-min) (point-max))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1358 'face gnus-signature-face)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1359 (widen)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1360 (re-search-backward gnus-signature-separator nil t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1361 (let ((start (match-beginning 0))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1362 (end (set-marker (make-marker) (1+ (match-end 0)))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1363 (gnus-article-add-button start (1- end) 'gnus-signature-toggle
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1364 end)))))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1365
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1366 (defun gnus-article-add-buttons (&optional force)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1367 "Find external references in the article and make buttons of them.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1368 \"External references\" are things like Message-IDs and URLs, as
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1369 specified by `gnus-button-alist'."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1370 (interactive (list 'force))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1371 (save-excursion
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1372 (set-buffer gnus-article-buffer)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1373 ;; Remove all old markers.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1374 (while gnus-button-marker-list
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1375 (set-marker (pop gnus-button-marker-list) nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1376 (let ((buffer-read-only nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1377 (inhibit-point-motion-hooks t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1378 (case-fold-search t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1379 (alist gnus-button-alist)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1380 beg entry regexp)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1381 (goto-char (point-min))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1382 ;; We skip the headers.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1383 (unless (search-forward "\n\n" nil t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1384 (goto-char (point-max)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1385 (setq beg (point))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1386 (while (setq entry (pop alist))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1387 (setq regexp (car entry))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1388 (goto-char beg)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1389 (while (re-search-forward regexp nil t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1390 (let* ((start (and entry (match-beginning (nth 1 entry))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1391 (end (and entry (match-end (nth 1 entry))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1392 (from (match-beginning 0)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1393 (when (or (eq t (nth 1 entry))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1394 (eval (nth 1 entry)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1395 ;; That optional form returned non-nil, so we add the
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1396 ;; button.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1397 (gnus-article-add-button
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1398 start end 'gnus-button-push
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1399 (car (push (set-marker (make-marker) from)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1400 gnus-button-marker-list))))))))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1401
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1402 ;; Add buttons to the head of an article.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1403 (defun gnus-article-add-buttons-to-head ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1404 "Add buttons to the head of the article."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1405 (interactive)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1406 (save-excursion
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1407 (set-buffer gnus-article-buffer)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1408 (let ((buffer-read-only nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1409 (inhibit-point-motion-hooks t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1410 (case-fold-search t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1411 (alist gnus-header-button-alist)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1412 entry beg end)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1413 (nnheader-narrow-to-headers)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1414 (while alist
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1415 ;; Each alist entry.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1416 (setq entry (car alist)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1417 alist (cdr alist))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1418 (goto-char (point-min))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1419 (while (re-search-forward (car entry) nil t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1420 ;; Each header matching the entry.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1421 (setq beg (match-beginning 0))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1422 (setq end (or (and (re-search-forward "^[^ \t]" nil t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1423 (match-beginning 0))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1424 (point-max)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1425 (goto-char beg)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1426 (while (re-search-forward (nth 1 entry) end t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1427 ;; Each match within a header.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1428 (let* ((from (match-beginning 0))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1429 (entry (cdr entry))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1430 (start (match-beginning (nth 1 entry)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1431 (end (match-end (nth 1 entry)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1432 (form (nth 2 entry)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1433 (goto-char (match-end 0))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1434 (and (eval form)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1435 (gnus-article-add-button
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1436 start end (nth 3 entry)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1437 (buffer-substring (match-beginning (nth 4 entry))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1438 (match-end (nth 4 entry)))))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1439 (goto-char end))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1440 (widen)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1441
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1442 ;;; External functions:
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1443
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1444 (defun gnus-article-add-button (from to fun &optional data)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1445 "Create a button between FROM and TO with callback FUN and data DATA."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1446 (and gnus-article-button-face
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1447 (gnus-overlay-put (gnus-make-overlay from to)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1448 'face gnus-article-button-face))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1449 (gnus-add-text-properties
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1450 from to
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1451 (nconc (and gnus-article-mouse-face
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1452 (list gnus-mouse-face-prop gnus-article-mouse-face))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1453 (list 'gnus-callback fun)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1454 (and data (list 'gnus-data data)))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1455
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1456 ;;; Internal functions:
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1457
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1458 (defun gnus-signature-toggle (end)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1459 (save-excursion
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1460 (set-buffer gnus-article-buffer)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1461 (let ((buffer-read-only nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1462 (inhibit-point-motion-hooks t))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1463 (if (get-text-property end 'invisible)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1464 (gnus-unhide-text end (point-max))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1465 (gnus-hide-text end (point-max) gnus-hidden-properties)))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1466
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1467 (defun gnus-button-entry ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1468 ;; Return the first entry in `gnus-button-alist' matching this place.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1469 (let ((alist gnus-button-alist)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1470 (entry nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1471 (while alist
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1472 (setq entry (pop alist))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1473 (if (looking-at (car entry))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1474 (setq alist nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1475 (setq entry nil)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1476 entry))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1477
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1478 (defun gnus-button-push (marker)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1479 ;; Push button starting at MARKER.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1480 (save-excursion
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1481 (set-buffer gnus-article-buffer)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1482 (goto-char marker)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1483 (let* ((entry (gnus-button-entry))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1484 (inhibit-point-motion-hooks t)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1485 (fun (nth 3 entry))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1486 (args (mapcar (lambda (group)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1487 (let ((string (buffer-substring
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1488 (match-beginning group)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1489 (match-end group))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1490 (gnus-set-text-properties
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1491 0 (length string) nil string)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1492 string))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1493 (nthcdr 4 entry))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1494 (cond
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1495 ((fboundp fun)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1496 (apply fun args))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1497 ((and (boundp fun)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1498 (fboundp (symbol-value fun)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1499 (apply (symbol-value fun) args))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1500 (t
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1501 (gnus-message 1 "You must define `%S' to use this button"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1502 (cons fun args)))))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1503
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1504 (defun gnus-button-message-id (message-id)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1505 "Fetch MESSAGE-ID."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1506 (save-excursion
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1507 (set-buffer gnus-summary-buffer)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1508 (gnus-summary-refer-article message-id)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1509
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1510 (defun gnus-button-mailto (address)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1511 ;; Mail to ADDRESS.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1512 (set-buffer (gnus-copy-article-buffer))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1513 (message-reply address))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1514
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1515 (defun gnus-button-reply (address)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1516 ;; Reply to ADDRESS.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1517 (message-reply address))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1518
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1519 (defun gnus-button-url (address)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1520 "Browse ADDRESS."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1521 (funcall browse-url-browser-function address))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1522
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1523 ;;; Next/prev buttons in the article buffer.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1524
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1525 (defvar gnus-next-page-line-format "%{%(Next page...%)%}\n")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1526 (defvar gnus-prev-page-line-format "%{%(Previous page...%)%}\n")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1527
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1528 (defvar gnus-prev-page-map nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1529 (unless gnus-prev-page-map
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1530 (setq gnus-prev-page-map (make-sparse-keymap))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1531 (define-key gnus-prev-page-map gnus-mouse-2 'gnus-button-prev-page)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1532 (define-key gnus-prev-page-map "\r" 'gnus-button-prev-page))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1533
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1534 (defun gnus-insert-prev-page-button ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1535 (let ((buffer-read-only nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1536 (gnus-eval-format
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1537 gnus-prev-page-line-format nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1538 `(gnus-prev t local-map ,gnus-prev-page-map
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1539 gnus-callback gnus-article-button-prev-page))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1540
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1541 (defvar gnus-next-page-map nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1542 (unless gnus-next-page-map
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1543 (setq gnus-next-page-map (make-keymap))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1544 (suppress-keymap gnus-prev-page-map)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1545 (define-key gnus-next-page-map gnus-mouse-2 'gnus-button-next-page)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1546 (define-key gnus-next-page-map "\r" 'gnus-button-next-page))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1547
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1548 (defun gnus-button-next-page ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1549 "Go to the next page."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1550 (interactive)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1551 (let ((win (selected-window)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1552 (select-window (get-buffer-window gnus-article-buffer t))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1553 (gnus-article-next-page)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1554 (select-window win)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1555
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1556 (defun gnus-button-prev-page ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1557 "Go to the prev page."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1558 (interactive)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1559 (let ((win (selected-window)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1560 (select-window (get-buffer-window gnus-article-buffer t))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1561 (gnus-article-prev-page)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1562 (select-window win)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1563
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1564 (defun gnus-insert-next-page-button ()
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1565 (let ((buffer-read-only nil))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1566 (gnus-eval-format gnus-next-page-line-format nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1567 `(gnus-next t local-map ,gnus-next-page-map
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1568 gnus-callback
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1569 gnus-article-button-next-page))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1570
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1571 (defun gnus-article-button-next-page (arg)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1572 "Go to the next page."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1573 (interactive "P")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1574 (let ((win (selected-window)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1575 (select-window (get-buffer-window gnus-article-buffer t))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1576 (gnus-article-next-page)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1577 (select-window win)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1578
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1579 (defun gnus-article-button-prev-page (arg)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1580 "Go to the prev page."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1581 (interactive "P")
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1582 (let ((win (selected-window)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1583 (select-window (get-buffer-window gnus-article-buffer t))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1584 (gnus-article-prev-page)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1585 (select-window win)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1586
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1587 ;;; Compatibility Functions:
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1588
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1589 (or (fboundp 'rassoc)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1590 ;; Introduced in Emacs 19.29.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1591 (defun rassoc (elt list)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1592 "Return non-nil if ELT is `equal' to the cdr of an element of LIST.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1593 The value is actually the element of LIST whose cdr is ELT."
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1594 (let (result)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1595 (while list
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1596 (setq result (car list))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1597 (if (equal (cdr result) elt)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1598 (setq list nil)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1599 (setq result nil
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1600 list (cdr list))))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1601 result)))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1602
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1603 ; (require 'gnus-cus)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1604 (gnus-ems-redefine)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1605 (provide 'gnus-vis)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1606
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1607 ;;; gnus-vis.el ends here