Mercurial > emacs
annotate lisp/gnus/nngateway.el @ 63531:60261c7a1b56
Revision: miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-428
Remove "-face" suffix from MH-E faces
2005-06-17 Miles Bader <miles@gnu.org>
* lisp/mh-e/mh-customize.el (mh-folder-body, mh-folder-cur-msg)
(mh-folder-cur-msg-number, mh-folder-date, mh-folder-followup)
(mh-folder-msg-number, mh-folder-refiled, mh-folder-subject)
(mh-folder-tick, mh-folder-to, mh-index-folder)
(mh-letter-header-field, mh-show-cc, mh-show-date)
(mh-show-header, mh-show-pgg-good, mh-show-pgg-unknown)
(mh-show-pgg-bad, mh-show-signature, mh-show-to, mh-show-from)
(mh-show-xface, mh-speedbar-folder, mh-speedbar-selected-folder)
(mh-speedbar-folder-with-unseen-messages)
(mh-speedbar-selected-folder-with-unseen-messages)
(mh-folder-msg-number, mh-folder-subject, mh-folder-followup)
(mh-folder-subject): Remove "-face" suffix from face names.
(mh-folder-body, mh-folder-cur-msg, mh-folder-cur-msg-number)
(mh-folder-date-face, mh-folder-followup-face)
(mh-folder-msg-number-face, mh-folder-refiled-face)
(mh-folder-subject-face, mh-folder-tick-face, mh-folder-to-face)
(mh-index-folder-face, mh-letter-header-field-face)
(mh-show-cc-face, mh-show-date-face, mh-show-header-face)
(mh-show-pgg-good-face, mh-show-pgg-unknown-face)
(mh-show-pgg-bad-face, mh-show-signature-face, mh-show-to-face)
(mh-show-from-face, mh-show-xface-face, mh-speedbar-folder-face)
(mh-speedbar-selected-folder-face)
(mh-speedbar-folder-with-unseen-messages-face)
(mh-speedbar-selected-folder-with-unseen-messages-face):
New backward-compatibility aliases for renamed faces.
(mh-folder-body-face, mh-folder-cur-msg-face)
(mh-folder-cur-msg-number-face, mh-folder-date-face)
(mh-folder-followup-face, mh-folder-msg-number-face)
(mh-folder-deleted-face, mh-folder-refiled-face)
(mh-folder-subject-face, mh-folder-address-face)
(mh-folder-scan-format-face, mh-folder-to-face)
(mh-index-folder-face, mh-show-cc-face, mh-show-date-face)
(mh-show-header-face, mh-show-pgg-good-face)
(mh-show-pgg-unknown-face, mh-show-pgg-bad-face)
(mh-show-to-face, mh-show-from-face, mh-show-subject-face)
(mh-speedbar-folder-with-unseen-messages)
(mh-speedbar-selected-folder-with-unseen-messages):
Use renamed MH-E faces.
* lisp/mh-e/mh-utils.el (mh-letter-font-lock-keywords)
(mh-face-display-function): Use renamed MH-E faces.
* lisp/mh-e/mh-speed.el (mh-folder-speedbar-buttons)
(mh-speed-update-current-folder, mh-speed-normal-face)
(mh-speed-bold-face, mh-speed-add-buttons)
(mh-speed-invalidate-map): Likewise.
* lisp/mh-e/mh-mime.el (mh-signature-highlight): Likewise.
author | Miles Bader <miles@gnu.org> |
---|---|
date | Fri, 17 Jun 2005 01:29:30 +0000 |
parents | 55fd4f77387a |
children | 18a818a2ee7c cce1c0ee76ee |
rev | line source |
---|---|
17493 | 1 ;;; nngateway.el --- posting news via mail gateways |
31716
9968f55ad26e
Update to emacs-21-branch of the Gnus CVS repository.
Gerd Moellmann <gerd@gnu.org>
parents:
24357
diff
changeset
|
2 |
56927
55fd4f77387a
Revision: miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-523
Miles Bader <miles@gnu.org>
parents:
52401
diff
changeset
|
3 ;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 |
31716
9968f55ad26e
Update to emacs-21-branch of the Gnus CVS repository.
Gerd Moellmann <gerd@gnu.org>
parents:
24357
diff
changeset
|
4 ;; Free Software Foundation, Inc. |
17493 | 5 |
24357
15fc6acbae7a
Upgrading to Gnus 5.7; see ChangeLog
Lars Magne Ingebrigtsen <larsi@gnus.org>
parents:
23712
diff
changeset
|
6 ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
17493 | 7 ;; Keywords: news, mail |
8 | |
9 ;; This file is part of GNU Emacs. | |
10 | |
11 ;; GNU Emacs is free software; you can redistribute it and/or modify | |
12 ;; it under the terms of the GNU General Public License as published by | |
13 ;; the Free Software Foundation; either version 2, or (at your option) | |
14 ;; any later version. | |
15 | |
16 ;; GNU Emacs is distributed in the hope that it will be useful, | |
17 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of | |
18 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
19 ;; GNU General Public License for more details. | |
20 | |
21 ;; You should have received a copy of the GNU General Public License | |
22 ;; along with GNU Emacs; see the file COPYING. If not, write to the | |
23 ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, | |
24 ;; Boston, MA 02111-1307, USA. | |
25 | |
26 ;;; Commentary: | |
27 | |
28 ;;; Code: | |
29 | |
23712 | 30 (eval-when-compile (require 'cl)) |
17493 | 31 (require 'nnoo) |
32 (require 'message) | |
33 | |
34 (nnoo-declare nngateway) | |
35 | |
36 (defvoo nngateway-address nil | |
37 "Address of the mail-to-news gateway.") | |
38 | |
39 (defvoo nngateway-header-transformation 'nngateway-simple-header-transformation | |
40 "Function to be called to rewrite the news headers into mail headers. | |
41 It is called narrowed to the headers to be transformed with one | |
42 parameter -- the gateway address.") | |
43 | |
44 ;;; Interface functions | |
45 | |
46 (nnoo-define-basics nngateway) | |
47 | |
48 (deffoo nngateway-open-server (server &optional defs) | |
49 (if (nngateway-server-opened server) | |
50 t | |
51 (unless (assq 'nngateway-address defs) | |
52 (setq defs (append defs (list (list 'nngateway-address server))))) | |
53 (nnoo-change-server 'nngateway server defs))) | |
54 | |
55 (deffoo nngateway-request-post (&optional server) | |
56 (when (or (nngateway-server-opened server) | |
57 (nngateway-open-server server)) | |
58 ;; Rewrite the header. | |
59 (let ((buf (current-buffer))) | |
31716
9968f55ad26e
Update to emacs-21-branch of the Gnus CVS repository.
Gerd Moellmann <gerd@gnu.org>
parents:
24357
diff
changeset
|
60 (with-temp-buffer |
17493 | 61 (insert-buffer-substring buf) |
62 (message-narrow-to-head) | |
63 (funcall nngateway-header-transformation nngateway-address) | |
19969
5f1ab3dd344d
*** empty log message ***
Lars Magne Ingebrigtsen <larsi@gnus.org>
parents:
17493
diff
changeset
|
64 (goto-char (point-max)) |
5f1ab3dd344d
*** empty log message ***
Lars Magne Ingebrigtsen <larsi@gnus.org>
parents:
17493
diff
changeset
|
65 (insert mail-header-separator "\n") |
17493 | 66 (widen) |
67 (let (message-required-mail-headers) | |
56927
55fd4f77387a
Revision: miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-523
Miles Bader <miles@gnu.org>
parents:
52401
diff
changeset
|
68 (funcall (or message-send-mail-real-function |
55fd4f77387a
Revision: miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-523
Miles Bader <miles@gnu.org>
parents:
52401
diff
changeset
|
69 message-send-mail-function))) |
24357
15fc6acbae7a
Upgrading to Gnus 5.7; see ChangeLog
Lars Magne Ingebrigtsen <larsi@gnus.org>
parents:
23712
diff
changeset
|
70 t)))) |
17493 | 71 |
72 ;;; Internal functions | |
73 | |
74 (defun nngateway-simple-header-transformation (gateway) | |
75 "Transform the headers to use GATEWAY." | |
76 (let ((newsgroups (mail-fetch-field "newsgroups"))) | |
77 (message-remove-header "to") | |
78 (message-remove-header "cc") | |
79 (goto-char (point-min)) | |
80 (insert "To: " (nnheader-replace-chars-in-string newsgroups ?. ?-) | |
81 "@" gateway "\n"))) | |
82 | |
24357
15fc6acbae7a
Upgrading to Gnus 5.7; see ChangeLog
Lars Magne Ingebrigtsen <larsi@gnus.org>
parents:
23712
diff
changeset
|
83 (defun nngateway-mail2news-header-transformation (gateway) |
15fc6acbae7a
Upgrading to Gnus 5.7; see ChangeLog
Lars Magne Ingebrigtsen <larsi@gnus.org>
parents:
23712
diff
changeset
|
84 "Transform the headers for sending to a mail2news gateway." |
15fc6acbae7a
Upgrading to Gnus 5.7; see ChangeLog
Lars Magne Ingebrigtsen <larsi@gnus.org>
parents:
23712
diff
changeset
|
85 (message-remove-header "to") |
15fc6acbae7a
Upgrading to Gnus 5.7; see ChangeLog
Lars Magne Ingebrigtsen <larsi@gnus.org>
parents:
23712
diff
changeset
|
86 (message-remove-header "cc") |
15fc6acbae7a
Upgrading to Gnus 5.7; see ChangeLog
Lars Magne Ingebrigtsen <larsi@gnus.org>
parents:
23712
diff
changeset
|
87 (goto-char (point-min)) |
15fc6acbae7a
Upgrading to Gnus 5.7; see ChangeLog
Lars Magne Ingebrigtsen <larsi@gnus.org>
parents:
23712
diff
changeset
|
88 (insert "To: " gateway "\n")) |
15fc6acbae7a
Upgrading to Gnus 5.7; see ChangeLog
Lars Magne Ingebrigtsen <larsi@gnus.org>
parents:
23712
diff
changeset
|
89 |
17493 | 90 (nnoo-define-skeleton nngateway) |
91 | |
92 (provide 'nngateway) | |
93 | |
52401 | 94 ;;; arch-tag: f7ecb92e-b10c-43d5-9a9b-1314233341fc |
17493 | 95 ;;; nngateway.el ends here |