aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPo Lu2021-12-09 10:30:18 +0800
committerPo Lu2021-12-09 10:30:18 +0800
commit47cd820d93d282da484ae91e68021736ed7994bc (patch)
treea24229d1df8547dfd427ef97cf9968b7f5a1e7a8
parent41b1d223c6ab7bca1b626a4c07a4f2dda2855feb (diff)
parent63f07ea22f3954c2154d831017caf494911cb515 (diff)
downloademacs-47cd820d93d282da484ae91e68021736ed7994bc.tar.gz
emacs-47cd820d93d282da484ae91e68021736ed7994bc.zip
Merge remote-tracking branch 'origin/master' into feature/pgtk
-rw-r--r--doc/lispref/compile.texi12
-rw-r--r--etc/NEWS17
-rw-r--r--lisp/calc/calc-ext.el38
-rw-r--r--lisp/calc/calc-store.el26
-rw-r--r--lisp/dired-aux.el14
-rw-r--r--lisp/emacs-lisp/shortdoc.el14
-rw-r--r--lisp/image-dired.el65
-rw-r--r--lisp/mail/rmailsum.el12
-rw-r--r--lisp/mouse.el147
-rw-r--r--lisp/net/browse-url.el20
-rw-r--r--lisp/net/newst-backend.el3
-rw-r--r--lisp/net/newsticker.el3
-rw-r--r--lisp/pixel-scroll.el57
-rw-r--r--lisp/progmodes/ebrowse.el36
-rw-r--r--lisp/speedbar.el32
-rw-r--r--src/nsterm.m6
-rw-r--r--test/lisp/emacs-lisp/cl-macs-tests.el12
-rw-r--r--test/lisp/emacs-lisp/subr-x-tests.el20
18 files changed, 291 insertions, 243 deletions
diff --git a/doc/lispref/compile.texi b/doc/lispref/compile.texi
index 523758c10f5..1ca1f66b95d 100644
--- a/doc/lispref/compile.texi
+++ b/doc/lispref/compile.texi
@@ -924,7 +924,11 @@ of the main Emacs process. This leaves the main Emacs process free to
924use while the compilation runs in the background. This is the method 924use while the compilation runs in the background. This is the method
925used by Emacs to natively-compile any Lisp file or byte-compiled Lisp 925used by Emacs to natively-compile any Lisp file or byte-compiled Lisp
926file that is loaded into Emacs, when no natively-compiled file for it 926file that is loaded into Emacs, when no natively-compiled file for it
927is available. 927is available. Note that because of this use of a subprocess, native
928compilation may produce warning and errors which byte-compilation does
929not, and lisp code may thus need to be modified to work correctly. See
930@code{native-comp-async-report-warnings-errors} in @pxref{Native-Compilation
931Variables} for more details.
928 932
929@defun native-compile-async files &optional recursively load selector 933@defun native-compile-async files &optional recursively load selector
930This function compiles the named @var{files} asynchronously. The 934This function compiles the named @var{files} asynchronously. The
@@ -1038,6 +1042,12 @@ Emacs session in a buffer named @file{*Warnings*}. The default value
1038@code{t} means display the resulting buffer. To log warnings without 1042@code{t} means display the resulting buffer. To log warnings without
1039popping up the @file{*Warnings*} buffer, set this variable to 1043popping up the @file{*Warnings*} buffer, set this variable to
1040@code{silent}. 1044@code{silent}.
1045
1046 A common cause for asynchronous native-compilation to produce
1047warnings is compiling a file that is missing some @code{require} of a
1048necessary feature. The feature may be loaded into the main emacs, but
1049because native compilation always starts from a subprocess with a
1050pristine environment, that may not be true for the subprocess.
1041@end defopt 1051@end defopt
1042 1052
1043@defopt native-comp-async-query-on-exit 1053@defopt native-comp-async-query-on-exit
diff --git a/etc/NEWS b/etc/NEWS
index e8e0c910ef0..9eee04b3399 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -85,8 +85,8 @@ To get the old monospaced mode line back, customize the
85'mode-line-active' and 'mode-line-inactive' faces not to inherit from 85'mode-line-active' and 'mode-line-inactive' faces not to inherit from
86the 'variable-pitch' face, or add this to your "~/.emacs": 86the 'variable-pitch' face, or add this to your "~/.emacs":
87 87
88 (set-face-attribute 'mode-line-active nil :inherit 'mode-line) 88 (set-face-attribute 'mode-line-active nil :inherit 'mode-line)
89 (set-face-attribute 'mode-line-inactive nil :inherit 'mode-line) 89 (set-face-attribute 'mode-line-inactive nil :inherit 'mode-line)
90 90
91 91
92* Changes in Emacs 29.1 92* Changes in Emacs 29.1
@@ -556,8 +556,8 @@ user options that are no longer needed are now obsolete:
556*** Navigation and marking commands now work in image display buffer. 556*** Navigation and marking commands now work in image display buffer.
557The following new bindings have been added: 557The following new bindings have been added:
558 558
559 n / SPC image-dired-display-previous-thumbnail-original 559 n / SPC image-dired-display-next-thumbnail-original
560 p / DEL image-dired-display-next-thumbnail-original 560 p / DEL image-dired-display-previous-thumbnail-original
561 m image-dired-mark-thumb-original-file 561 m image-dired-mark-thumb-original-file
562 d image-dired-flag-thumb-original-file 562 d image-dired-flag-thumb-original-file
563 u image-dired-unmark-thumb-original-file 563 u image-dired-unmark-thumb-original-file
@@ -610,6 +610,12 @@ The command 'bookmark-set' (bound to 'C-x r m') is now supported in
610the thumbnail view, and will create a bookmark that opens the current 610the thumbnail view, and will create a bookmark that opens the current
611directory in Image-Dired. 611directory in Image-Dired.
612 612
613---
614*** New user option 'image-dired-marking-shows-next'.
615If this option is non-nil (the default), marking, unmarking or
616flagging an image in either the thumbnail or display buffer shows the
617next image.
618
613+++ 619+++
614*** 'image-dired-show-all-from-dir-max-files' has been increased to 500. 620*** 'image-dired-show-all-from-dir-max-files' has been increased to 500.
615This option controls asking for confirmation when starting Image-Dired 621This option controls asking for confirmation when starting Image-Dired
@@ -718,10 +724,11 @@ Emacs buffers, like indentation and the like. The new ert function
718 724
719* Incompatible Lisp Changes in Emacs 29.1 725* Incompatible Lisp Changes in Emacs 29.1
720 726
721** User option 'mail-source-ignore-errors' is now obsolete 727** User option 'mail-source-ignore-errors' is now obsolete.
722The whole mechanism for prompting users to continue in case of 728The whole mechanism for prompting users to continue in case of
723mail-source errors has been removed, so this option is no longer 729mail-source errors has been removed, so this option is no longer
724needed. 730needed.
731
725** Fonts 732** Fonts
726 733
727--- 734---
diff --git a/lisp/calc/calc-ext.el b/lisp/calc/calc-ext.el
index dbe2f689d85..93ba8c4b6bb 100644
--- a/lisp/calc/calc-ext.el
+++ b/lisp/calc/calc-ext.el
@@ -1266,27 +1266,23 @@ calc-kill calc-kill-region calc-yank))))
1266 (math-normalize val))))) 1266 (math-normalize val)))))
1267 1267
1268 1268
1269(defvar calc-help-map nil) 1269(defvar-keymap calc-help-map
1270 1270 "b" 'calc-describe-bindings
1271(if calc-help-map 1271 "c" 'calc-describe-key-briefly
1272 nil 1272 "f" 'calc-describe-function
1273 (setq calc-help-map (make-keymap)) 1273 "h" 'calc-full-help
1274 (define-key calc-help-map "b" 'calc-describe-bindings) 1274 "i" 'calc-info
1275 (define-key calc-help-map "c" 'calc-describe-key-briefly) 1275 "k" 'calc-describe-key
1276 (define-key calc-help-map "f" 'calc-describe-function) 1276 "n" 'calc-view-news
1277 (define-key calc-help-map "h" 'calc-full-help) 1277 "s" 'calc-info-summary
1278 (define-key calc-help-map "i" 'calc-info) 1278 "t" 'calc-tutorial
1279 (define-key calc-help-map "k" 'calc-describe-key) 1279 "v" 'calc-describe-variable
1280 (define-key calc-help-map "n" 'calc-view-news) 1280 "C-c" 'calc-describe-copying
1281 (define-key calc-help-map "s" 'calc-info-summary) 1281 "C-d" 'calc-describe-distribution
1282 (define-key calc-help-map "t" 'calc-tutorial) 1282 "C-n" 'calc-view-news
1283 (define-key calc-help-map "v" 'calc-describe-variable) 1283 "C-w" 'calc-describe-no-warranty
1284 (define-key calc-help-map "\C-c" 'calc-describe-copying) 1284 "?" 'calc-help-for-help
1285 (define-key calc-help-map "\C-d" 'calc-describe-distribution) 1285 "C-h" 'calc-help-for-help)
1286 (define-key calc-help-map "\C-n" 'calc-view-news)
1287 (define-key calc-help-map "\C-w" 'calc-describe-no-warranty)
1288 (define-key calc-help-map "?" 'calc-help-for-help)
1289 (define-key calc-help-map "\C-h" 'calc-help-for-help))
1290 1286
1291(defvar calc-prefix-help-retry nil) 1287(defvar calc-prefix-help-retry nil)
1292(defvar calc-prefix-help-phase 0) 1288(defvar calc-prefix-help-phase 0)
diff --git a/lisp/calc/calc-store.el b/lisp/calc/calc-store.el
index de2f18f3947..817b50951dd 100644
--- a/lisp/calc/calc-store.el
+++ b/lisp/calc/calc-store.el
@@ -163,19 +163,19 @@
163 tag (and (not val) 1)) 163 tag (and (not val) 1))
164 (message "Variable \"%s\" changed" (calc-var-name var))))))) 164 (message "Variable \"%s\" changed" (calc-var-name var)))))))
165 165
166(defvar calc-var-name-map nil "Keymap for reading Calc variable names.") 166(defvar calc-var-name-map
167(if calc-var-name-map 167 (let ((map (copy-keymap minibuffer-local-completion-map)))
168 () 168 (define-key map " " #'self-insert-command)
169 (setq calc-var-name-map (copy-keymap minibuffer-local-completion-map)) 169 (mapc (lambda (x)
170 (define-key calc-var-name-map " " 'self-insert-command) 170 (define-key map (char-to-string x)
171 (mapc (lambda (x) 171 #'calcVar-digit))
172 (define-key calc-var-name-map (char-to-string x) 172 "0123456789")
173 'calcVar-digit)) 173 (mapc (lambda (x)
174 "0123456789") 174 (define-key map (char-to-string x)
175 (mapc (lambda (x) 175 #'calcVar-oper))
176 (define-key calc-var-name-map (char-to-string x) 176 "+-*/^|")
177 'calcVar-oper)) 177 map)
178 "+-*/^|")) 178 "Keymap for reading Calc variable names.")
179 179
180(defvar calc-store-opers) 180(defvar calc-store-opers)
181 181
diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el
index af7b160c1a4..5301a3a27ff 100644
--- a/lisp/dired-aux.el
+++ b/lisp/dired-aux.el
@@ -992,12 +992,14 @@ prompted for the shell command to use interactively."
992 992
993 993
994(defun dired-check-process (msg program &rest arguments) 994(defun dired-check-process (msg program &rest arguments)
995 "Display MSG while running PROGRAM, and check for output. 995 "Display MSG, then run PROGRAM, and log any error messages from it.
996Remaining arguments are strings passed as command arguments to PROGRAM. 996ARGUMENTS should be strings to be passed to PROGRAM as command-line
997On error, insert output 997arguments.
998in a log buffer and return the offending ARGUMENTS or PROGRAM. 998
999Caller can cons up a list of failed args. 999If PROGRAM exits successfully, display \"MSG...done\" and return nil.
1000Else returns nil for success." 1000If PROGRAM exits abnormally, save in `dired-log-buffer' the command
1001that invoked PROGRAM and the messages it emitted, and return either
1002the offending ARGUMENTS or PROGRAM if no ARGUMENTS were provided."
1001 (let (err-buffer err (dir default-directory)) 1003 (let (err-buffer err (dir default-directory))
1002 (message "%s..." msg) 1004 (message "%s..." msg)
1003 (save-excursion 1005 (save-excursion
diff --git a/lisp/emacs-lisp/shortdoc.el b/lisp/emacs-lisp/shortdoc.el
index ba08e68af57..5c51e257eb0 100644
--- a/lisp/emacs-lisp/shortdoc.el
+++ b/lisp/emacs-lisp/shortdoc.el
@@ -1423,14 +1423,12 @@ Example:
1423 (setq slist (cdr slist))) 1423 (setq slist (cdr slist)))
1424 (setcdr slist (cons elem (cdr slist)))))) 1424 (setcdr slist (cons elem (cdr slist))))))
1425 1425
1426(defvar shortdoc-mode-map 1426(defvar-keymap shortdoc-mode-map
1427 (let ((map (make-sparse-keymap))) 1427 :doc "Keymap for `shortdoc-mode'."
1428 (define-key map (kbd "n") 'shortdoc-next) 1428 "n" #'shortdoc-next
1429 (define-key map (kbd "p") 'shortdoc-previous) 1429 "p" #'shortdoc-previous
1430 (define-key map (kbd "C-c C-n") 'shortdoc-next-section) 1430 "C-c C-n" #'shortdoc-next-section
1431 (define-key map (kbd "C-c C-p") 'shortdoc-previous-section) 1431 "C-c C-p" #'shortdoc-previous-section)
1432 map)
1433 "Keymap for `shortdoc-mode'.")
1434 1432
1435(define-derived-mode shortdoc-mode special-mode "shortdoc" 1433(define-derived-mode shortdoc-mode special-mode "shortdoc"
1436 "Mode for shortdoc." 1434 "Mode for shortdoc."
diff --git a/lisp/image-dired.el b/lisp/image-dired.el
index d75ccfece11..c5cc586f252 100644
--- a/lisp/image-dired.el
+++ b/lisp/image-dired.el
@@ -103,9 +103,6 @@
103;; TODO 103;; TODO
104;; ==== 104;; ====
105;; 105;;
106;; * Some sort of auto-rotate function based on rotate info in the
107;; EXIF data.
108;;
109;; * Investigate if it is possible to also write the tags to the image 106;; * Investigate if it is possible to also write the tags to the image
110;; files. 107;; files.
111;; 108;;
@@ -114,12 +111,6 @@
114;; 111;;
115;; * From thumbs.el: Add setroot function. 112;; * From thumbs.el: Add setroot function.
116;; 113;;
117;; * From thumbs.el: Add image resizing, if useful (image-dired's automatic
118;; "image fit" might be enough)
119;;
120;; * From thumbs.el: Add the "modify" commands (emboss, negate,
121;; monochrome etc).
122;;
123;; * Add `image-dired-display-thumbs-ring' and functions to cycle that. Find out 114;; * Add `image-dired-display-thumbs-ring' and functions to cycle that. Find out
124;; which is best, saving old batch just before inserting new, or 115;; which is best, saving old batch just before inserting new, or
125;; saving the current batch in the ring when inserting it. Adding 116;; saving the current batch in the ring when inserting it. Adding
@@ -499,6 +490,17 @@ variable is nil, it will never ask."
499 (const :tag "Disable warning" nil)) 490 (const :tag "Disable warning" nil))
500 :version "29.1") 491 :version "29.1")
501 492
493(defcustom image-dired-marking-shows-next t
494 "If non-nil, marking, unmarking or flagging an image shows the next image.
495
496This affects the following commands:
497\\<image-dired-thumbnail-mode-map>
498 `image-dired-flag-thumb-original-file' (bound to \\[image-dired-flag-thumb-original-file])
499 `image-dired-mark-thumb-original-file' (bound to \\[image-dired-mark-thumb-original-file])
500 `image-dired-unmark-thumb-original-file' (bound to \\[image-dired-unmark-thumb-original-file])"
501 :type 'boolean
502 :version "29.1")
503
502 504
503;;; Util functions 505;;; Util functions
504 506
@@ -1468,46 +1470,53 @@ Should be called from commands in `image-dired-thumbnail-mode'."
1468 ,@body 1470 ,@body
1469 (image-dired-thumb-update-marks)))))) 1471 (image-dired-thumb-update-marks))))))
1470 1472
1473(defmacro image-dired--do-mark-command (maybe-next &rest body)
1474 "Helper macro for the mark, unmark and flag commands.
1475Run BODY in Dired buffer.
1476If optional argument MAYBE-NEXT is non-nil, show next image
1477according to `image-dired-marking-shows-next'."
1478 (declare (indent defun) (debug t))
1479 `(image-dired--with-thumbnail-buffer
1480 (image-dired--on-file-in-dired-buffer
1481 ,@body)
1482 ,(when maybe-next
1483 '(if image-dired-marking-shows-next
1484 (image-dired-display-next-thumbnail-original)
1485 (image-dired-next-line)))))
1486
1471(defun image-dired-mark-thumb-original-file () 1487(defun image-dired-mark-thumb-original-file ()
1472 "Mark original image file in associated Dired buffer." 1488 "Mark original image file in associated Dired buffer."
1473 (interactive nil image-dired-thumbnail-mode image-dired-display-image-mode) 1489 (interactive nil image-dired-thumbnail-mode image-dired-display-image-mode)
1474 (image-dired--with-thumbnail-buffer 1490 (image-dired--do-mark-command t
1475 (image-dired--on-file-in-dired-buffer 1491 (dired-mark 1)))
1476 (dired-mark 1))
1477 (image-dired-forward-image)))
1478 1492
1479(defun image-dired-unmark-thumb-original-file () 1493(defun image-dired-unmark-thumb-original-file ()
1480 "Unmark original image file in associated Dired buffer." 1494 "Unmark original image file in associated Dired buffer."
1481 (interactive nil image-dired-thumbnail-mode image-dired-display-image-mode) 1495 (interactive nil image-dired-thumbnail-mode image-dired-display-image-mode)
1482 (image-dired--with-thumbnail-buffer 1496 (image-dired--do-mark-command t
1483 (image-dired--on-file-in-dired-buffer 1497 (dired-unmark 1)))
1484 (dired-unmark 1))
1485 (image-dired-forward-image)))
1486 1498
1487(defun image-dired-flag-thumb-original-file () 1499(defun image-dired-flag-thumb-original-file ()
1488 "Flag original image file for deletion in associated Dired buffer." 1500 "Flag original image file for deletion in associated Dired buffer."
1489 (interactive nil image-dired-thumbnail-mode image-dired-display-image-mode) 1501 (interactive nil image-dired-thumbnail-mode image-dired-display-image-mode)
1490 (image-dired--with-thumbnail-buffer 1502 (image-dired--do-mark-command t
1491 (image-dired--on-file-in-dired-buffer 1503 (dired-flag-file-deletion 1)))
1492 (dired-flag-file-deletion 1))
1493 (image-dired-forward-image)))
1494 1504
1495(defun image-dired-toggle-mark-thumb-original-file () 1505(defun image-dired-toggle-mark-thumb-original-file ()
1496 "Toggle mark on original image file in associated Dired buffer." 1506 "Toggle mark on original image file in associated Dired buffer."
1497 (interactive nil image-dired-thumbnail-mode image-dired-display-image-mode) 1507 (interactive nil image-dired-thumbnail-mode image-dired-display-image-mode)
1498 (image-dired--with-thumbnail-buffer 1508 (image-dired--do-mark-command nil
1499 (image-dired--on-file-in-dired-buffer 1509 (if (image-dired-dired-file-marked-p)
1500 (if (image-dired-dired-file-marked-p) 1510 (dired-unmark 1)
1501 (dired-unmark 1) 1511 (dired-mark 1))))
1502 (dired-mark 1)))))
1503 1512
1504(defun image-dired-unmark-all-marks () 1513(defun image-dired-unmark-all-marks ()
1505 "Remove all marks from all files in associated Dired buffer. 1514 "Remove all marks from all files in associated Dired buffer.
1506Also update the marks in the thumbnail buffer." 1515Also update the marks in the thumbnail buffer."
1507 (interactive nil image-dired-thumbnail-mode image-dired-display-image-mode) 1516 (interactive nil image-dired-thumbnail-mode image-dired-display-image-mode)
1517 (image-dired--do-mark-command nil
1518 (dired-unmark-all-marks))
1508 (image-dired--with-thumbnail-buffer 1519 (image-dired--with-thumbnail-buffer
1509 (with-current-buffer (image-dired-associated-dired-buffer)
1510 (dired-unmark-all-marks))
1511 (image-dired-thumb-update-marks))) 1520 (image-dired-thumb-update-marks)))
1512 1521
1513(defun image-dired-jump-original-dired-buffer () 1522(defun image-dired-jump-original-dired-buffer ()
diff --git a/lisp/mail/rmailsum.el b/lisp/mail/rmailsum.el
index 9dd9573a9fc..8fc3fc095cc 100644
--- a/lisp/mail/rmailsum.el
+++ b/lisp/mail/rmailsum.el
@@ -1480,13 +1480,11 @@ argument says to read a file name and use that file as the inbox."
1480(declare-function rmail-output-read-file-name "rmailout" ()) 1480(declare-function rmail-output-read-file-name "rmailout" ())
1481(declare-function mail-send-and-exit "sendmail" (&optional arg)) 1481(declare-function mail-send-and-exit "sendmail" (&optional arg))
1482 1482
1483(defvar rmail-summary-edit-map nil) 1483(defvar rmail-summary-edit-map
1484(if rmail-summary-edit-map 1484 (let ((map (nconc (make-sparse-keymap) text-mode-map)))
1485 nil 1485 (define-key map "\C-c\C-c" #'rmail-cease-edit)
1486 (setq rmail-summary-edit-map 1486 (define-key map "\C-c\C-]" #'rmail-abort-edit)
1487 (nconc (make-sparse-keymap) text-mode-map)) 1487 map))
1488 (define-key rmail-summary-edit-map "\C-c\C-c" 'rmail-cease-edit)
1489 (define-key rmail-summary-edit-map "\C-c\C-]" 'rmail-abort-edit))
1490 1488
1491(defun rmail-summary-edit-current-message () 1489(defun rmail-summary-edit-current-message ()
1492 "Edit the contents of this message." 1490 "Edit the contents of this message."
diff --git a/lisp/mouse.el b/lisp/mouse.el
index 459cce4cd97..11fdd3f6391 100644
--- a/lisp/mouse.el
+++ b/lisp/mouse.el
@@ -184,8 +184,8 @@ items `Turn Off' and `Help'."
184 "-" " " (format "%S" minor-mode)))) 184 "-" " " (format "%S" minor-mode))))
185 (turn-off menu-item "Turn off minor mode" ,mm-fun) 185 (turn-off menu-item "Turn off minor mode" ,mm-fun)
186 (help menu-item "Help for minor mode" 186 (help menu-item "Help for minor mode"
187 (lambda () (interactive) 187 ,(lambda () (interactive)
188 (describe-function ',mm-fun))))))) 188 (describe-function mm-fun)))))))
189 (if menu 189 (if menu
190 (popup-menu menu) 190 (popup-menu menu)
191 (message "No menu available"))))) 191 (message "No menu available")))))
@@ -271,7 +271,7 @@ not it is actually displayed."
271 ;; FIXME: We have a problem here: we have to use the global/local/minor 271 ;; FIXME: We have a problem here: we have to use the global/local/minor
272 ;; so they're displayed in the expected order, but later on in the command 272 ;; so they're displayed in the expected order, but later on in the command
273 ;; loop, they're actually looked up in the opposite order. 273 ;; loop, they're actually looked up in the opposite order.
274 (apply 'append 274 (apply #'append
275 global-menu 275 global-menu
276 local-menu 276 local-menu
277 minor-mode-menus))) 277 minor-mode-menus)))
@@ -524,8 +524,8 @@ Some context functions add menu items below the separator."
524 menu) 524 menu)
525 525
526(defvar context-menu-entry 526(defvar context-menu-entry
527 `(menu-item ,(purecopy "Context Menu") ignore 527 `(menu-item ,(purecopy "Context Menu") ,(make-sparse-keymap)
528 :filter (lambda (_) (context-menu-map))) 528 :filter ,(lambda (_) (context-menu-map)))
529 "Menu item that creates the context menu and can be bound to a mouse key.") 529 "Menu item that creates the context menu and can be bound to a mouse key.")
530 530
531(defvar context-menu-mode-map 531(defvar context-menu-mode-map
@@ -546,7 +546,7 @@ Some context functions add menu items below the separator."
546 546
547When Context Menu mode is enabled, clicking the mouse button down-mouse-3 547When Context Menu mode is enabled, clicking the mouse button down-mouse-3
548activates the menu whose contents depends on its surrounding context." 548activates the menu whose contents depends on its surrounding context."
549 :global t :group 'mouse) 549 :global t)
550 550
551(defun context-menu-open () 551(defun context-menu-open ()
552 "Start key navigation of the context menu. 552 "Start key navigation of the context menu.
@@ -558,7 +558,7 @@ This is the keyboard interface to \\[context-menu-map]."
558 (call-interactively map) 558 (call-interactively map)
559 (popup-menu map (point))))) 559 (popup-menu map (point)))))
560 560
561(global-set-key [S-f10] 'context-menu-open) 561(global-set-key [S-f10] #'context-menu-open)
562 562
563(defun mark-thing-at-mouse (click thing) 563(defun mark-thing-at-mouse (click thing)
564 "Activate the region around THING found near the mouse CLICK." 564 "Activate the region around THING found near the mouse CLICK."
@@ -613,7 +613,7 @@ This command must be bound to a mouse click."
613 (or (eq frame oframe) 613 (or (eq frame oframe)
614 (set-mouse-position (selected-frame) (1- (frame-width)) 0)))) 614 (set-mouse-position (selected-frame) (1- (frame-width)) 0))))
615 615
616(define-obsolete-function-alias 'mouse-tear-off-window 'tear-off-window "24.4") 616(define-obsolete-function-alias 'mouse-tear-off-window #'tear-off-window "24.4")
617(defun tear-off-window (click) 617(defun tear-off-window (click)
618 "Delete the selected window, and create a new frame displaying its buffer." 618 "Delete the selected window, and create a new frame displaying its buffer."
619 (interactive (list last-nonmenu-event)) 619 (interactive (list last-nonmenu-event))
@@ -689,7 +689,6 @@ must be one of the symbols `header', `mode', or `vertical'."
689 ;; previously sampled position. The difference of `position' 689 ;; previously sampled position. The difference of `position'
690 ;; and `last-position' determines the size change of WINDOW. 690 ;; and `last-position' determines the size change of WINDOW.
691 (last-position position) 691 (last-position position)
692 (draggable t)
693 posn-window growth dragged) 692 posn-window growth dragged)
694 ;; Decide on whether we are allowed to track at all and whose 693 ;; Decide on whether we are allowed to track at all and whose
695 ;; window's edge we drag. 694 ;; window's edge we drag.
@@ -742,7 +741,7 @@ must be one of the symbols `header', `mode', or `vertical'."
742 (setq dragged t) 741 (setq dragged t)
743 (adjust-window-trailing-edge window growth t t)) 742 (adjust-window-trailing-edge window growth t t))
744 (setq last-position position)) 743 (setq last-position position))
745 (draggable 744 (t
746 ;; Drag bottom edge of `window'. 745 ;; Drag bottom edge of `window'.
747 (setq start (event-start event)) 746 (setq start (event-start event))
748 ;; Set `posn-window' to the window where `event' was recorded. 747 ;; Set `posn-window' to the window where `event' was recorded.
@@ -1842,7 +1841,7 @@ If MODE is 2 then do the same for lines."
1842 event))) 1841 event)))
1843 (setcar last new) 1842 (setcar last new)
1844 (if (and (not (equal modifiers old-modifiers)) 1843 (if (and (not (equal modifiers old-modifiers))
1845 (key-binding (apply 'vector events))) 1844 (key-binding (apply #'vector events)))
1846 t 1845 t
1847 (setcar last event) 1846 (setcar last event)
1848 nil))) 1847 nil)))
@@ -1896,12 +1895,12 @@ regardless of where you click."
1896 (setq mouse-selection-click-count 0) 1895 (setq mouse-selection-click-count 0)
1897 (yank arg)) 1896 (yank arg))
1898 1897
1899(defun mouse-yank-primary (click) 1898(defun mouse-yank-primary (&optional event)
1900 "Insert the primary selection at the position clicked on. 1899 "Insert the primary selection,
1901Move point to the end of the inserted text, and set mark at 1900Move point to the end of the inserted text, and set mark at
1902beginning. If `mouse-yank-at-point' is non-nil, insert at point 1901beginning. If `mouse-yank-at-point' is non-nil, insert at point
1903regardless of where you click." 1902otherwise insert it at the position of EVENT."
1904 (interactive "e") 1903 (interactive (list last-nonmenu-event))
1905 ;; Give temporary modes such as isearch a chance to turn off. 1904 ;; Give temporary modes such as isearch a chance to turn off.
1906 (run-hooks 'mouse-leave-buffer-hook) 1905 (run-hooks 'mouse-leave-buffer-hook)
1907 ;; Without this, confusing things happen upon e.g. inserting into 1906 ;; Without this, confusing things happen upon e.g. inserting into
@@ -1909,7 +1908,7 @@ regardless of where you click."
1909 (when select-active-regions 1908 (when select-active-regions
1910 (let (select-active-regions) 1909 (let (select-active-regions)
1911 (deactivate-mark))) 1910 (deactivate-mark)))
1912 (or mouse-yank-at-point (mouse-set-point click)) 1911 (or mouse-yank-at-point (mouse-set-point event))
1913 (let ((primary (gui-get-primary-selection))) 1912 (let ((primary (gui-get-primary-selection)))
1914 (push-mark) 1913 (push-mark)
1915 (insert-for-yank primary))) 1914 (insert-for-yank primary)))
@@ -2049,11 +2048,11 @@ if `mouse-drag-copy-region' is non-nil)."
2049 (setq mouse-save-then-kill-posn click-pt))))) 2048 (setq mouse-save-then-kill-posn click-pt)))))
2050 2049
2051 2050
2052(global-set-key [M-mouse-1] 'mouse-start-secondary) 2051(global-set-key [M-mouse-1] #'mouse-start-secondary)
2053(global-set-key [M-drag-mouse-1] 'mouse-set-secondary) 2052(global-set-key [M-drag-mouse-1] #'mouse-set-secondary)
2054(global-set-key [M-down-mouse-1] 'mouse-drag-secondary) 2053(global-set-key [M-down-mouse-1] #'mouse-drag-secondary)
2055(global-set-key [M-mouse-3] 'mouse-secondary-save-then-kill) 2054(global-set-key [M-mouse-3] #'mouse-secondary-save-then-kill)
2056(global-set-key [M-mouse-2] 'mouse-yank-secondary) 2055(global-set-key [M-mouse-2] #'mouse-yank-secondary)
2057 2056
2058(defconst mouse-secondary-overlay 2057(defconst mouse-secondary-overlay
2059 (let ((ol (make-overlay (point-min) (point-min)))) 2058 (let ((ol (make-overlay (point-min) (point-min))))
@@ -3213,78 +3212,78 @@ is copied instead of being cut."
3213 3212
3214;;; Bindings for mouse commands. 3213;;; Bindings for mouse commands.
3215 3214
3216(global-set-key [down-mouse-1] 'mouse-drag-region) 3215(global-set-key [down-mouse-1] #'mouse-drag-region)
3217(global-set-key [mouse-1] 'mouse-set-point) 3216(global-set-key [mouse-1] #'mouse-set-point)
3218(global-set-key [drag-mouse-1] 'mouse-set-region) 3217(global-set-key [drag-mouse-1] #'mouse-set-region)
3219 3218
3220(defun mouse--strip-first-event (_prompt) 3219(defun mouse--strip-first-event (_prompt)
3221 (substring (this-single-command-raw-keys) 1)) 3220 (substring (this-single-command-raw-keys) 1))
3222 3221
3223(define-key function-key-map [left-fringe mouse-1] 'mouse--strip-first-event) 3222(define-key function-key-map [left-fringe mouse-1] #'mouse--strip-first-event)
3224(define-key function-key-map [right-fringe mouse-1] 'mouse--strip-first-event) 3223(define-key function-key-map [right-fringe mouse-1] #'mouse--strip-first-event)
3225 3224
3226(global-set-key [mouse-2] 'mouse-yank-primary) 3225(global-set-key [mouse-2] #'mouse-yank-primary)
3227;; Allow yanking also when the corresponding cursor is "in the fringe". 3226;; Allow yanking also when the corresponding cursor is "in the fringe".
3228(define-key function-key-map [right-fringe mouse-2] 'mouse--strip-first-event) 3227(define-key function-key-map [right-fringe mouse-2] #'mouse--strip-first-event)
3229(define-key function-key-map [left-fringe mouse-2] 'mouse--strip-first-event) 3228(define-key function-key-map [left-fringe mouse-2] #'mouse--strip-first-event)
3230(global-set-key [mouse-3] 'mouse-save-then-kill) 3229(global-set-key [mouse-3] #'mouse-save-then-kill)
3231(define-key function-key-map [right-fringe mouse-3] 'mouse--strip-first-event) 3230(define-key function-key-map [right-fringe mouse-3] #'mouse--strip-first-event)
3232(define-key function-key-map [left-fringe mouse-3] 'mouse--strip-first-event) 3231(define-key function-key-map [left-fringe mouse-3] #'mouse--strip-first-event)
3233 3232
3234;; By binding these to down-going events, we let the user use the up-going 3233;; By binding these to down-going events, we let the user use the up-going
3235;; event to make the selection, saving a click. 3234;; event to make the selection, saving a click.
3236(global-set-key [C-down-mouse-1] 'mouse-buffer-menu) 3235(global-set-key [C-down-mouse-1] #'mouse-buffer-menu)
3237(if (not (eq system-type 'ms-dos)) 3236(if (not (eq system-type 'ms-dos))
3238 (global-set-key [S-down-mouse-1] 'mouse-appearance-menu)) 3237 (global-set-key [S-down-mouse-1] #'mouse-appearance-menu))
3239;; C-down-mouse-2 is bound in facemenu.el. 3238;; C-down-mouse-2 is bound in facemenu.el.
3240(global-set-key [C-down-mouse-3] 3239(global-set-key [C-down-mouse-3]
3241 `(menu-item ,(purecopy "Menu Bar") ignore 3240 `(menu-item ,(purecopy "Menu Bar") ignore
3242 :filter (lambda (_) 3241 :filter ,(lambda (_)
3243 (if (zerop (or (frame-parameter nil 'menu-bar-lines) 0)) 3242 (if (zerop (or (frame-parameter nil 'menu-bar-lines) 0))
3244 (mouse-menu-bar-map) 3243 (mouse-menu-bar-map)
3245 (mouse-menu-major-mode-map))))) 3244 (mouse-menu-major-mode-map)))))
3246 3245
3247;; Binding mouse-1 to mouse-select-window when on mode-, header-, or 3246;; Binding mouse-1 to mouse-select-window when on mode-, header-, or
3248;; vertical-line prevents Emacs from signaling an error when the mouse 3247;; vertical-line prevents Emacs from signaling an error when the mouse
3249;; button is released after dragging these lines, on non-toolkit 3248;; button is released after dragging these lines, on non-toolkit
3250;; versions. 3249;; versions.
3251(global-set-key [header-line down-mouse-1] 'mouse-drag-header-line) 3250(global-set-key [header-line down-mouse-1] #'mouse-drag-header-line)
3252(global-set-key [header-line mouse-1] 'mouse-select-window) 3251(global-set-key [header-line mouse-1] #'mouse-select-window)
3253(global-set-key [tab-line down-mouse-1] 'mouse-drag-tab-line) 3252(global-set-key [tab-line down-mouse-1] #'mouse-drag-tab-line)
3254(global-set-key [tab-line mouse-1] 'mouse-select-window) 3253(global-set-key [tab-line mouse-1] #'mouse-select-window)
3255;; (global-set-key [mode-line drag-mouse-1] 'mouse-select-window) 3254;; (global-set-key [mode-line drag-mouse-1] 'mouse-select-window)
3256(global-set-key [mode-line down-mouse-1] 'mouse-drag-mode-line) 3255(global-set-key [mode-line down-mouse-1] #'mouse-drag-mode-line)
3257(global-set-key [mode-line mouse-1] 'mouse-select-window) 3256(global-set-key [mode-line mouse-1] #'mouse-select-window)
3258(global-set-key [mode-line mouse-2] 'mouse-delete-other-windows) 3257(global-set-key [mode-line mouse-2] #'mouse-delete-other-windows)
3259(global-set-key [mode-line mouse-3] 'mouse-delete-window) 3258(global-set-key [mode-line mouse-3] #'mouse-delete-window)
3260(global-set-key [mode-line C-mouse-2] 'mouse-split-window-horizontally) 3259(global-set-key [mode-line C-mouse-2] #'mouse-split-window-horizontally)
3261(global-set-key [vertical-scroll-bar C-mouse-2] 'mouse-split-window-vertically) 3260(global-set-key [vertical-scroll-bar C-mouse-2] #'mouse-split-window-vertically)
3262(global-set-key [horizontal-scroll-bar C-mouse-2] 'mouse-split-window-horizontally) 3261(global-set-key [horizontal-scroll-bar C-mouse-2] #'mouse-split-window-horizontally)
3263(global-set-key [vertical-line down-mouse-1] 'mouse-drag-vertical-line) 3262(global-set-key [vertical-line down-mouse-1] #'mouse-drag-vertical-line)
3264(global-set-key [vertical-line mouse-1] 'mouse-select-window) 3263(global-set-key [vertical-line mouse-1] #'mouse-select-window)
3265(global-set-key [vertical-line C-mouse-2] 'mouse-split-window-vertically) 3264(global-set-key [vertical-line C-mouse-2] #'mouse-split-window-vertically)
3266(global-set-key [right-divider down-mouse-1] 'mouse-drag-vertical-line) 3265(global-set-key [right-divider down-mouse-1] #'mouse-drag-vertical-line)
3267(global-set-key [right-divider mouse-1] 'ignore) 3266(global-set-key [right-divider mouse-1] #'ignore)
3268(global-set-key [right-divider C-mouse-2] 'mouse-split-window-vertically) 3267(global-set-key [right-divider C-mouse-2] #'mouse-split-window-vertically)
3269(global-set-key [bottom-divider down-mouse-1] 'mouse-drag-mode-line) 3268(global-set-key [bottom-divider down-mouse-1] #'mouse-drag-mode-line)
3270(global-set-key [bottom-divider mouse-1] 'ignore) 3269(global-set-key [bottom-divider mouse-1] #'ignore)
3271(global-set-key [bottom-divider C-mouse-2] 'mouse-split-window-horizontally) 3270(global-set-key [bottom-divider C-mouse-2] #'mouse-split-window-horizontally)
3272(global-set-key [left-edge down-mouse-1] 'mouse-drag-left-edge) 3271(global-set-key [left-edge down-mouse-1] #'mouse-drag-left-edge)
3273(global-set-key [left-edge mouse-1] 'ignore) 3272(global-set-key [left-edge mouse-1] #'ignore)
3274(global-set-key [top-left-corner down-mouse-1] 'mouse-drag-top-left-corner) 3273(global-set-key [top-left-corner down-mouse-1] #'mouse-drag-top-left-corner)
3275(global-set-key [top-left-corner mouse-1] 'ignore) 3274(global-set-key [top-left-corner mouse-1] #'ignore)
3276(global-set-key [top-edge down-mouse-1] 'mouse-drag-top-edge) 3275(global-set-key [top-edge down-mouse-1] #'mouse-drag-top-edge)
3277(global-set-key [top-edge mouse-1] 'ignore) 3276(global-set-key [top-edge mouse-1] #'ignore)
3278(global-set-key [top-right-corner down-mouse-1] 'mouse-drag-top-right-corner) 3277(global-set-key [top-right-corner down-mouse-1] #'mouse-drag-top-right-corner)
3279(global-set-key [top-right-corner mouse-1] 'ignore) 3278(global-set-key [top-right-corner mouse-1] #'ignore)
3280(global-set-key [right-edge down-mouse-1] 'mouse-drag-right-edge) 3279(global-set-key [right-edge down-mouse-1] #'mouse-drag-right-edge)
3281(global-set-key [right-edge mouse-1] 'ignore) 3280(global-set-key [right-edge mouse-1] #'ignore)
3282(global-set-key [bottom-right-corner down-mouse-1] 'mouse-drag-bottom-right-corner) 3281(global-set-key [bottom-right-corner down-mouse-1] #'mouse-drag-bottom-right-corner)
3283(global-set-key [bottom-right-corner mouse-1] 'ignore) 3282(global-set-key [bottom-right-corner mouse-1] #'ignore)
3284(global-set-key [bottom-edge down-mouse-1] 'mouse-drag-bottom-edge) 3283(global-set-key [bottom-edge down-mouse-1] #'mouse-drag-bottom-edge)
3285(global-set-key [bottom-edge mouse-1] 'ignore) 3284(global-set-key [bottom-edge mouse-1] #'ignore)
3286(global-set-key [bottom-left-corner down-mouse-1] 'mouse-drag-bottom-left-corner) 3285(global-set-key [bottom-left-corner down-mouse-1] #'mouse-drag-bottom-left-corner)
3287(global-set-key [bottom-left-corner mouse-1] 'ignore) 3286(global-set-key [bottom-left-corner mouse-1] #'ignore)
3288 3287
3289(provide 'mouse) 3288(provide 'mouse)
3290 3289
diff --git a/lisp/net/browse-url.el b/lisp/net/browse-url.el
index 40b584f32cf..0273478cacf 100644
--- a/lisp/net/browse-url.el
+++ b/lisp/net/browse-url.el
@@ -38,7 +38,7 @@
38;; browse-url-firefox Firefox Don't know (tried with 1.0.1) 38;; browse-url-firefox Firefox Don't know (tried with 1.0.1)
39;; browse-url-chrome Chrome 47.0.2526.111 39;; browse-url-chrome Chrome 47.0.2526.111
40;; browse-url-chromium Chromium 3.0 40;; browse-url-chromium Chromium 3.0
41;; browse-url-epiphany Epiphany Don't know 41;; browse-url-epiphany GNOME Web (Epiphany) Don't know
42;; browse-url-webpositive WebPositive 1.2-alpha (Haiku R1/beta3) 42;; browse-url-webpositive WebPositive 1.2-alpha (Haiku R1/beta3)
43;; browse-url-w3 w3 0 43;; browse-url-w3 w3 0
44;; browse-url-text-* Any text browser 0 44;; browse-url-text-* Any text browser 0
@@ -156,7 +156,7 @@
156 (function-item :tag "Firefox" :value browse-url-firefox) 156 (function-item :tag "Firefox" :value browse-url-firefox)
157 (function-item :tag "Google Chrome" :value browse-url-chrome) 157 (function-item :tag "Google Chrome" :value browse-url-chrome)
158 (function-item :tag "Chromium" :value browse-url-chromium) 158 (function-item :tag "Chromium" :value browse-url-chromium)
159 (function-item :tag "Epiphany" :value browse-url-epiphany) 159 (function-item :tag "GNOME Web (Epiphany)" :value browse-url-epiphany)
160 (function-item :tag "WebPositive" :value browse-url-webpositive) 160 (function-item :tag "WebPositive" :value browse-url-webpositive)
161 (function-item :tag "Text browser in an xterm window" 161 (function-item :tag "Text browser in an xterm window"
162 :value browse-url-text-xterm) 162 :value browse-url-text-xterm)
@@ -305,15 +305,15 @@ Defaults to the value of `browse-url-firefox-arguments' at the time
305 :version "24.1") 305 :version "24.1")
306 306
307(defcustom browse-url-epiphany-program "epiphany" 307(defcustom browse-url-epiphany-program "epiphany"
308 "The name by which to invoke Epiphany." 308 "The name by which to invoke GNOME Web (Epiphany)."
309 :type 'string) 309 :type 'string)
310 310
311(defcustom browse-url-epiphany-arguments nil 311(defcustom browse-url-epiphany-arguments nil
312 "A list of strings to pass to Epiphany as arguments." 312 "A list of strings to pass to GNOME Web (Epiphany) as arguments."
313 :type '(repeat (string :tag "Argument"))) 313 :type '(repeat (string :tag "Argument")))
314 314
315(defcustom browse-url-epiphany-startup-arguments browse-url-epiphany-arguments 315(defcustom browse-url-epiphany-startup-arguments browse-url-epiphany-arguments
316 "A list of strings to pass to Epiphany when it starts up. 316 "A list of strings to pass to GNOME Web (Epiphany) when it starts up.
317Defaults to the value of `browse-url-epiphany-arguments' at the time 317Defaults to the value of `browse-url-epiphany-arguments' at the time
318`browse-url' is loaded." 318`browse-url' is loaded."
319 :type '(repeat (string :tag "Argument"))) 319 :type '(repeat (string :tag "Argument")))
@@ -1140,12 +1140,12 @@ The optional argument NEW-WINDOW is not used."
1140(function-put 'browse-url-chrome 'browse-url-browser-kind 'external) 1140(function-put 'browse-url-chrome 'browse-url-browser-kind 'external)
1141 1141
1142(defun browse-url-epiphany (url &optional new-window) 1142(defun browse-url-epiphany (url &optional new-window)
1143 "Ask the Epiphany WWW browser to load URL. 1143 "Ask the GNOME Web (Epiphany) WWW browser to load URL.
1144Default to the URL around or before point. The strings in variable 1144Default to the URL around or before point. The strings in variable
1145`browse-url-galeon-arguments' are also passed to Epiphany. 1145`browse-url-epiphany-arguments' are also passed to GNOME Web.
1146 1146
1147When called interactively, if variable `browse-url-new-window-flag' is 1147When called interactively, if variable `browse-url-new-window-flag' is
1148non-nil, load the document in a new Epiphany window, otherwise use a 1148non-nil, load the document in a new GNOME Web window, otherwise use a
1149random existing one. A non-nil interactive prefix argument reverses 1149random existing one. A non-nil interactive prefix argument reverses
1150the effect of `browse-url-new-window-flag'. 1150the effect of `browse-url-new-window-flag'.
1151 1151
@@ -1177,10 +1177,10 @@ used instead of `browse-url-new-window-flag'."
1177(function-put 'browse-url-epiphany 'browse-url-browser-kind 'external) 1177(function-put 'browse-url-epiphany 'browse-url-browser-kind 'external)
1178 1178
1179(defun browse-url-epiphany-sentinel (process url) 1179(defun browse-url-epiphany-sentinel (process url)
1180 "Handle a change to the process communicating with Epiphany." 1180 "Handle a change to the process communicating with GNOME Web (Epiphany)."
1181 (or (eq (process-exit-status process) 0) 1181 (or (eq (process-exit-status process) 0)
1182 (let* ((process-environment (browse-url-process-environment))) 1182 (let* ((process-environment (browse-url-process-environment)))
1183 ;; Epiphany is not running - start it 1183 ;; GNOME Web is not running - start it
1184 (message "Starting %s..." browse-url-epiphany-program) 1184 (message "Starting %s..." browse-url-epiphany-program)
1185 (apply #'start-process (concat "epiphany " url) nil 1185 (apply #'start-process (concat "epiphany " url) nil
1186 browse-url-epiphany-program 1186 browse-url-epiphany-program
diff --git a/lisp/net/newst-backend.el b/lisp/net/newst-backend.el
index efbff79d686..77e148047ae 100644
--- a/lisp/net/newst-backend.el
+++ b/lisp/net/newst-backend.el
@@ -1204,8 +1204,7 @@ URL `http://www.atompub.org/2005/08/17/draft-ietf-atompub-format-11.html'"
1204Return value as well as arguments NAME, TIME, and TOPNODE are the 1204Return value as well as arguments NAME, TIME, and TOPNODE are the
1205same as in `newsticker--parse-atom-1.0'. 1205same as in `newsticker--parse-atom-1.0'.
1206 1206
1207For the RSS 0.91 specification see URL `http://backend.userland.com/rss091' 1207For the RSS 0.91 specification see URL `http://backend.userland.com/rss091'."
1208or URL `http://my.netscape.com/publish/formats/rss-spec-0.91.html'."
1209 (newsticker--debug-msg "Parsing RSS 0.91 feed %s" name) 1208 (newsticker--debug-msg "Parsing RSS 0.91 feed %s" name)
1210 (let* ((channelnode (car (xml-get-children topnode 'channel))) 1209 (let* ((channelnode (car (xml-get-children topnode 'channel)))
1211 is-new-feed has-new-items) 1210 is-new-feed has-new-items)
diff --git a/lisp/net/newsticker.el b/lisp/net/newsticker.el
index 34e94acd12c..c1714218be9 100644
--- a/lisp/net/newsticker.el
+++ b/lisp/net/newsticker.el
@@ -43,8 +43,7 @@
43;; are contained in "RSS" (RDF Site Summary) or "Atom" files. Newsticker 43;; are contained in "RSS" (RDF Site Summary) or "Atom" files. Newsticker
44;; should work with the following RSS formats: 44;; should work with the following RSS formats:
45;; * RSS 0.91 45;; * RSS 0.91
46;; (see http://backend.userland.com/rss091 or 46;; (see http://backend.userland.com/rss091)
47;; http://my.netscape.com/publish/formats/rss-spec-0.91.html)
48;; * RSS 0.92 47;; * RSS 0.92
49;; (see http://backend.userland.com/rss092) 48;; (see http://backend.userland.com/rss092)
50;; * RSS 1.0 49;; * RSS 1.0
diff --git a/lisp/pixel-scroll.el b/lisp/pixel-scroll.el
index 6191c0530c4..94c14d50dca 100644
--- a/lisp/pixel-scroll.el
+++ b/lisp/pixel-scroll.el
@@ -141,17 +141,17 @@ Nil means to not interpolate such scrolls."
141 number) 141 number)
142 :version "29.1") 142 :version "29.1")
143 143
144(defcustom pixel-scroll-precision-interpolation-total-time 0.01 144(defcustom pixel-scroll-precision-interpolation-total-time 0.1
145 "The total time in seconds to spend interpolating a large scroll." 145 "The total time in seconds to spend interpolating a large scroll."
146 :group 'mouse 146 :group 'mouse
147 :type 'float 147 :type 'float
148 :version 29.1) 148 :version "29.1")
149 149
150(defcustom pixel-scroll-precision-interpolation-factor 2.0 150(defcustom pixel-scroll-precision-interpolation-factor 4.0
151 "A factor to apply to the distance of an interpolated scroll." 151 "A factor to apply to the distance of an interpolated scroll."
152 :group 'mouse 152 :group 'mouse
153 :type 'float 153 :type 'float
154 :version 29.1) 154 :version "29.1")
155 155
156(defun pixel-scroll-in-rush-p () 156(defun pixel-scroll-in-rush-p ()
157 "Return non-nil if next scroll should be non-smooth. 157 "Return non-nil if next scroll should be non-smooth.
@@ -544,20 +544,43 @@ animation."
544 (let ((percentage 0) 544 (let ((percentage 0)
545 (total-time pixel-scroll-precision-interpolation-total-time) 545 (total-time pixel-scroll-precision-interpolation-total-time)
546 (factor pixel-scroll-precision-interpolation-factor) 546 (factor pixel-scroll-precision-interpolation-factor)
547 (last-time (float-time))
547 (time-elapsed 0.0) 548 (time-elapsed 0.0)
548 (between-scroll 0.001)) 549 (between-scroll 0.001)
549 (while (< percentage 1) 550 (rem (window-parameter nil 'interpolated-scroll-remainder))
550 (sit-for between-scroll) 551 (time (window-parameter nil 'interpolated-scroll-remainder-time)))
551 (setq time-elapsed (+ time-elapsed between-scroll) 552 (when (and rem time
552 percentage (/ time-elapsed total-time)) 553 (< (- (float-time) time) 1.0)
553 (if (< delta 0) 554 (eq (< delta 0) (< rem 0)))
554 (pixel-scroll-precision-scroll-down 555 (setq delta (+ delta rem)))
555 (ceiling (abs (* (* delta factor) 556 (while-no-input
556 (/ between-scroll total-time))))) 557 (unwind-protect
557 (pixel-scroll-precision-scroll-up 558 (while (< percentage 1)
558 (ceiling (* (* delta factor) 559 (redisplay t)
559 (/ between-scroll total-time))))) 560 (sleep-for between-scroll)
560 (redisplay t)))) 561 (setq time-elapsed (+ time-elapsed
562 (- (float-time) last-time))
563 percentage (/ time-elapsed total-time))
564 (if (< delta 0)
565 (pixel-scroll-precision-scroll-down
566 (ceiling (abs (* (* delta factor)
567 (/ between-scroll total-time)))))
568 (pixel-scroll-precision-scroll-up
569 (ceiling (* (* delta factor)
570 (/ between-scroll total-time)))))
571 (setq last-time (float-time)))
572 (if (< percentage 1)
573 (progn
574 (set-window-parameter nil 'interpolated-scroll-remainder
575 (* delta (- 1 percentage)))
576 (set-window-parameter nil 'interpolated-scroll-remainder-time
577 (float-time)))
578 (set-window-parameter nil
579 'interpolated-scroll-remainder
580 nil)
581 (set-window-parameter nil
582 'interpolated-scroll-remainder-time
583 nil))))))
561 584
562(defun pixel-scroll-precision-scroll-up (delta) 585(defun pixel-scroll-precision-scroll-up (delta)
563 "Scroll the current window up by DELTA pixels." 586 "Scroll the current window up by DELTA pixels."
diff --git a/lisp/progmodes/ebrowse.el b/lisp/progmodes/ebrowse.el
index 6e416d064a8..0713370da3c 100644
--- a/lisp/progmodes/ebrowse.el
+++ b/lisp/progmodes/ebrowse.el
@@ -4045,23 +4045,27 @@ NUMBER-OF-STATIC-VARIABLES:"
4045(defvar ebrowse-global-map nil 4045(defvar ebrowse-global-map nil
4046 "Keymap for Ebrowse commands.") 4046 "Keymap for Ebrowse commands.")
4047 4047
4048
4049(defvar ebrowse-global-prefix-key "\C-c\C-m" 4048(defvar ebrowse-global-prefix-key "\C-c\C-m"
4050 "Prefix key for Ebrowse commands.") 4049 "Prefix key for Ebrowse commands.")
4051 4050
4052 4051(defvar-keymap ebrowse-global-submap-4
4053(defvar ebrowse-global-submap-4 nil 4052 :doc "Keymap used for `ebrowse-global-prefix' followed by `4'."
4054 "Keymap used for `ebrowse-global-prefix' followed by `4'.") 4053 "." #'ebrowse-tags-find-definition-other-window
4055 4054 "f" #'ebrowse-tags-find-definition-other-window
4056 4055 "v" #'ebrowse-tags-find-declaration-other-window
4057(defvar ebrowse-global-submap-5 nil 4056 "F" #'ebrowse-tags-view-definition-other-window
4058 "Keymap used for `ebrowse-global-prefix' followed by `5'.") 4057 "V" #'ebrowse-tags-view-declaration-other-window)
4059 4058
4059(defvar-keymap ebrowse-global-submap-5
4060 :doc "Keymap used for `ebrowse-global-prefix' followed by `5'."
4061 "." #'ebrowse-tags-find-definition-other-frame
4062 "f" #'ebrowse-tags-find-definition-other-frame
4063 "v" #'ebrowse-tags-find-declaration-other-frame
4064 "F" #'ebrowse-tags-view-definition-other-frame
4065 "V" #'ebrowse-tags-view-declaration-other-frame)
4060 4066
4061(unless ebrowse-global-map 4067(unless ebrowse-global-map
4062 (setq ebrowse-global-map (make-sparse-keymap)) 4068 (setq ebrowse-global-map (make-sparse-keymap))
4063 (setq ebrowse-global-submap-4 (make-sparse-keymap))
4064 (setq ebrowse-global-submap-5 (make-sparse-keymap))
4065 (define-key ebrowse-global-map "a" 'ebrowse-tags-apropos) 4069 (define-key ebrowse-global-map "a" 'ebrowse-tags-apropos)
4066 (define-key ebrowse-global-map "b" 'ebrowse-pop-to-browser-buffer) 4070 (define-key ebrowse-global-map "b" 'ebrowse-pop-to-browser-buffer)
4067 (define-key ebrowse-global-map "-" 'ebrowse-back-in-position-stack) 4071 (define-key ebrowse-global-map "-" 'ebrowse-back-in-position-stack)
@@ -4082,17 +4086,7 @@ NUMBER-OF-STATIC-VARIABLES:"
4082 (define-key ebrowse-global-map " " 'ebrowse-electric-buffer-list) 4086 (define-key ebrowse-global-map " " 'ebrowse-electric-buffer-list)
4083 (define-key ebrowse-global-map "\t" 'ebrowse-tags-complete-symbol) 4087 (define-key ebrowse-global-map "\t" 'ebrowse-tags-complete-symbol)
4084 (define-key ebrowse-global-map "4" ebrowse-global-submap-4) 4088 (define-key ebrowse-global-map "4" ebrowse-global-submap-4)
4085 (define-key ebrowse-global-submap-4 "." 'ebrowse-tags-find-definition-other-window)
4086 (define-key ebrowse-global-submap-4 "f" 'ebrowse-tags-find-definition-other-window)
4087 (define-key ebrowse-global-submap-4 "v" 'ebrowse-tags-find-declaration-other-window)
4088 (define-key ebrowse-global-submap-4 "F" 'ebrowse-tags-view-definition-other-window)
4089 (define-key ebrowse-global-submap-4 "V" 'ebrowse-tags-view-declaration-other-window)
4090 (define-key ebrowse-global-map "5" ebrowse-global-submap-5) 4089 (define-key ebrowse-global-map "5" ebrowse-global-submap-5)
4091 (define-key ebrowse-global-submap-5 "." 'ebrowse-tags-find-definition-other-frame)
4092 (define-key ebrowse-global-submap-5 "f" 'ebrowse-tags-find-definition-other-frame)
4093 (define-key ebrowse-global-submap-5 "v" 'ebrowse-tags-find-declaration-other-frame)
4094 (define-key ebrowse-global-submap-5 "F" 'ebrowse-tags-view-definition-other-frame)
4095 (define-key ebrowse-global-submap-5 "V" 'ebrowse-tags-view-declaration-other-frame)
4096 (define-key global-map ebrowse-global-prefix-key ebrowse-global-map)) 4090 (define-key global-map ebrowse-global-prefix-key ebrowse-global-map))
4097 4091
4098 4092
diff --git a/lisp/speedbar.el b/lisp/speedbar.el
index 3cc3e276067..cfa96608bff 100644
--- a/lisp/speedbar.el
+++ b/lisp/speedbar.el
@@ -3694,27 +3694,21 @@ regular expression EXPR."
3694 3694
3695;;; BUFFER DISPLAY mode. 3695;;; BUFFER DISPLAY mode.
3696;; 3696;;
3697(defvar speedbar-buffers-key-map nil 3697(defvar speedbar-buffers-key-map
3698 (let ((map (speedbar-make-specialized-keymap)))
3699 ;; Basic tree features
3700 (define-key map "e" #'speedbar-edit-line)
3701 (define-key map "\C-m" #'speedbar-edit-line)
3702 (define-key map "+" #'speedbar-expand-line)
3703 (define-key map "=" #'speedbar-expand-line)
3704 (define-key map "-" #'speedbar-contract-line)
3705 (define-key map " " #'speedbar-toggle-line-expansion)
3706 ;; Buffer specific keybindings
3707 (define-key map "k" #'speedbar-buffer-kill-buffer)
3708 (define-key map "r" #'speedbar-buffer-revert-buffer)
3709 map)
3698 "Keymap used when in the buffers display mode.") 3710 "Keymap used when in the buffers display mode.")
3699 3711
3700(if speedbar-buffers-key-map
3701 nil
3702 (setq speedbar-buffers-key-map (speedbar-make-specialized-keymap))
3703
3704 ;; Basic tree features
3705 (define-key speedbar-buffers-key-map "e" 'speedbar-edit-line)
3706 (define-key speedbar-buffers-key-map "\C-m" 'speedbar-edit-line)
3707 (define-key speedbar-buffers-key-map "+" 'speedbar-expand-line)
3708 (define-key speedbar-buffers-key-map "=" 'speedbar-expand-line)
3709 (define-key speedbar-buffers-key-map "-" 'speedbar-contract-line)
3710 (define-key speedbar-buffers-key-map " " 'speedbar-toggle-line-expansion)
3711
3712 ;; Buffer specific keybindings
3713 (define-key speedbar-buffers-key-map "k" 'speedbar-buffer-kill-buffer)
3714 (define-key speedbar-buffers-key-map "r" 'speedbar-buffer-revert-buffer)
3715
3716 )
3717
3718(defvar speedbar-buffer-easymenu-definition 3712(defvar speedbar-buffer-easymenu-definition
3719 '(["Jump to buffer" speedbar-edit-line t] 3713 '(["Jump to buffer" speedbar-edit-line t]
3720 ["Expand File Tags" speedbar-expand-line 3714 ["Expand File Tags" speedbar-expand-line
diff --git a/src/nsterm.m b/src/nsterm.m
index 5c19b0cab82..5d39be3a870 100644
--- a/src/nsterm.m
+++ b/src/nsterm.m
@@ -6658,8 +6658,10 @@ not_in_argv (NSString *arg)
6658 ? ceil (fabs (delta)) : 1; 6658 ? ceil (fabs (delta)) : 1;
6659 6659
6660 scrollUp = delta > 0; 6660 scrollUp = delta > 0;
6661 x = [theEvent scrollingDeltaX]; 6661 x = ([theEvent scrollingDeltaX]
6662 y = [theEvent scrollingDeltaY]; 6662 * FRAME_COLUMN_WIDTH (emacsframe));
6663 y = ([theEvent scrollingDeltaY]
6664 * FRAME_LINE_HEIGHT (emacsframe));
6663 } 6665 }
6664 6666
6665 if (lines == 0 && mwheel_coalesce_scroll_events) 6667 if (lines == 0 && mwheel_coalesce_scroll_events)
diff --git a/test/lisp/emacs-lisp/cl-macs-tests.el b/test/lisp/emacs-lisp/cl-macs-tests.el
index 7c3afefaadd..13da60ec45e 100644
--- a/test/lisp/emacs-lisp/cl-macs-tests.el
+++ b/test/lisp/emacs-lisp/cl-macs-tests.el
@@ -668,13 +668,13 @@ collection clause."
668 #'len)) 668 #'len))
669 (`(function (lambda (,_ ,_) . ,_)) t)))) 669 (`(function (lambda (,_ ,_) . ,_)) t))))
670 670
671(with-suppressed-warnings ((lexical test) (lexical test1) (lexical test2))
672 (defvar test)
673 (defvar test1)
674 (defvar test2))
675(ert-deftest cl-macs--progv () 671(ert-deftest cl-macs--progv ()
676 (should (= (cl-progv '(test test) '(1 2) test) 2)) 672 (defvar cl-macs--test)
677 (should (equal (cl-progv '(test1 test2) '(1 2) (list test1 test2)) 673 (defvar cl-macs--test1)
674 (defvar cl-macs--test2)
675 (should (= (cl-progv '(cl-macs--test cl-macs--test) '(1 2) cl-macs--test) 2))
676 (should (equal (cl-progv '(cl-macs--test1 cl-macs--test2) '(1 2)
677 (list cl-macs--test1 cl-macs--test2))
678 '(1 2)))) 678 '(1 2))))
679 679
680;;; cl-macs-tests.el ends here 680;;; cl-macs-tests.el ends here
diff --git a/test/lisp/emacs-lisp/subr-x-tests.el b/test/lisp/emacs-lisp/subr-x-tests.el
index d8369506000..821b6770ba0 100644
--- a/test/lisp/emacs-lisp/subr-x-tests.el
+++ b/test/lisp/emacs-lisp/subr-x-tests.el
@@ -676,7 +676,7 @@
676 (buffer-string)) 676 (buffer-string))
677 "foo\n"))) 677 "foo\n")))
678 678
679(ert-deftest test-add-display-text-property () 679(ert-deftest subr-x-test-add-display-text-property ()
680 (with-temp-buffer 680 (with-temp-buffer
681 (insert "Foo bar zot gazonk") 681 (insert "Foo bar zot gazonk")
682 (add-display-text-property 4 8 'height 2.0) 682 (add-display-text-property 4 8 'height 2.0)
@@ -694,5 +694,23 @@
694 [(raise 0.5) (height 2.0)])) 694 [(raise 0.5) (height 2.0)]))
695 (should (equal (get-text-property 9 'display) '(raise 0.5))))) 695 (should (equal (get-text-property 9 'display) '(raise 0.5)))))
696 696
697(ert-deftest subr-x-named-let ()
698 (let ((funs ()))
699 (named-let loop
700 ((rest '(1 42 3))
701 (sum 0))
702 (when rest
703 ;; Here, we make sure that the variables are distinct in every
704 ;; iteration, since a naive tail-call optimization would tend to end up
705 ;; with a single `sum' variable being shared by all the closures.
706 (push (lambda () sum) funs)
707 ;; Here we add a dummy `sum' variable which shadows the `sum' iteration
708 ;; variable since a naive tail-call optimization could also trip here
709 ;; thinking it can `(setq sum ...)' to set the iteration
710 ;; variable's value.
711 (let ((sum sum))
712 (loop (cdr rest) (+ sum (car rest))))))
713 (should (equal (mapcar #'funcall funs) '(43 1 0)))))
714
697(provide 'subr-x-tests) 715(provide 'subr-x-tests)
698;;; subr-x-tests.el ends here 716;;; subr-x-tests.el ends here