mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-06-14 04:21:24 +00:00
Merge branch 'master' of git.sv.gnu.org:/srv/git/emacs
This commit is contained in:
commit
247f46d5e4
8 changed files with 71 additions and 43 deletions
|
|
@ -16979,11 +16979,10 @@ The command invoked by the keys is @code{compare-windows}. Note that
|
|||
@code{compare-windows} is preceded by a single-quote; otherwise, Emacs
|
||||
would first try to evaluate the symbol to determine its value.
|
||||
|
||||
These three things, the double quotation marks, the backslash before
|
||||
the @samp{C}, and the single-quote are necessary parts of
|
||||
key binding that I tend to forget. Fortunately, I have come to
|
||||
remember that I should look at my existing @file{.emacs} file, and
|
||||
adapt what is there.
|
||||
These two things, the double quotation marks and the single-quote, are
|
||||
necessary parts of key binding that I tend to forget. Fortunately, I
|
||||
have come to remember that I should look at my existing @file{.emacs}
|
||||
file, and adapt what is there.
|
||||
|
||||
As for the key binding itself: @kbd{C-c w}. This combines the prefix
|
||||
key, @kbd{C-c}, with a single character, in this case, @kbd{w}. This
|
||||
|
|
|
|||
14
etc/NEWS
14
etc/NEWS
|
|
@ -4520,9 +4520,17 @@ singleton list.
|
|||
---
|
||||
** Support macOS Accessibility Zoom focus tracking.
|
||||
This is an important change for visually-impaired users. If macOS
|
||||
Accessibility Zoom is enabled (System Settings, Accessibility, Zoom)
|
||||
with keyboard focus tracking (Advanced...), Zoom is informed of updated
|
||||
cursor positions during each redisplay cycle.
|
||||
Accessibility Zoom is enabled via (System Settings, Accessibility,
|
||||
Zoom...) with keyboard focus tracking (Advanced...), Zoom is informed
|
||||
of updated cursor positions during each redisplay cycle.
|
||||
|
||||
---
|
||||
** New macOS function 'ns-process-is-accessibility-trusted'.
|
||||
This function returns t if the macOS Accessibility Framework trusts the
|
||||
Emacs. This is a necessary condition for Accessibility Zoom and other
|
||||
accessibility features. Enable Emacs via (System Settings, Privacy &
|
||||
Security, Accessibility...) and add the Emacs.app installed directory to
|
||||
the enabled application list.
|
||||
|
||||
---
|
||||
** Process execution has been optimized on Android.
|
||||
|
|
|
|||
|
|
@ -774,7 +774,9 @@ be used instead.
|
|||
;; be any need to font-lock-flush all the Elisp buffers.
|
||||
(dolist (buf (buffer-list))
|
||||
(with-current-buffer buf
|
||||
(when (derived-mode-p 'emacs-lisp-mode)
|
||||
(when (and (derived-mode-p 'emacs-lisp-mode)
|
||||
;; Don't flush if it refontifies the whole buffer eagerly.
|
||||
font-lock-support-mode)
|
||||
;; So as to take into account new macros that may have been defined
|
||||
;; by the just-loaded file.
|
||||
(font-lock-flush))))))
|
||||
|
|
@ -868,29 +870,30 @@ use of `macroexpand-all' as a way to find the \"underlying raw code\".")
|
|||
|
||||
(defun elisp--local-variables ()
|
||||
"Return a list of locally let-bound variables at point."
|
||||
(save-excursion
|
||||
(skip-syntax-backward "w_")
|
||||
(let* ((ppss (syntax-ppss))
|
||||
(txt (buffer-substring-no-properties (or (car (nth 9 ppss)) (point))
|
||||
(or (nth 8 ppss) (point))))
|
||||
(closer ()))
|
||||
(dolist (p (nth 9 ppss))
|
||||
(push (cdr (syntax-after p)) closer))
|
||||
(setq closer (apply #'string closer))
|
||||
(let* ((sexp (condition-case nil
|
||||
(car (read-from-string
|
||||
(concat txt "elisp--witness--lisp" closer)))
|
||||
((invalid-read-syntax end-of-file) nil)))
|
||||
(vars (elisp--local-variables-1
|
||||
nil (elisp--safe-macroexpand-all sexp))))
|
||||
(delq nil
|
||||
(mapcar (lambda (var)
|
||||
(and (symbolp var)
|
||||
(not (string-match (symbol-name var) "\\`[&_]"))
|
||||
;; Eliminate uninterned vars.
|
||||
(intern-soft var)
|
||||
var))
|
||||
vars))))))
|
||||
(let* ((sexp
|
||||
(save-excursion
|
||||
(skip-syntax-backward "w_")
|
||||
(let* ((ppss (syntax-ppss))
|
||||
(txt (buffer-substring-no-properties
|
||||
(or (car (nth 9 ppss)) (point))
|
||||
(or (nth 8 ppss) (point))))
|
||||
(closer
|
||||
(nreverse (mapcar (lambda (p) (cdr (syntax-after p)))
|
||||
(nth 9 ppss)))))
|
||||
(condition-case nil
|
||||
(car (read-from-string
|
||||
(concat txt "elisp--witness--lisp" closer)))
|
||||
((invalid-read-syntax end-of-file) nil)))))
|
||||
(vars (elisp--local-variables-1
|
||||
nil (elisp--safe-macroexpand-all sexp))))
|
||||
(delq nil
|
||||
(mapcar (lambda (var)
|
||||
(and (symbolp var)
|
||||
(not (string-match (symbol-name var) "\\`[&_]"))
|
||||
;; Eliminate uninterned vars.
|
||||
(intern-soft var)
|
||||
var))
|
||||
vars))))
|
||||
|
||||
(defconst elisp--local-variables-completion-table
|
||||
(let ((lastpos nil) (lastvars nil))
|
||||
|
|
|
|||
|
|
@ -1806,7 +1806,7 @@ See also `current-global-map'.")
|
|||
(defun listify-key-sequence (key)
|
||||
"Convert a key sequence to a list of events."
|
||||
(declare (side-effect-free t))
|
||||
(if (vectorp key)
|
||||
(if (or (vectorp key) (multibyte-string-p key))
|
||||
(append key nil)
|
||||
(mapcar (lambda (c)
|
||||
(if (> c 127)
|
||||
|
|
|
|||
|
|
@ -1276,7 +1276,7 @@ Return the result of evaluating FORM."
|
|||
(dolist (file ,flist)
|
||||
(dolist (setting ,settings)
|
||||
(let ((property (car setting)))
|
||||
(unless (memq property ,vc-touched-properties)
|
||||
(unless (memq property vc-touched-properties)
|
||||
(put (intern file vc-file-prop-obarray)
|
||||
property (cdr setting))))))))))
|
||||
|
||||
|
|
@ -2230,7 +2230,8 @@ have changed; continue with old fileset?" (current-buffer))))
|
|||
(dolist (file files)
|
||||
(let ((file (expand-file-name file)))
|
||||
(vc-file-setprop file 'display-state "committing")
|
||||
(vc-dir-resynch-file file)
|
||||
(when vc-dir-buffers
|
||||
(vc-dir-resynch-file file))
|
||||
(push file to-remove-props)))
|
||||
(vc-exec-after #'remove-props-done-msg nil proc))
|
||||
ret)
|
||||
|
|
|
|||
22
src/nsfns.m
22
src/nsfns.m
|
|
@ -3755,6 +3755,27 @@ The position is returned as a cons cell (X . Y) of the
|
|||
return Qnil;
|
||||
}
|
||||
|
||||
|
||||
DEFUN ("ns-process-is-accessibility-trusted",
|
||||
Fns_process_is_accessibility_trusted,
|
||||
Sns_process_is_accessibility_trusted,
|
||||
0, 0, 0,
|
||||
doc: /* Return non-nil if Emacs is trusted by macOS Accessibility.
|
||||
Return nil otherwise or if the OS is not macOS.
|
||||
This is necessary for Emacs to support Zoom and related accessibility
|
||||
features. Authorize Emacs for accessibility via System
|
||||
Settings... Privacy & Security... Accessibility... and add the Emacs.app
|
||||
installed directory to the enabled application list. */)
|
||||
(void)
|
||||
{
|
||||
#ifdef NS_IMPL_COCOA
|
||||
if (AXIsProcessTrusted())
|
||||
return Qt;
|
||||
#endif
|
||||
return Qnil;
|
||||
}
|
||||
|
||||
|
||||
DEFUN ("ns-badge", Fns_badge, Sns_badge, 1, 1, 0,
|
||||
doc: /* Set the app icon badge to BADGE.
|
||||
BADGE should be a string short enough to display nicely in the short
|
||||
|
|
@ -4248,6 +4269,7 @@ - (Lisp_Object)lispString
|
|||
defsubr (&Sns_set_mouse_absolute_pixel_position);
|
||||
defsubr (&Sns_mouse_absolute_pixel_position);
|
||||
defsubr (&Sns_show_character_palette);
|
||||
defsubr (&Sns_process_is_accessibility_trusted);
|
||||
defsubr (&Sns_badge);
|
||||
defsubr (&Sns_request_user_attention);
|
||||
defsubr (&Sns_progress_indicator);
|
||||
|
|
|
|||
|
|
@ -6517,14 +6517,6 @@ - (void)applicationDidFinishLaunching: (NSNotification *)notification
|
|||
}
|
||||
#endif
|
||||
|
||||
#ifdef NS_IMPL_COCOA
|
||||
/* Is accessibility enabled for this process/bundle? */
|
||||
if (AXIsProcessTrusted())
|
||||
NSLog (@"Emacs is macOS AXIsProcessTrusted");
|
||||
else
|
||||
NSLog (@"Emacs is not macOS AXIsProcessTrusted");
|
||||
#endif
|
||||
|
||||
ns_send_appdefined (-2);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -433,6 +433,9 @@
|
|||
(should (eq (global-key-binding "x") 'self-insert-command))
|
||||
(should-not (global-key-binding [f12])))
|
||||
|
||||
(ert-deftest subr-listify-key-sequence ()
|
||||
(should (equal (listify-key-sequence "ŕ°") '(?ŕ ?°))))
|
||||
|
||||
|
||||
;;;; Mode hooks.
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue