mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-06 06:20:55 -08:00
Fix Imenu in 'emacs-news-view-mode'
* lisp/textmodes/emacs-news-mode.el (emacs-news-view-mode): Make it derived from emacs-news-mode. Add useful key bindings. (Bug#72080)
This commit is contained in:
parent
ea30ffc52b
commit
ab7c40ea52
1 changed files with 11 additions and 2 deletions
|
|
@ -107,12 +107,21 @@
|
||||||
(emacs-news--mode-common))
|
(emacs-news--mode-common))
|
||||||
|
|
||||||
;;;###autoload
|
;;;###autoload
|
||||||
(define-derived-mode emacs-news-view-mode special-mode "NEWS"
|
(define-derived-mode emacs-news-view-mode emacs-news-mode "NEWS"
|
||||||
"Major mode for viewing the Emacs NEWS file."
|
"Major mode for viewing the Emacs NEWS file."
|
||||||
(setq buffer-read-only t)
|
(setq buffer-read-only t)
|
||||||
(emacs-news--buttonize)
|
(emacs-news--buttonize)
|
||||||
(button-mode)
|
(button-mode)
|
||||||
(emacs-news--mode-common))
|
;; Bind useful browsing keys.
|
||||||
|
(keymap-local-set "q" 'quit-window)
|
||||||
|
(keymap-local-set "SPC" 'scroll-up-command)
|
||||||
|
(keymap-local-set "S-SPC" 'scroll-down-command)
|
||||||
|
(keymap-local-set "DEL" 'scroll-down-command)
|
||||||
|
(keymap-local-set "?" 'describe-mode)
|
||||||
|
(keymap-local-set "h" 'describe-mode)
|
||||||
|
(keymap-local-set ">" 'end-of-buffer)
|
||||||
|
(keymap-local-set "<" 'beginning-of-buffer)
|
||||||
|
(keymap-local-set "g" 'revert-buffer))
|
||||||
|
|
||||||
(defun emacs-news--fill-paragraph (&optional justify)
|
(defun emacs-news--fill-paragraph (&optional justify)
|
||||||
(cond
|
(cond
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue