mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-06 06:20:55 -08:00
`inhibit-point-motion-hooks` has defaulted to t (and been declared obsolete) since Emacs-25, so remove left-over bindings to that now default value. * lisp/dabbrev.el (dabbrev--search): * lisp/format.el (format-insert-file): * lisp/forms.el (forms-next-field, forms-prev-field): * lisp/minibuf-eldef.el (minibuf-eldef-setup-minibuffer): * lisp/simple.el (primitive-undo): * lisp/cedet/semantic/edit.el (semantic-change-function): * lisp/cedet/srecode/fields.el (srecode-field-mod-hook): * lisp/cedet/srecode/insert.el (srecode-insert-fcn): * lisp/erc/erc-button.el (erc-button-add-buttons): * lisp/erc/erc.el (erc-display-line): * lisp/eshell/em-script.el (eshell-source-file): * lisp/eshell/em-smart.el (eshell-smart-scroll-window): * lisp/eshell/esh-arg.el (eshell-parse-arguments): * lisp/eshell/esh-cmd.el (eshell-with-temp-command): * lisp/eshell/esh-mode.el (eshell-send-input, eshell-output-filter): * lisp/gnus/gnus-art.el (gnus-with-article-headers) (article-hide-headers, article-hide-boring-headers) (article-decode-mime-words, article-decode-charset) (article-decode-encoded-words, article-decode-group-name) (article-decode-idna-rhs, article-hide-list-identifiers) (article-strip-banner, article-really-strip-banner) (article-strip-leading-blank-lines) (article-strip-multiple-blank-lines, article-strip-leading-space) (article-strip-trailing-space, article-strip-all-blank-lines) (gnus-article-narrow-to-signature, gnus-article-show-hidden-text) (article-date-ut, article-verify-x-pgp-sig) (gnus-article-only-boring-p, gnus-article-highlight-signature) (gnus-article-add-buttons, gnus-signature-toggle, gnus-button-push): * lisp/gnus/gnus-cite.el (gnus-article-highlight-citation) (gnus-article-fill-cited-article, gnus-article-hide-citation) (gnus-article-toggle-cited-text, gnus-article-hide-citation-maybe) (gnus-cite-parse-wrapper, gnus-cite-add-face, gnus-cite-toggle): * lisp/gnus/gnus-gravatar.el (gnus-gravatar-insert): * lisp/gnus/gnus-rfc1843.el (rfc1843-decode-article-body): * lisp/gnus/gnus-sum.el (gnus-summary-toggle-header): * lisp/gnus/gnus-util.el (gnus-fetch-field): * lisp/gnus/message.el (message-fetch-field, message-reply) (message-followup, message-hide-headers): * lisp/net/goto-addr.el (goto-address-fontify): * lisp/obsolete/linum.el (linum-update-window): * lisp/play/zone.el (zone-shift-left, zone-shift-right) (zone-fill-out-screen): * lisp/progmodes/opascal.el (opascal-save-excursion): * lisp/progmodes/vhdl-mode.el (vhdl-prepare-search-2): * lisp/textmodes/enriched.el (enriched-encode): * lisp/textmodes/flyspell.el (flyspell-word-search-backward) (flyspell-word-search-forward): * lisp/textmodes/table.el (table--point-entered/left-cell-function): Remove let-binding of `inhibit-point-motion-hooks`.
76 lines
2.4 KiB
EmacsLisp
76 lines
2.4 KiB
EmacsLisp
;;; gnus-rfc1843.el --- HZ (rfc1843) decoding interface functions for Gnus -*- lexical-binding: t; -*-
|
|
|
|
;; Copyright (C) 1998-2022 Free Software Foundation, Inc.
|
|
|
|
;; Author: Shenghuo Zhu <zsh@cs.rochester.edu>
|
|
;; Keywords: news HZ HZ+ mail i18n
|
|
|
|
;; This file is part of GNU Emacs.
|
|
|
|
;; GNU Emacs is free software: you can redistribute it and/or modify
|
|
;; it under the terms of the GNU General Public License as published by
|
|
;; the Free Software Foundation, either version 3 of the License, or
|
|
;; (at your option) any later version.
|
|
|
|
;; GNU Emacs is distributed in the hope that it will be useful,
|
|
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
;; GNU General Public License for more details.
|
|
|
|
;; You should have received a copy of the GNU General Public License
|
|
;; along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>.
|
|
|
|
;;; Commentary:
|
|
|
|
;; Usage:
|
|
;; (require 'gnus-rfc1843)
|
|
;; (rfc1843-gnus-setup)
|
|
|
|
;;; Code:
|
|
|
|
(require 'rfc1843)
|
|
(require 'gnus-sum)
|
|
(require 'gnus-art)
|
|
(require 'message)
|
|
|
|
(defun rfc1843-decode-article-body ()
|
|
"Decode HZ encoded text in the article body."
|
|
(if (string-match (concat "\\<\\(" rfc1843-newsgroups-regexp "\\)\\>")
|
|
(or gnus-newsgroup-name ""))
|
|
(save-excursion
|
|
(save-restriction
|
|
(message-narrow-to-head)
|
|
(let* ((case-fold-search t)
|
|
(ct (message-fetch-field "Content-Type" t))
|
|
(ctl (and ct (mail-header-parse-content-type ct))))
|
|
(if (and ctl (not (string-search "/" (car ctl))))
|
|
(setq ctl nil))
|
|
(goto-char (point-max))
|
|
(widen)
|
|
(forward-line 1)
|
|
(narrow-to-region (point) (point-max))
|
|
(when (or (not ctl)
|
|
(equal (car ctl) "text/plain"))
|
|
(rfc1843-decode-region (point) (point-max))))))))
|
|
|
|
(defun rfc1843-gnus-setup ()
|
|
"Setup HZ decoding for Gnus."
|
|
(add-hook 'gnus-article-decode-hook #'rfc1843-decode-article-body t)
|
|
(setq gnus-decode-encoded-word-function
|
|
#'gnus-multi-decode-encoded-word-string
|
|
gnus-decode-header-function
|
|
#'gnus-multi-decode-header
|
|
gnus-decode-encoded-word-methods
|
|
(nconc gnus-decode-encoded-word-methods
|
|
(list
|
|
(cons (concat "\\<\\(" rfc1843-newsgroups-regexp "\\)\\>")
|
|
'rfc1843-decode-string)))
|
|
gnus-decode-header-methods
|
|
(nconc gnus-decode-header-methods
|
|
(list
|
|
(cons (concat "\\<\\(" rfc1843-newsgroups-regexp "\\)\\>")
|
|
'rfc1843-decode-region)))))
|
|
|
|
(provide 'gnus-rfc1843)
|
|
|
|
;;; gnus-rfc1843.el ends here
|