aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPo Lu2024-06-30 23:12:09 +0800
committerPo Lu2024-06-30 23:12:09 +0800
commit7c8d4e96ba6db19bdca20a87bafed024a84eb517 (patch)
treefbab938bf8f25d5634912a58260f9d1c517d6737
parent7f89fe8a342d7b4e8800d0ef333fb6759b58ccb5 (diff)
parent64851d101a854e00c68f3e9259d70777e7b26cb2 (diff)
downloademacs-7c8d4e96ba6db19bdca20a87bafed024a84eb517.tar.gz
emacs-7c8d4e96ba6db19bdca20a87bafed024a84eb517.zip
Merge from savannah/emacs-30
64851d101a8 Improve Android "adaptive icon" 9b294059d71 Fix documentation for Emacs 30 f50167ab95e ; Update NEWS and corresponding manuals 4e22ef870c4 Add D-Bus test f784d946d44 ; Repair corruption in etc/DEBUG c750fbb539e ; * etc/DEBUG: Advice for debugging Emacs on OpenBSD (bug... 38179f85f8f Merge remote-tracking branch 'savannah/scratch/windows-98... 72cf9964f3c Inaccuracy in efaq.texi fc48e9e8ed5 ; Fix typos in DOS Makefile scripts 9b8d754579f ; * etc/NEWS: Explain Nextstep. 8819e5a45d5 Fix treesit crash (bug#71681) eaf2dc96c1f ; Fix SHR test on MS-Windows 57880f597c5 Delete redundant mention of `with-eval-after-load' ea8ce984342 * doc/misc/efaq.texi (New in Emacs 30): Fix typos. 45a20d781a9 ; Fix typos in symbols d95f039af43 Document security fixes in FAQ d063af203c8 Add "New in Emacs 30" to FAQ ca6b484162b ; * etc/NEWS: Move "Minibuffer and Completions" 35c46663e49 ; * etc/NEWS: Move item to "Lisp Changes". 0515b38d289 ; * etc/NEWS: Move keyboard macro items closer together. 22af3a71039 ; * etc/NEWS: More copy-edits. 000ef8876ae ; * etc/NEWS: Move items to "Incompatible Lisp Changes". 4088dc8e4ce ; * etc/NEWS: Rearrange "Incompatible Lisp Changes". 179800f36bb ; * lisp/epg.el (epg--start): Add commentary about encoding. 73898f0214c Fix non-ASCII filename operatiion on EasyPG (bug#71500) a65b6aac6b5 Silence warning with global minor mode :predicate f5f7343ac41 ; * etc/NEWS: Move an item to "Startup Changes" c95066bf188 ; * etc/NEWS: Move some Lisp items to better place. bf7db88ce1f ; * etc/NEWS: Rearrange "Editing Changes in Emacs 30.1" 000424eb9eb ; * etc/NEWS: Make touch screen support more prominent. 5b5671587fb ; * etc/NEWS: Rearrange "Changes in Emacs 30.1". 31124abdefe ; * lisp/thingatpt.el (sexp-at-point): Doc fix (bug#71777). 44f269d6e60 Fix: make 'xwidget-webkit-scroll-backward' scroll backwards 358085997c6 Merge branch 'emacs-30' of git.savannah.gnu.org:/srv/git/... 736b7cad406 Add jsdoc support to php-ts-mode in <script> element 5f3d964e397 Update to Transient v0.7.2-4-gf75bc48d 2d8881d5267 Fix typo incurring leaks of face structures 219501dd629 ; Fix use of @footnote in cc-mode.texi c7be2dcac44 Merge branch 'emacs-30' of git.sv.gnu.org:/srv/git/emacs ... f0a48799756 Sync with Tramp 2.7.1 53dcf2b9492 ; * etc/NEWS: Move the mwheel entry to a better place. a5726782d03 ; Sort tree-sitter modes in NEWS daa89dc939e ; * etc/NEWS: Rearrange "New Modes and Packages in Emacs ... 4ddbf4f70ef ; * etc/NEWS: Move many items. 437b1ced268 ; * etc/NEWS: Copy-edits. 7372b2eb302 Expand docstring of which-key-mode df0eb5be1ea Improve documentation of 'remove-overlays' in ELisp manual 73c1252bb6b Fix link to major mode variable in docstring c4ad54812ac Make `shell-mode' more robust c4ec905c9a9 Correct ommissions in rmc.el bf862fc2770 * lisp/hi-lock.el: More fixes related to revert-buffer. 6cc8ffae9a6 Update to Org 9.7.5-9-ga091ca c477443ab80 ; Fix typo in lua-ts-mode.el 6e5e4d61939 ; Add 'eglot-ensure' option to 'lua-ts-mode-hook' 58a2f36a8b9 ; * etc/NEWS: Copy edit. df53ef176ac Merge branch 'emacs-30' of git.savannah.gnu.org:/srv/git/... 039e6ffd866 Write Antinews for Emacs 30 ELisp Reference bf8c9f702ba (eval-last-sexp): Fix bug#71774 6d94090cadc * lisp/hi-lock.el: More fixes for revert-buffer (bug#57534) 280c91782af * lisp/hi-lock.el (hi-lock-revert-buffer-rehighlight): Im... 339310d0205 * lisp/tab-bar.el (tab-bar-select-restore-windows): Impro... c1e7569a925 Write Antinews for Emacs 30 user manual 233f683da8f ; * lisp/erc/erc-backend.el (erc-server-reconnect-timeout... 20a672b3b2b Change ERC version for Emacs 30 to 5.6.0.30.1 cbede3d43df * src/w32uniscribe.c (syms_of_w32uniscribe_for_pdumper): ... 6f9f9a21555 Fix two tests for --without-all build 98daa10f065 ; * etc/PROBLEMS (PGTK): Remove redundant 2nd PGTK section. ced33bc2397 Fix handling of non-nil 'dired-movement-style' b1e9b6fd67d ; * lisp/gnus/message.el (message-idna-to-ascii-rhs): Doc... 5eb9a0d2c79 ; * etc/NEWS: Fix last change (bug#71720). 6ec77f580dd Do not prematurely truncate python eldoc string f475a1a2544 ; Fix simple-tests as fallout of last change aa10d0c5ac1 Add tests for `kill-whole-line' (bug#65734) 058bb4ca25a kill-whole-line: Honor visibility; fix kill-ring when rea... e45173d114e * lisp/hi-lock.el (hi-lock-file-patterns-policy): Add val... d6afb017deb * lisp/progmodes/xref.el (xref-revert-buffer-restore-poin... 8d55b38e2a1 Fix Cygwin build 82125b1a661 Use 'revert-function' in *xref* buffer 860840621a1 Prevent crashes and related issues if initial activity is... d5c6eb1f964 Doc fix in 'php-ts-mode' fb15affde8c Avoid compiler warnings in the Cygwin-w32 build 8d354925ddb Add new face 'widget-unselected' to wid-edit.el 1809f6a93ef Always perform Eshell process cleanup runs in the Eshell ... 8b1841021c0 Avert crash in store_mode_line_string on Android 5.0 and ... e7c85f9235a Use HarfBuzz in Cygwin-w32 build 8e3e206bd32 ; * src/buffer.c (syms_of_buffer) <mode-line-format>: ASC... fe0d9dfb3b1 ; * lisp/treesit.el (treesit--syntax-propertize-start): F... 2f18929319a Fix tabbing between widgets (bug#70594) 6ad6507532b ; * lisp/which-key.el (which-key-dont-use-unicode): Add :... 60b38c317bb * lisp/touch-screen.el (touch-screen-inhibit-drag): Anoth... a4ca30ac2e0 Fix rescaling of images via 'text-scale-mode' in EWW 0e43606b20d * lisp/touch-screen.el (touch-screen-inhibit-drag): Fix t... 1b4c5627211 Fix latent side-effects of respecting field boundaries in... e4046f33ab8 ; * lisp/simple.el (undo-auto--boundaries): Doc fix (bug#... 008eeb21fdb ; * lisp/language/cyrillic.el: Delete obsolete commentary... 680155d3f03 Add missing builtin package declarations ce4f56caf71 Extend treesitter tests on emba 7e8a97ac788 Show entries from key-translation-map in which-key mode 4a0958642d9 * lisp/tab-bar.el (tab-bar-tab-group-face-function): Impr... a769f171e7e ; Fix flymake tests with GCC 14. 96e27c2ecf9 Don't show char name for multi-char translations 0715abfa86a Reset ls-lisp-use-string-collate when ls-lisp-emulation c... 4fcc38966bf Update to Transient v0.7.2-1-gf273c0c8 b7d5ca3a8fb * doc/misc/calc.texi (Musical Notes): Fix typo. 164f75822b2 ; Fix typos 768e92b9c02 Update options that depend on 'which-key-dont-use-unicode' 4b2682b17cd ; Remove debugging message in Completion Preview test 73a58329a69 Fix omission of updates to child frames on Android 0edacf2aa7e Add jsdoc support to js-ts-mode cace0cbee93 ; Restore inadvertently removed line. 2b04effb13d ; * test/lisp/net/shr-tests.el (shr-test--rendering-check... 6619aec6bca ; Don't run new 'shr-test/zoom-image' when built without ... 5d19bfda321 ; * admin/release-branch.txt: Update and fix typo. fb11294d415 ; Fix typos d9bd1718f9a Backport: Minor changes in tramp-tests.el 1728de5a776 Backport: Tramp: Fix bug#71709, and other minor changes dd0fc6aff60 New branch emacs-30 bc72c33ac38 * admin/admin.el: (set-version): Fix regexp for configure... 60475a73d17 Disable Ffile_system_info for Android special directories 18e7a9f3d0c Restore functionality on Windows 98 5f8a9cd4b6f Fix a bug in 'switch-to-buffer' 5f9b5803bea Fix zooming images in SHR 6f2036243f2 ; Doc fix in 'php-ts-mode'. 2f1c882a16e Colorize CSS property value like `css--fontify-region' dd0994aa36c Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs 486ea8ef5ac * configure.ac: Disable kqueue on Haiku. 737fa7c5292 Fix 'Customize' menu entry for 'php-ts-mode' cb7be6035ee Fix compilation on prerelease versions of Haiku 2b848a4e504 Fix FIXME in comment 77e3a56507d Update SKK-JISYO.L from upstream e5bae788614 Update publicsuffix.txt from upstream bf5f74288b7 Add assignment form as `etc/copyright-assign.txt` fcd37988048 ; Merge from origin/emacs-29 0f01cb0ebd1 Bump Emacs version to 29.4.50 014aab9847a Fix for grammar change of keyword "virtual" in tree-sitte... fa364a0d469 Revert "; * etc/HISTORY: Delete never-released Emacs 28.3." a81417e5766 Update Tramp version (don't merge to master) ff389163ee8 Manually merge NEWS.29 from emacs-29 ea057131220 ; * etc/HISTORY: Delete never-released Emacs 28.3. d3469978b89 Merge from origin/emacs-29 3739342a4e9 ; Merge from origin/emacs-29 38e738a35eb Merge from origin/emacs-29 4c4c94fa105 ; Merge from origin/emacs-29 1313b8966ae Merge from origin/emacs-29 4a76af51bb6 Replace literal whitespace with `\s` e41dd2241f7 ; Merge from origin/emacs-29 8520ec829d3 ; * lisp/editorconfig.el (editorconfig-indentation-alist)... 99161fb7140 Fix non-existing `editorconfig-set-indentation-python-mode` fd15d89ec51 Merge remote-tracking branch 'origin/emacs-29' into emacs-29 6a299b3cace Release Emacs 29.4 3f3c08bcc76 Add before-save-hook to man page files 7b0e6cb3ffa Use UTC when generating man page timestamps a7cb642a9fc Merge from origin/emacs-29 6491d11b53a ; Merge from origin/emacs-29 2f39a4b28a9 Merge from origin/emacs-29 150e2b979c1 ; * src/xfns.c (unwind_create_frame): Add missing definit... 75fdeef7b49 Allow to expand truncated long lines in *Compilation* buf... fb1b188e1ad Eglot: Fix command execution (bug#71642) 155cc89de02 Support for indentation of PHP alternative syntax control... 7f7b28a2500 ; Wayland SECONDARY selection problem 11fb3510f48 Prevent auto-revert when deleting entry (bug#71264) a4fe4ca93cf Fix font lock regex for user defined constant in PHP e1ba4ebb495 Make Compilation mode recognize non-legacy Kotlin/Gradle ... 4f030834994 ; Improve documentation of EditorConfig support c0bfe429485 List Andrea Corallo as co-maintainer in ack.texi b3d6880512f * admin/MAINTAINERS: Add myself in (co-)maintainers. 7cc939bf27e ; * lisp/ldefs-boot.el: Regenerated for Emacs 29.4 959eacc2a70 Bump Emacs version to 29.4 9a02fce714c Update files for Emacs 29.4 d96c54d3883 * admin/authors.el: Update for Emacs 29.4 fd207432e50 * etc/NEWS: Update for Emacs 29.4 c645e1d8205 org-link-expand-abbrev: Do not evaluate arbitrary unsafe ... 50a237c4689 Update Tramp version (don't merge to master) f3e80dd0f70 * admin/emacs-shell-lib: Backport to Bash 4.4 or older. ce85d3811da Fix bug#49289 also for other auth-source backends # Conflicts: # etc/NEWS
-rw-r--r--configure.ac2
-rw-r--r--doc/emacs/basic.texi13
-rw-r--r--doc/emacs/buffers.texi15
-rw-r--r--doc/emacs/building.texi12
-rw-r--r--doc/emacs/dired.texi9
-rw-r--r--doc/emacs/files.texi41
-rw-r--r--doc/emacs/killing.texi7
-rw-r--r--doc/emacs/maintaining.texi15
-rw-r--r--doc/emacs/mini.texi20
-rw-r--r--doc/emacs/text.texi16
-rw-r--r--etc/DEBUG72
-rw-r--r--etc/NEWS.30129
-rw-r--r--java/res/drawable/emacs_background.xml28
-rw-r--r--java/res/drawable/emacs_foreground.xml24
-rw-r--r--src/emacs.c8
-rw-r--r--src/w32.c2
-rw-r--r--src/w32.h1
-rw-r--r--src/w32fns.c79
-rw-r--r--src/w32notify.c42
-rw-r--r--src/w32uniscribe.c140
-rw-r--r--test/lisp/net/dbus-tests.el52
21 files changed, 525 insertions, 202 deletions
diff --git a/configure.ac b/configure.ac
index e4038a31022..d0c5d8b400d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3138,7 +3138,7 @@ if test "${HAVE_W32}" = "yes"; then
3138 NATIVE_IMAGE_API="yes (w32)" 3138 NATIVE_IMAGE_API="yes (w32)"
3139 W32_OBJ="$W32_OBJ w32image.o" 3139 W32_OBJ="$W32_OBJ w32image.o"
3140 fi 3140 fi
3141 W32_LIBS="$W32_LIBS -lwinmm -lusp10 -lgdi32 -lcomdlg32" 3141 W32_LIBS="$W32_LIBS -lwinmm -lgdi32 -lcomdlg32"
3142 W32_LIBS="$W32_LIBS -lmpr -lwinspool -lole32 -lcomctl32" 3142 W32_LIBS="$W32_LIBS -lmpr -lwinspool -lole32 -lcomctl32"
3143 W32_RES_LINK="\$(EMACSRES)" 3143 W32_RES_LINK="\$(EMACSRES)"
3144 CLIENTRES="emacsclient.res" 3144 CLIENTRES="emacsclient.res"
diff --git a/doc/emacs/basic.texi b/doc/emacs/basic.texi
index a2a934ff243..42f5c971e2f 100644
--- a/doc/emacs/basic.texi
+++ b/doc/emacs/basic.texi
@@ -643,14 +643,11 @@ long, by using Auto Fill mode. @xref{Filling}.
643 Normally, the first character of each continuation line is 643 Normally, the first character of each continuation line is
644positioned at the beginning of the screen line where it is displayed. 644positioned at the beginning of the screen line where it is displayed.
645The minor mode @code{visual-wrap-prefix-mode} and its global 645The minor mode @code{visual-wrap-prefix-mode} and its global
646(@pxref{Minor Modes}) counterpart 646counterpart (@pxref{Minor Modes}) @code{global-visual-wrap-prefix-mode}
647@code{global-visual-wrap-prefix-mode} arranges that continuation lines 647arranges for continuation lines to be indented on display using a fill
648be prefixed by slightly adjusted versions of the fill prefixes 648prefix (@pxref{Fill Prefix}) automatically computed from each line's
649(@pxref{Fill Prefix}) of their respective logical lines, so that 649surrounding context. These prefixes are display-only feature, and do
650indentation characters or the prefixes of source code comments are 650not change the buffer text in any way.
651replicated across every continuation line, and the appearance of such
652comments or indentation is not broken. These prefixes are only shown
653on display, and does not change the buffer text in any way.
654 651
655 Sometimes, you may need to edit files containing many long logical 652 Sometimes, you may need to edit files containing many long logical
656lines, and it may not be practical to break them all up by adding 653lines, and it may not be practical to break them all up by adding
diff --git a/doc/emacs/buffers.texi b/doc/emacs/buffers.texi
index 2786ff6ad65..eba593f0ec9 100644
--- a/doc/emacs/buffers.texi
+++ b/doc/emacs/buffers.texi
@@ -313,6 +313,8 @@ Kill buffer @var{buffer} (@code{kill-buffer}).
313Offer to kill each buffer, one by one. 313Offer to kill each buffer, one by one.
314@item M-x kill-matching-buffers 314@item M-x kill-matching-buffers
315Offer to kill all buffers matching a regular expression. 315Offer to kill all buffers matching a regular expression.
316@item M-x kill-matching-buffers-no-ask
317Like @code{kill-matching-buffers}, but don't ask for confirmation.
316@end table 318@end table
317 319
318@findex kill-buffer 320@findex kill-buffer
@@ -334,13 +336,16 @@ by one. An answer of @kbd{yes} means to kill the buffer, just like
334with a space, which are used internally by Emacs. 336with a space, which are used internally by Emacs.
335 337
336@findex kill-matching-buffers 338@findex kill-matching-buffers
339@findex kill-matching-buffers-no-ask
337 The command @kbd{M-x kill-matching-buffers} prompts for a regular 340 The command @kbd{M-x kill-matching-buffers} prompts for a regular
338expression and kills all buffers whose names match that expression. 341expression and kills all buffers whose names match that expression.
339@xref{Regexps}. Like @code{kill-some-buffers}, it asks for 342@xref{Regexps}. Like @code{kill-some-buffers}, it asks for confirmation
340confirmation before each kill. This command normally ignores buffers 343before each kill. This command normally ignores buffers whose names
341whose names begin with a space, which are used internally by Emacs. 344begin with a space, which are used internally by Emacs. To kill
342To kill internal buffers as well, call @code{kill-matching-buffers} 345internal buffers as well, call @code{kill-matching-buffers} with a
343with a prefix argument. 346prefix argument. The command @w{@kbd{M-x kill-matching-buffers-no-ask}}
347works like @code{kill-matching-buffers}, but doesn't ask for
348confirmation before killing each matching buffer.
344 349
345 The Buffer Menu feature is also convenient for killing various 350 The Buffer Menu feature is also convenient for killing various
346buffers. @xref{Several Buffers}. 351buffers. @xref{Several Buffers}.
diff --git a/doc/emacs/building.texi b/doc/emacs/building.texi
index 38cc0bb67af..1b079c2cef9 100644
--- a/doc/emacs/building.texi
+++ b/doc/emacs/building.texi
@@ -477,6 +477,14 @@ non-@code{nil} if the buffer is to be saved). Any other
477non-@code{nil} value means that all buffers should be saved without 477non-@code{nil} value means that all buffers should be saved without
478asking. The default is @code{ask}. 478asking. The default is @code{ask}.
479 479
480@vindex grep-use-headings
481@vindex grep-heading@r{ face}
482 By default, grep matches are shown with the file names prefixed to
483each line. But if the variable @code{grep-use-headings} is customized
484to a non-@code{nil} value, the matches are split into sections, one
485section for each file with matches, and the file names are shown in the
486section headings using a special face @code{grep-heading}.
487
480@findex grep-find 488@findex grep-find
481@findex find-grep 489@findex find-grep
482 The command @kbd{M-x grep-find} (also available as @kbd{M-x 490 The command @kbd{M-x grep-find} (also available as @kbd{M-x
@@ -1313,6 +1321,10 @@ of output to its standard output, you may wish to separate its I/O
1313from interaction with GDB. Use the command @w{@kbd{M-x 1321from interaction with GDB. Use the command @w{@kbd{M-x
1314gdb-display-io-buffer}} to show a window with a buffer to which Emacs 1322gdb-display-io-buffer}} to show a window with a buffer to which Emacs
1315redirects the input and output from the program you are debugging. 1323redirects the input and output from the program you are debugging.
1324However, if the variable @code{gdb-display-io-buffer} is @code{nil},
1325Emacs will not create nor display a separate I/O buffer, but will
1326instead redirect the program's interaction to the GUD interaction
1327buffer.
1316 1328
1317@findex gdb-display-registers-buffer 1329@findex gdb-display-registers-buffer
1318@item Registers Buffer 1330@item Registers Buffer
diff --git a/doc/emacs/dired.texi b/doc/emacs/dired.texi
index c251a6dc2be..cf57350743f 100644
--- a/doc/emacs/dired.texi
+++ b/doc/emacs/dired.texi
@@ -803,9 +803,9 @@ The @code{dired-keep-marker-copy} user option controls how this
803command handles file marking. The default is to mark all new copies 803command handles file marking. The default is to mark all new copies
804of files with a @samp{C} mark. 804of files with a @samp{C} mark.
805 805
806@item D
807@findex dired-do-delete 806@findex dired-do-delete
808@kindex D @r{(Dired)} 807@kindex D @r{(Dired)}
808@item D
809Delete the specified files (@code{dired-do-delete}). This is like the 809Delete the specified files (@code{dired-do-delete}). This is like the
810shell command @code{rm}. 810shell command @code{rm}.
811 811
@@ -813,6 +813,13 @@ Like the other commands in this section, this command operates on the
813@emph{marked} files, or the next @var{n} files. By contrast, @kbd{x} 813@emph{marked} files, or the next @var{n} files. By contrast, @kbd{x}
814(@code{dired-do-flagged-delete}) deletes all @dfn{flagged} files. 814(@code{dired-do-flagged-delete}) deletes all @dfn{flagged} files.
815 815
816@findex dired-do-open
817@kindex E @r{(Dired)}
818@item E
819``Open'' the specified files using an external program. The program is
820selected according to the system conventions, as determined by the
821variable @code{shell-command-guess-open}.
822
816@findex dired-do-rename 823@findex dired-do-rename
817@kindex R @r{(Dired)} 824@kindex R @r{(Dired)}
818@cindex renaming files (in Dired) 825@cindex renaming files (in Dired)
diff --git a/doc/emacs/files.texi b/doc/emacs/files.texi
index dfacf501650..709cb0910e6 100644
--- a/doc/emacs/files.texi
+++ b/doc/emacs/files.texi
@@ -1633,8 +1633,8 @@ commands to visit the corresponding source locations.
1633manipulate and apply parts of patches: 1633manipulate and apply parts of patches:
1634 1634
1635@table @kbd 1635@table @kbd
1636@item M-n
1637@findex diff-hunk-next 1636@findex diff-hunk-next
1637@item M-n
1638Move to the next hunk-start (@code{diff-hunk-next}). With prefix 1638Move to the next hunk-start (@code{diff-hunk-next}). With prefix
1639argument @var{n}, move forward to the @var{n}th next hunk. 1639argument @var{n}, move forward to the @var{n}th next hunk.
1640 1640
@@ -1645,45 +1645,50 @@ you set @code{diff-refine} to the symbol @code{navigation}, Diff mode
1645only refines the hunk you move to with this command or with 1645only refines the hunk you move to with this command or with
1646@code{diff-hunk-prev}. 1646@code{diff-hunk-prev}.
1647 1647
1648@item M-p
1649@findex diff-hunk-prev 1648@findex diff-hunk-prev
1649@item M-p
1650Move to the previous hunk-start (@code{diff-hunk-prev}). With prefix 1650Move to the previous hunk-start (@code{diff-hunk-prev}). With prefix
1651argument @var{n}, move back to the @var{n}th previous hunk. Like 1651argument @var{n}, move back to the @var{n}th previous hunk. Like
1652@kbd{M-n}, this command refines the hunk you move to if you set 1652@kbd{M-n}, this command refines the hunk you move to if you set
1653@code{diff-refine} to the symbol @code{navigation}. 1653@code{diff-refine} to the symbol @code{navigation}.
1654 1654
1655@item M-@}
1656@findex diff-file-next 1655@findex diff-file-next
1656@item M-@}
1657Move to the next file-start, in a multi-file patch 1657Move to the next file-start, in a multi-file patch
1658(@code{diff-file-next}). With prefix argument @var{n}, move forward 1658(@code{diff-file-next}). With prefix argument @var{n}, move forward
1659to the start of the @var{n}th next file. 1659to the start of the @var{n}th next file.
1660 1660
1661@item M-@{
1662@findex diff-file-prev 1661@findex diff-file-prev
1662@item M-@{
1663Move to the previous file-start, in a multi-file patch 1663Move to the previous file-start, in a multi-file patch
1664(@code{diff-file-prev}). With prefix argument @var{n}, move back to 1664(@code{diff-file-prev}). With prefix argument @var{n}, move back to
1665the start of the @var{n}th previous file. 1665the start of the @var{n}th previous file.
1666 1666
1667@item M-k
1668@findex diff-hunk-kill 1667@findex diff-hunk-kill
1668@item M-k
1669Kill the hunk at point (@code{diff-hunk-kill}). 1669Kill the hunk at point (@code{diff-hunk-kill}).
1670 1670
1671@item M-K
1672@findex diff-file-kill 1671@findex diff-file-kill
1672@item M-K
1673In a multi-file patch, kill the current file part. 1673In a multi-file patch, kill the current file part.
1674(@code{diff-file-kill}). 1674(@code{diff-file-kill}).
1675 1675
1676@item C-c C-a
1677@findex diff-apply-hunk 1676@findex diff-apply-hunk
1678@cindex patches, applying 1677@cindex patches, applying
1678@item C-c C-a
1679Apply this hunk to its target file (@code{diff-apply-hunk}). With a 1679Apply this hunk to its target file (@code{diff-apply-hunk}). With a
1680prefix argument of @kbd{C-u}, revert this hunk, i.e.@: apply the 1680prefix argument of @kbd{C-u}, revert this hunk, i.e.@: apply the
1681reverse of the hunk, which changes the ``new'' version into the ``old'' 1681reverse of the hunk, which changes the ``new'' version into the ``old''
1682version. If @code{diff-jump-to-old-file} is non-@code{nil}, apply the 1682version. If @code{diff-jump-to-old-file} is non-@code{nil}, apply the
1683hunk to the ``old'' version of the file instead. 1683hunk to the ``old'' version of the file instead.
1684 1684
1685@item C-c C-b 1685@findex diff-apply-buffer
1686@item C-c @key{RET} a
1687Apply all the hunks in the buffer (@code{diff-apply-buffer}). If the
1688diffs were applied successfully, save the changed buffers.
1689
1686@findex diff-refine-hunk 1690@findex diff-refine-hunk
1691@item C-c C-b
1687Highlight the changes of the hunk at point with a finer granularity 1692Highlight the changes of the hunk at point with a finer granularity
1688(@code{diff-refine-hunk}). This allows you to see exactly which parts 1693(@code{diff-refine-hunk}). This allows you to see exactly which parts
1689of each changed line were actually changed. 1694of each changed line were actually changed.
@@ -1693,9 +1698,9 @@ By default, Diff mode refines hunks as Emacs displays them, so you may
1693find this command useful if you customize @code{diff-refine} to a 1698find this command useful if you customize @code{diff-refine} to a
1694non-default value. 1699non-default value.
1695 1700
1696@item C-c C-c
1697@findex diff-goto-source 1701@findex diff-goto-source
1698@vindex diff-jump-to-old-file 1702@vindex diff-jump-to-old-file
1703@item C-c C-c
1699Go to the source file and line corresponding to this hunk 1704Go to the source file and line corresponding to this hunk
1700(@code{diff-goto-source}). By default, this jumps to the ``new'' 1705(@code{diff-goto-source}). By default, this jumps to the ``new''
1701version of the file, the one shown first on the file header. 1706version of the file, the one shown first on the file header.
@@ -1710,20 +1715,20 @@ this jumps to the work file by default. With a prefix argument, jump
1710to the ``old'' revision of the file (@pxref{Old Revisions}), when 1715to the ``old'' revision of the file (@pxref{Old Revisions}), when
1711point is on the old line, or otherwise jump to the ``new'' revision. 1716point is on the old line, or otherwise jump to the ``new'' revision.
1712 1717
1713@item C-c C-e
1714@findex diff-ediff-patch 1718@findex diff-ediff-patch
1719@item C-c C-e
1715Start an Ediff session with the patch (@code{diff-ediff-patch}). 1720Start an Ediff session with the patch (@code{diff-ediff-patch}).
1716@xref{Top, Ediff, Ediff, ediff, The Ediff Manual}. 1721@xref{Top, Ediff, Ediff, ediff, The Ediff Manual}.
1717 1722
1718@item C-c C-n
1719@findex diff-restrict-view 1723@findex diff-restrict-view
1724@item C-c C-n
1720Restrict the view to the current hunk (@code{diff-restrict-view}). 1725Restrict the view to the current hunk (@code{diff-restrict-view}).
1721@xref{Narrowing}. With a prefix argument, restrict the 1726@xref{Narrowing}. With a prefix argument, restrict the
1722view to the current file of a multiple-file patch. To widen again, 1727view to the current file of a multiple-file patch. To widen again,
1723use @kbd{C-x n w} (@code{widen}). 1728use @kbd{C-x n w} (@code{widen}).
1724 1729
1725@item C-c C-r
1726@findex diff-reverse-direction 1730@findex diff-reverse-direction
1731@item C-c C-r
1727Reverse the direction of comparison for the entire buffer 1732Reverse the direction of comparison for the entire buffer
1728(@code{diff-reverse-direction}). With a prefix argument, reverse the 1733(@code{diff-reverse-direction}). With a prefix argument, reverse the
1729direction only inside the current region (@pxref{Mark}). Reversing 1734direction only inside the current region (@pxref{Mark}). Reversing
@@ -1731,8 +1736,8 @@ the direction means changing the hunks and the file-start headers to
1731produce a patch that would change the ``new'' version into the ``old'' 1736produce a patch that would change the ``new'' version into the ``old''
1732one. 1737one.
1733 1738
1734@item C-c C-s
1735@findex diff-split-hunk 1739@findex diff-split-hunk
1740@item C-c C-s
1736Split the hunk at point (@code{diff-split-hunk}) into two separate 1741Split the hunk at point (@code{diff-split-hunk}) into two separate
1737hunks. This inserts a hunk header and modifies the header of the 1742hunks. This inserts a hunk header and modifies the header of the
1738current hunk. This command is useful for manually editing patches, 1743current hunk. This command is useful for manually editing patches,
@@ -1743,35 +1748,35 @@ produced by the @option{-c} or @option{--context} options to
1743@command{diff}, first convert the buffer to the unified diff format 1748@command{diff}, first convert the buffer to the unified diff format
1744with @kbd{C-c C-u}. 1749with @kbd{C-c C-u}.
1745 1750
1746@item C-c C-d
1747@findex diff-unified->context 1751@findex diff-unified->context
1752@item C-c C-d
1748Convert the entire buffer to the @dfn{context diff format} 1753Convert the entire buffer to the @dfn{context diff format}
1749(@code{diff-unified->context}). With a prefix argument, convert only 1754(@code{diff-unified->context}). With a prefix argument, convert only
1750the hunks within the region. 1755the hunks within the region.
1751 1756
1752@item C-c C-u
1753@findex diff-context->unified 1757@findex diff-context->unified
1758@item C-c C-u
1754Convert the entire buffer to unified diff format 1759Convert the entire buffer to unified diff format
1755(@code{diff-context->unified}). With a prefix argument, convert 1760(@code{diff-context->unified}). With a prefix argument, convert
1756unified format to context format. When the mark is active, convert 1761unified format to context format. When the mark is active, convert
1757only the hunks within the region. 1762only the hunks within the region.
1758 1763
1759@item C-c C-l
1760@findex diff-refresh-hunk 1764@findex diff-refresh-hunk
1765@item C-c C-l
1761Re-generate the current hunk (@code{diff-refresh-hunk}). 1766Re-generate the current hunk (@code{diff-refresh-hunk}).
1762 1767
1763@item C-c C-w
1764@vindex diff-ignore-whitespace-switches 1768@vindex diff-ignore-whitespace-switches
1765@findex diff-ignore-whitespace-hunk 1769@findex diff-ignore-whitespace-hunk
1770@item C-c C-w
1766Re-generate the current hunk, disregarding changes in whitespace. 1771Re-generate the current hunk, disregarding changes in whitespace.
1767With a non-@code{nil} prefix arg, re-generate all the hunks 1772With a non-@code{nil} prefix arg, re-generate all the hunks
1768(@code{diff-ignore-whitespace-hunk}). This calls @code{diff-command} 1773(@code{diff-ignore-whitespace-hunk}). This calls @code{diff-command}
1769with @code{diff-ignore-whitespace-switches}, which defaults to 1774with @code{diff-ignore-whitespace-switches}, which defaults to
1770@samp{-b}, meaning ignore changes in whitespace only. 1775@samp{-b}, meaning ignore changes in whitespace only.
1771 1776
1772@item C-x 4 A
1773@findex diff-add-change-log-entries-other-window 1777@findex diff-add-change-log-entries-other-window
1774@findex add-change-log-entry-other-window@r{, in Diff mode} 1778@findex add-change-log-entry-other-window@r{, in Diff mode}
1779@item C-x 4 A
1775Generate a ChangeLog entry, like @kbd{C-x 4 a} does (@pxref{Change 1780Generate a ChangeLog entry, like @kbd{C-x 4 a} does (@pxref{Change
1776Log}), for each one of the hunks 1781Log}), for each one of the hunks
1777(@code{diff-add-change-log-entries-other-window}). This creates a 1782(@code{diff-add-change-log-entries-other-window}). This creates a
diff --git a/doc/emacs/killing.texi b/doc/emacs/killing.texi
index 57adc037cb7..62f72763ac6 100644
--- a/doc/emacs/killing.texi
+++ b/doc/emacs/killing.texi
@@ -302,6 +302,13 @@ a pure white space string to the kill ring, you can say:
302non-@code{nil} value, identical subsequent kills yield a single 302non-@code{nil} value, identical subsequent kills yield a single
303kill-ring entry, without duplication. 303kill-ring entry, without duplication.
304 304
305@findex kill-ring-deindent-mode
306 If you enable the minor mode @code{kill-ring-deindent-mode}, text
307saved to the kill-ring will have its indentation decreased by the amount
308of indentation of the first saved line. That is, if the first line of
309the saved text was indented @var{n} columns, this mode will remove that
310number of columns from the indentation of each saved line.
311
305@node Yanking 312@node Yanking
306@section Yanking 313@section Yanking
307@cindex moving text 314@cindex moving text
diff --git a/doc/emacs/maintaining.texi b/doc/emacs/maintaining.texi
index 64d77fb88a5..f4752fa2b29 100644
--- a/doc/emacs/maintaining.texi
+++ b/doc/emacs/maintaining.texi
@@ -1850,6 +1850,9 @@ Run shell command in the current project's root directory
1850@item C-x p & 1850@item C-x p &
1851Run shell command asynchronously in the current project's root 1851Run shell command asynchronously in the current project's root
1852directory (@code{project-async-shell-command}). 1852directory (@code{project-async-shell-command}).
1853@item C-x p o
1854Run the next command in the current project
1855(@code{project-any-command}).
1853@end table 1856@end table
1854 1857
1855 Emacs provides commands for handling project files conveniently. 1858 Emacs provides commands for handling project files conveniently.
@@ -1946,6 +1949,11 @@ directory. @xref{Top,Eshell,Eshell, eshell, Eshell: The Emacs Shell}.
1946 The command @kbd{C-x p &} (@code{project-async-shell-command}) runs 1949 The command @kbd{C-x p &} (@code{project-async-shell-command}) runs
1947@code{async-shell-command} in the current project's root directory. 1950@code{async-shell-command} in the current project's root directory.
1948 1951
1952@findex project-any-command
1953 Finally, the command @kbd{C-x p o} (@code{project-any-command}) will
1954run the next command you type, whether related to files or not, in the
1955current project.
1956
1949@node Project Buffer Commands 1957@node Project Buffer Commands
1950@subsection Project Commands That Operate on Buffers 1958@subsection Project Commands That Operate on Buffers
1951 1959
@@ -1958,6 +1966,9 @@ List the project buffers (@code{project-list-buffers}).
1958@item C-x p k 1966@item C-x p k
1959Kill all live buffers that belong to the current project 1967Kill all live buffers that belong to the current project
1960(@code{project-kill-buffers}). 1968(@code{project-kill-buffers}).
1969@item C-x p o
1970Run the next command in the current project
1971(@code{project-any-command}).
1961@end table 1972@end table
1962 1973
1963@findex project-switch-to-buffer 1974@findex project-switch-to-buffer
@@ -1986,6 +1997,10 @@ project that satisfy any of @code{project-kill-buffer-conditions}. If
1986@code{project-kill-buffers-display-buffer-list} is non-@code{nil}, the 1997@code{project-kill-buffers-display-buffer-list} is non-@code{nil}, the
1987buffers to be killed will be displayed first. 1998buffers to be killed will be displayed first.
1988 1999
2000 Finally, the command @kbd{C-x p o} (@code{project-any-command}) will
2001run the next command you type, whether related to buffers or not, in the
2002current project.
2003
1989@node Switching Projects 2004@node Switching Projects
1990@subsection Switching Projects 2005@subsection Switching Projects
1991 2006
diff --git a/doc/emacs/mini.texi b/doc/emacs/mini.texi
index 4557f41c3f7..79744967455 100644
--- a/doc/emacs/mini.texi
+++ b/doc/emacs/mini.texi
@@ -452,6 +452,15 @@ While in the completion list buffer, kill it and delete the window
452showing it (@code{kill-current-buffer}). 452showing it (@code{kill-current-buffer}).
453@end table 453@end table
454 454
455@vindex minibuffer-visible-completions
456 If the variable @code{minibuffer-visible-completions} is customized to
457a non-@code{nil} value, it changes the commands bound to the arrow keys:
458instead of moving in the minibuffer, they move between completion
459candidates, like meta-arrow keys do by default. Similarly,
460@kbd{@key{RET}} selects the current candidate, like @kbd{M-@key{RET}}
461does normally. @code{C-g} hides the completion window, but leaves the
462minibuffer active, so you can continue typing at the prompt.
463
455@node Completion Exit 464@node Completion Exit
456@subsection Completion Exit 465@subsection Completion Exit
457 466
@@ -685,6 +694,17 @@ then move to a candidate by cursor motion commands and select it with
685@code{second-tab}, then the first @kbd{@key{TAB}} will pop up the 694@code{second-tab}, then the first @kbd{@key{TAB}} will pop up the
686completions list buffer, and the second one will switch to it. 695completions list buffer, and the second one will switch to it.
687 696
697@findex previous-line-completion
698@findex next-line-completion
699@vindex completion-auto-wrap
700 When the window showing the completions is selected, either because
701you customized @code{completion-auto-select} or because you switched to
702it by typing @kbd{C-x o}, the @kbd{@key{UP}} and @kbd{@key{DOWN}} arrow
703keys move by lines between completion candidates; with a prefix numeric
704argument, they move that many lines. If @code{completion-auto-wrap} is
705non-@code{nil}, these commands will wrap at bottom and top of the
706candidate list.
707
688@vindex completion-cycle-threshold 708@vindex completion-cycle-threshold
689 If @code{completion-cycle-threshold} is non-@code{nil}, completion 709 If @code{completion-cycle-threshold} is non-@code{nil}, completion
690commands can cycle through completion alternatives. Normally, if 710commands can cycle through completion alternatives. Normally, if
diff --git a/doc/emacs/text.texi b/doc/emacs/text.texi
index 1d1065c45c2..8abaeafcf33 100644
--- a/doc/emacs/text.texi
+++ b/doc/emacs/text.texi
@@ -1208,6 +1208,12 @@ Hide everything except the top @var{n} levels of heading lines
1208Hide everything except for the heading or body that point is in, plus 1208Hide everything except for the heading or body that point is in, plus
1209the headings leading up from there to the top level of the outline 1209the headings leading up from there to the top level of the outline
1210(@code{outline-hide-other}). 1210(@code{outline-hide-other}).
1211@item C-c / h @var{regexp} @key{RET}
1212Hide bodies of headings that match @var{regexp}
1213(@code{outline-hide-by-heading-regexp}).
1214@item C-c / s @var{regexp} @key{RET}
1215Show bodies of headings that match @var{regexp}
1216(@code{outline-show-by-heading-regexp}).
1211@end table 1217@end table
1212 1218
1213@findex outline-hide-entry 1219@findex outline-hide-entry
@@ -1253,6 +1259,16 @@ headers leading up from there to top level in the outline) and the top
1253level headings. It also reveals body lines preceding the first 1259level headings. It also reveals body lines preceding the first
1254heading in the buffer. 1260heading in the buffer.
1255 1261
1262@findex outline-hide-by-heading-regexp
1263@findex outline-show-by-heading-regexp
1264@kindex C-c / h @r{(Outline mode)}
1265@kindex C-c / s @r{(Outline mode)}
1266 The command @kbd{C-c / h} (@code{outline-hide-by-heading-regexp})
1267prompts for a regular expression, and hides all the body lines of
1268headings which match the regular expression. The command @kbd{C-c / s}
1269likewise prompts for a regular expression, and reveals the bodies of
1270matching headings.
1271
1256@findex outline-hide-body 1272@findex outline-hide-body
1257@findex outline-show-all 1273@findex outline-show-all
1258@kindex C-c C-t @r{(Outline mode)} 1274@kindex C-c C-t @r{(Outline mode)}
diff --git a/etc/DEBUG b/etc/DEBUG
index 4eae090621f..06544674e5d 100644
--- a/etc/DEBUG
+++ b/etc/DEBUG
@@ -1157,6 +1157,12 @@ Please refer to the LLDB reference on the web for more information
1157about LLDB. If you already know GDB, you will also find a mapping 1157about LLDB. If you already know GDB, you will also find a mapping
1158from GDB commands to corresponding LLDB commands there. 1158from GDB commands to corresponding LLDB commands there.
1159 1159
1160** Debugging Emacs on OpenBSD
1161
1162To debug Emacs on OpenBSD, use the 'egdb' command from the 'gdb'
1163package. This reportedly works both if Emacs was compiled with GCC and
1164if it was compiled with clang.
1165
1160** Debugging Emacs on Android. 1166** Debugging Emacs on Android.
1161 1167
1162A script located in the java/ directory automates the procedures 1168A script located in the java/ directory automates the procedures
@@ -1282,39 +1288,39 @@ the crash.
1282The third form is printed when Emacs misuses the JVM in some fashion 1288The third form is printed when Emacs misuses the JVM in some fashion
1283that is detected by the Android CheckJNI facility. It looks like: 1289that is detected by the Android CheckJNI facility. It looks like:
1284 1290
1285A/art art/runtime/check_jni.cc:65] JNI DETECTED ERROR IN APPLICATION: ... 1291A/art: art/runtime/check_jni.cc:65] JNI DETECTED ERROR IN APPLICATION: ...
1286A/art art/runtime/check_jni.cc:65] in call to CallVoidMethodV 1292A/art: art/runtime/check_jni.cc:65] in call to CallVoidMethodV
1287A/art art/runtime/check_jni.cc:65] from void android.os.MessageQueue.nativePollOnce(long, int) 1293A/art: art/runtime/check_jni.cc:65] from void android.os.MessageQueue.nativePollOnce(long, int)
1288A/art art/runtime/check_jni.cc:65] "main" prio=5 tid=1 Runnable 1294A/art: art/runtime/check_jni.cc:65] "main" prio=5 tid=1 Runnable
1289A/art art/runtime/check_jni.cc:65] | group="main" sCount=0 dsCount=0 obj=0x87d30ef0 self=0xb4f07800 1295A/art: art/runtime/check_jni.cc:65] | group="main" sCount=0 dsCount=0 obj=0x87d30ef0 self=0xb4f07800
1290A/art art/runtime/check_jni.cc:65] | sysTid=18828 nice=-11 cgrp=apps sched=0/0 handle=0xb6fdeec8 1296A/art: art/runtime/check_jni.cc:65] | sysTid=18828 nice=-11 cgrp=apps sched=0/0 handle=0xb6fdeec8
1291A/art art/runtime/check_jni.cc:65] | state=R schedstat=( 2249126546 506089308 3210 ) utm=183 stm=41 core=3 HZ=100 1297A/art: art/runtime/check_jni.cc:65] | state=R schedstat=( 2249126546 506089308 3210 ) utm=183 stm=41 core=3 HZ=100
1292A/art art/runtime/check_jni.cc:65] | stack=0xbe0c8000-0xbe0ca000 stackSize=8MB 1298A/art: art/runtime/check_jni.cc:65] | stack=0xbe0c8000-0xbe0ca000 stackSize=8MB
1293A/art art/runtime/check_jni.cc:65] | held mutexes= "mutator lock"(shared held) 1299A/art: art/runtime/check_jni.cc:65] | held mutexes= "mutator lock"(shared held)
1294A/art﹕ art/runtime/check_jni.cc:65] native: #00 pc 00004640 /system/lib/libbacktrace_libc++.so (UnwindCurrent::Unwind(unsigned int, ucontext*)+23) 1300A/art: art/runtime/check_jni.cc:65] native: #00 pc 00004640 /system/lib/libbacktrace_libc++.so (UnwindCurrent::Unwind(unsigned int, ucontext*)+23)
1295A/art﹕ art/runtime/check_jni.cc:65] native: #01 pc 00002e8d /system/lib/libbacktrace_libc++.so (Backtrace::Unwind(unsigned int, ucontext*)+8) 1301A/art: art/runtime/check_jni.cc:65] native: #01 pc 00002e8d /system/lib/libbacktrace_libc++.so (Backtrace::Unwind(unsigned int, ucontext*)+8)
1296A/art﹕ art/runtime/check_jni.cc:65] native: #02 pc 00248381 /system/lib/libart.so (art::DumpNativeStack(std::__1::basic_ostream<char, std::__1::char_traits<char> >&, int, char const*, art::mirror::ArtMethod*)+68) 1302A/art: art/runtime/check_jni.cc:65] native: #02 pc 00248381 /system/lib/libart.so (art::DumpNativeStack(std::__1::basic_ostream<char, std::__1::char_traits<char> >&, int, char const*, art::mirror::ArtMethod*)+68)
1297A/art﹕ art/runtime/check_jni.cc:65] native: #03 pc 0022cd0b /system/lib/libart.so (art::Thread::Dump(std::__1::basic_ostream<char, std::__1::char_traits<char> >&) const+146) 1303A/art: art/runtime/check_jni.cc:65] native: #03 pc 0022cd0b /system/lib/libart.so (art::Thread::Dump(std::__1::basic_ostream<char, std::__1::char_traits<char> >&) const+146)
1298A/art﹕ art/runtime/check_jni.cc:65] native: #04 pc 000b189b /system/lib/libart.so (art::JniAbort(char const*, char const*)+582) 1304A/art: art/runtime/check_jni.cc:65] native: #04 pc 000b189b /system/lib/libart.so (art::JniAbort(char const*, char const*)+582)
1299A/art﹕ art/runtime/check_jni.cc:65] native: #05 pc 000b1fd5 /system/lib/libart.so (art::JniAbortF(char const*, char const*, ...)+60) 1305A/art: art/runtime/check_jni.cc:65] native: #05 pc 000b1fd5 /system/lib/libart.so (art::JniAbortF(char const*, char const*, ...)+60)
1300A/art﹕ art/runtime/check_jni.cc:65] native: #06 pc 000b50e5 /system/lib/libart.so (art::ScopedCheck::ScopedCheck(_JNIEnv*, int, char const*)+1284) 1306A/art: art/runtime/check_jni.cc:65] native: #06 pc 000b50e5 /system/lib/libart.so (art::ScopedCheck::ScopedCheck(_JNIEnv*, int, char const*)+1284)
1301A/art﹕ art/runtime/check_jni.cc:65] native: #07 pc 000bc59f /system/lib/libart.so (art::CheckJNI::CallVoidMethodV(_JNIEnv*, _jobject*, _jmethodID*, std::__va_list)+30) 1307A/art: art/runtime/check_jni.cc:65] native: #07 pc 000bc59f /system/lib/libart.so (art::CheckJNI::CallVoidMethodV(_JNIEnv*, _jobject*, _jmethodID*, std::__va_list)+30)
1302A/art art/runtime/check_jni.cc:65] native: #08 pc 00063803 /system/lib/libandroid_runtime.so (???) 1308A/art: art/runtime/check_jni.cc:65] native: #08 pc 00063803 /system/lib/libandroid_runtime.so (???)
1303A/art﹕ art/runtime/check_jni.cc:65] native: #09 pc 000776bd /system/lib/libandroid_runtime.so (android::NativeDisplayEventReceiver::dispatchVsync(long long, int, unsigned int)+40) 1309A/art: art/runtime/check_jni.cc:65] native: #09 pc 000776bd /system/lib/libandroid_runtime.so (android::NativeDisplayEventReceiver::dispatchVsync(long long, int, unsigned int)+40)
1304A/art﹕ art/runtime/check_jni.cc:65] native: #10 pc 00077885 /system/lib/libandroid_runtime.so (android::NativeDisplayEventReceiver::handleEvent(int, int, void*)+80) 1310A/art: art/runtime/check_jni.cc:65] native: #10 pc 00077885 /system/lib/libandroid_runtime.so (android::NativeDisplayEventReceiver::handleEvent(int, int, void*)+80)
1305A/art art/runtime/check_jni.cc:65] native: #11 pc 00010f6f /system/lib/libutils.so (android::Looper::pollInner(int)+482) 1311A/art: art/runtime/check_jni.cc:65] native: #11 pc 00010f6f /system/lib/libutils.so (android::Looper::pollInner(int)+482)
1306A/art﹕ art/runtime/check_jni.cc:65] native: #12 pc 00011019 /system/lib/libutils.so (android::Looper::pollOnce(int, int*, int*, void**)+92) 1312A/art: art/runtime/check_jni.cc:65] native: #12 pc 00011019 /system/lib/libutils.so (android::Looper::pollOnce(int, int*, int*, void**)+92)
1307A/art﹕ art/runtime/check_jni.cc:65] native: #13 pc 000830c1 /system/lib/libandroid_runtime.so (android::NativeMessageQueue::pollOnce(_JNIEnv*, int)+22) 1313A/art: art/runtime/check_jni.cc:65] native: #13 pc 000830c1 /system/lib/libandroid_runtime.so (android::NativeMessageQueue::pollOnce(_JNIEnv*, int)+22)
1308A/art﹕ art/runtime/check_jni.cc:65] native: #14 pc 000b22d7 /system/framework/arm/boot.oat (Java_android_os_MessageQueue_nativePollOnce__JI+102) 1314A/art: art/runtime/check_jni.cc:65] native: #14 pc 000b22d7 /system/framework/arm/boot.oat (Java_android_os_MessageQueue_nativePollOnce__JI+102)
1309A/art art/runtime/check_jni.cc:65] at android.os.MessageQueue.nativePollOnce(Native method) 1315A/art: art/runtime/check_jni.cc:65] at android.os.MessageQueue.nativePollOnce(Native method)
1310A/art art/runtime/check_jni.cc:65] at android.os.MessageQueue.next(MessageQueue.java:143) 1316A/art: art/runtime/check_jni.cc:65] at android.os.MessageQueue.next(MessageQueue.java:143)
1311A/art art/runtime/check_jni.cc:65] at android.os.Looper.loop(Looper.java:130) 1317A/art: art/runtime/check_jni.cc:65] at android.os.Looper.loop(Looper.java:130)
1312A/art art/runtime/check_jni.cc:65] at android.app.ActivityThread.main(ActivityThread.java:5832) 1318A/art: art/runtime/check_jni.cc:65] at android.app.ActivityThread.main(ActivityThread.java:5832)
1313A/art art/runtime/check_jni.cc:65] at java.lang.reflect.Method.invoke!(Native method) 1319A/art: art/runtime/check_jni.cc:65] at java.lang.reflect.Method.invoke!(Native method)
1314A/art art/runtime/check_jni.cc:65] at java.lang.reflect.Method.invoke(Method.java:372) 1320A/art: art/runtime/check_jni.cc:65] at java.lang.reflect.Method.invoke(Method.java:372)
1315A/art art/runtime/check_jni.cc:65] at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399) 1321A/art: art/runtime/check_jni.cc:65] at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
1316A/art art/runtime/check_jni.cc:65] at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194) 1322A/art: art/runtime/check_jni.cc:65] at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
1317A/art art/runtime/check_jni.cc:65] 1323A/art: art/runtime/check_jni.cc:65]
1318 1324
1319In such situations, the first line explains what infraction Emacs 1325In such situations, the first line explains what infraction Emacs
1320committed, while the ensuing ones print backtraces for each running 1326committed, while the ensuing ones print backtraces for each running
diff --git a/etc/NEWS.30 b/etc/NEWS.30
index d5409d139dc..a6eda6afddd 100644
--- a/etc/NEWS.30
+++ b/etc/NEWS.30
@@ -58,6 +58,7 @@ ALSA on these operating systems instead.
58 58
59* Startup Changes in Emacs 30.1 59* Startup Changes in Emacs 30.1
60 60
61---
61** On GNU/Linux, Emacs is now the default application for 'org-protocol'. 62** On GNU/Linux, Emacs is now the default application for 'org-protocol'.
62Org mode provides a way to quickly capture bookmarks, notes, and links 63Org mode provides a way to quickly capture bookmarks, notes, and links
63using 'emacsclient': 64using 'emacsclient':
@@ -71,7 +72,7 @@ arranges for Emacs to be the default application for the 'org-protocol'
71URI scheme. See the Org mode manual, Info node "(org) Protocols" for 72URI scheme. See the Org mode manual, Info node "(org) Protocols" for
72more details. 73more details.
73 74
74--- 75+++
75** New variable lets Lisp code read emacsclient arguments. 76** New variable lets Lisp code read emacsclient arguments.
76When '--eval' is passed to emacsclient and Emacs is evaluating each 77When '--eval' is passed to emacsclient and Emacs is evaluating each
77argument, the new variable 'server-eval-args-left' is set to those 78argument, the new variable 'server-eval-args-left' is set to those
@@ -84,6 +85,7 @@ escaping (to protect them from the shell).
84 85
85* Incompatible Changes in Emacs 30.1 86* Incompatible Changes in Emacs 30.1
86 87
88---
87** Tree-Sitter modes are now declared as submodes of the non-TS modes. 89** Tree-Sitter modes are now declared as submodes of the non-TS modes.
88In order to help the use of those Tree-Sitter modes, they are now 90In order to help the use of those Tree-Sitter modes, they are now
89declared to have the corresponding non-Tree-Sitter mode as an 91declared to have the corresponding non-Tree-Sitter mode as an
@@ -94,6 +96,7 @@ collections of snippets automatically apply to the new Tree-Sitter modes.
94Note that those modes still do not inherit from the non-TS mode, so 96Note that those modes still do not inherit from the non-TS mode, so
95configuration settings installed via mode hooks are not affected. 97configuration settings installed via mode hooks are not affected.
96 98
99---
97** Mouse wheel events should now always be 'wheel-up/down/left/right'. 100** Mouse wheel events should now always be 'wheel-up/down/left/right'.
98At those places where the old 'mouse-4/5/6/7' events could still occur 101At those places where the old 'mouse-4/5/6/7' events could still occur
99(i.e., X11 input in the absence of XInput2, and 'xterm-mouse-mode'), 102(i.e., X11 input in the absence of XInput2, and 'xterm-mouse-mode'),
@@ -124,6 +127,7 @@ to your init file:
124 127
125 (advice-add 'completion-at-point :after #'minibuffer-hide-completions) 128 (advice-add 'completion-at-point :after #'minibuffer-hide-completions)
126 129
130---
127** The default process filter was rewritten in native code. 131** The default process filter was rewritten in native code.
128The round-trip through the Lisp function 132The round-trip through the Lisp function
129'internal-default-process-filter' is skipped when the process filter is 133'internal-default-process-filter' is skipped when the process filter is
@@ -158,6 +162,7 @@ see the variable 'url-request-extra-headers'.
158 162
159* Changes in Emacs 30.1 163* Changes in Emacs 30.1
160 164
165---
161** Emacs now supports Unicode Standard version 15.1. 166** Emacs now supports Unicode Standard version 15.1.
162 167
163+++ 168+++
@@ -184,20 +189,23 @@ TTY frames.
184 189
185--- 190---
186** Support for underline colors on TTY frames. 191** Support for underline colors on TTY frames.
187Colors specified in face underlines will now also be displayed in TTY 192Colors specified in the underline face will now also be displayed on TTY
188frames with the previously mentioned capabilities. 193frames on terminals that support the 'Su' or 'Smulx' capabilities.
189 194
195+++
190** Modeline elements can now be right-aligned. 196** Modeline elements can now be right-aligned.
191Anything following the symbol 'mode-line-format-right-align' in 197Anything following the symbol 'mode-line-format-right-align' in
192'mode-line-format' will be right-aligned. Exactly where it is 198'mode-line-format' will be right-aligned. Exactly where it is
193right-aligned to is controlled by the new user option 199right-aligned to is controlled by the new user option
194'mode-line-right-align-edge'. 200'mode-line-right-align-edge'.
195 201
202---
196** X selection requests are now handled much faster and asynchronously. 203** X selection requests are now handled much faster and asynchronously.
197This means it should be less necessary to disable the likes of 204This means it should be less necessary to disable the likes of
198'select-active-regions' when Emacs is running over a slow network 205'select-active-regions' when Emacs is running over a slow network
199connection. 206connection.
200 207
208---
201** Emacs now updates invisible frames that are made visible by a compositor. 209** Emacs now updates invisible frames that are made visible by a compositor.
202If an invisible or an iconified frame is shown to the user by the 210If an invisible or an iconified frame is shown to the user by the
203compositing manager, Emacs will now redisplay such a frame even though 211compositing manager, Emacs will now redisplay such a frame even though
@@ -209,8 +217,8 @@ example, as part of preview for iconified frames.
209The only exception is w32notify. 217The only exception is w32notify.
210 218
211+++ 219+++
212** Image ':map' property is now recomputed when image is transformed. 220** The ':map' property of images is now recomputed when image is transformed.
213Now images with clickable maps work as expected after you run commands 221Images with clickable maps now work as expected after you run commands
214such as 'image-increase-size', 'image-decrease-size', 'image-rotate', 222such as 'image-increase-size', 'image-decrease-size', 'image-rotate',
215'image-flip-horizontally', and 'image-flip-vertically'. 223'image-flip-horizontally', and 'image-flip-vertically'.
216Set the new user option 'image-recompute-map-p' to nil to prevent Emacs 224Set the new user option 'image-recompute-map-p' to nil to prevent Emacs
@@ -218,11 +226,13 @@ from recomputing image maps.
218 226
219** Minibuffer and Completions 227** Minibuffer and Completions
220 228
229+++
221*** New commands 'previous-line-completion' and 'next-line-completion'. 230*** New commands 'previous-line-completion' and 'next-line-completion'.
222Bound to '<up>' and '<down>' arrow keys, respectively, they navigate 231Bound to '<up>' and '<down>' arrow keys, respectively, they navigate
223the "*Completions*" buffer vertically by lines, wrapping at the 232the "*Completions*" buffer vertically by lines, wrapping at the
224top/bottom when 'completion-auto-wrap' is non-nil. 233top/bottom when 'completion-auto-wrap' is non-nil.
225 234
235+++
226*** New user option 'minibuffer-visible-completions'. 236*** New user option 'minibuffer-visible-completions'.
227When customized to non-nil, you can use arrow keys in the minibuffer 237When customized to non-nil, you can use arrow keys in the minibuffer
228to navigate the completions displayed in the "*Completions*" window. 238to navigate the completions displayed in the "*Completions*" window.
@@ -231,6 +241,7 @@ completions window. When the completions window is not visible,
231then all these keys have their usual meaning in the minibuffer. 241then all these keys have their usual meaning in the minibuffer.
232This option is supported for in-buffer completion as well. 242This option is supported for in-buffer completion as well.
233 243
244---
234*** Selected completion candidates are deselected on typing. 245*** Selected completion candidates are deselected on typing.
235When you type at the minibuffer prompt, the current completion 246When you type at the minibuffer prompt, the current completion
236candidate will be un-highlighted, and point in the "*Completions*" window 247candidate will be un-highlighted, and point in the "*Completions*" window
@@ -242,6 +253,7 @@ the minibuffer contents instead. This deselection behavior can be
242controlled with the new user option 'completion-auto-deselect', which 253controlled with the new user option 'completion-auto-deselect', which
243is t by default. 254is t by default.
244 255
256+++
245*** New value 'historical' for user option 'completions-sort'. 257*** New value 'historical' for user option 'completions-sort'.
246When 'completions-sort' is set to 'historical', completion candidates 258When 'completions-sort' is set to 'historical', completion candidates
247will be first sorted alphabetically, and then re-sorted by their order 259will be first sorted alphabetically, and then re-sorted by their order
@@ -304,6 +316,7 @@ It specifies how 'set-window-configuration' and 'window-state-put'
304should proceed with windows whose buffer was killed after the 316should proceed with windows whose buffer was killed after the
305corresponding configuration or state was recorded. 317corresponding configuration or state was recorded.
306 318
319---
307*** New variable 'window-point-context-set-function'. 320*** New variable 'window-point-context-set-function'.
308It can be used to set a context for window point in all windows by 321It can be used to set a context for window point in all windows by
309'window-point-context-set' before calling 'current-window-configuration' 322'window-point-context-set' before calling 'current-window-configuration'
@@ -336,8 +349,9 @@ window systems other than macOS and GNUstep (Nextstep).
336 349
337+++ 350+++
338*** New global minor mode 'modifier-bar-mode'. 351*** New global minor mode 'modifier-bar-mode'.
339When this minor mode is enabled, buttons representing modifier keys 352When this minor mode is enabled, the tool bar displays buttons
340are displayed along the tool bar. 353representing modifier keys. Clicking on these buttons applies the
354corresponding modifiers to the next input event.
341 355
342+++ 356+++
343*** New user option 'tool-bar-always-show-default'. 357*** New user option 'tool-bar-always-show-default'.
@@ -413,10 +427,12 @@ Switch to a buffer visiting the source of what is being described in
413This user option controls outline visibility in the output buffer of 427This user option controls outline visibility in the output buffer of
414'describe-bindings' when 'describe-bindings-outline' is non-nil. 428'describe-bindings' when 'describe-bindings-outline' is non-nil.
415 429
430---
416*** 'describe-function' shows function inferred type when available. 431*** 'describe-function' shows function inferred type when available.
417For native compiled Lisp functions 'describe-function' prints (after 432For native compiled Lisp functions 'describe-function' prints (after
418the signature) the automatically inferred function type as well. 433the signature) the automatically inferred function type as well.
419 434
435---
420*** 'describe-function' now shows the type of the function object. 436*** 'describe-function' now shows the type of the function object.
421The text used to say things like "car is is a built-in function" whereas 437The text used to say things like "car is is a built-in function" whereas
422it now says "car is a primitive-function" where "primitive-function" is 438it now says "car is a primitive-function" where "primitive-function" is
@@ -427,6 +443,7 @@ get information about that type.
427*** 'C-h m' ('describe-mode') uses outlining by default. 443*** 'C-h m' ('describe-mode') uses outlining by default.
428Set 'describe-mode-outline' to nil to get back the old behavior. 444Set 'describe-mode-outline' to nil to get back the old behavior.
429 445
446---
430*** 'C-h k' ('describe-key') shows Unicode name. 447*** 'C-h k' ('describe-key') shows Unicode name.
431For keybindings which produce single characters via translation or input 448For keybindings which produce single characters via translation or input
432methods, 'C-h k' now shows the Unicode name of the produced character in 449methods, 'C-h k' now shows the Unicode name of the produced character in
@@ -436,6 +453,7 @@ addition to the character itself, e.g.
436 453
437 € 'EURO SIGN' (translated from C-x 8 E) 454 € 'EURO SIGN' (translated from C-x 8 E)
438 455
456---
439*** 'C-h b' ('describe-bindings') shows Unicode names. 457*** 'C-h b' ('describe-bindings') shows Unicode names.
440For keybindings which produce single characters via translation (such as 458For keybindings which produce single characters via translation (such as
441those using the 'C-x 8' or 'A-' prefix, or 'dead-acute', 'dead-grave', 459those using the 'C-x 8' or 'A-' prefix, or 'dead-acute', 'dead-grave',
@@ -465,8 +483,10 @@ This command can toggle boolean options for the duration of a session.
465*** New prefix argument for modifying directory-local variables. 483*** New prefix argument for modifying directory-local variables.
466The commands 'add-dir-local-variable', 'delete-dir-local-variable' and 484The commands 'add-dir-local-variable', 'delete-dir-local-variable' and
467'copy-file-locals-to-dir-locals' now take an optional prefix argument, 485'copy-file-locals-to-dir-locals' now take an optional prefix argument,
468to enter the file name you want to modify. 486to enter the file name where you want to modify directory-local
487variables.
469 488
489+++
470*** New user option 'safe-local-variable-directories'. 490*** New user option 'safe-local-variable-directories'.
471This user option names directories in which Emacs will treat all 491This user option names directories in which Emacs will treat all
472directory-local variables as safe. 492directory-local variables as safe.
@@ -475,6 +495,10 @@ directory-local variables as safe.
475** CL Print 495** CL Print
476 496
477+++ 497+++
498*** There is a new chapter in the CL manual documenting cl-print.el.
499See the Info node "(cl) Printing".
500
501+++
478*** You can expand the "..." truncation everywhere. 502*** You can expand the "..." truncation everywhere.
479The code that allowed "..." to be expanded in the "*Backtrace*" buffer 503The code that allowed "..." to be expanded in the "*Backtrace*" buffer
480should now work anywhere the data is generated by 'cl-print'. 504should now work anywhere the data is generated by 'cl-print'.
@@ -494,13 +518,9 @@ This setting causes byte-compiled functions to be printed in full by
494'prin1'. A button on this output can be activated to disassemble the 518'prin1'. A button on this output can be activated to disassemble the
495function. 519function.
496 520
497+++
498*** There is a new chapter in the CL manual documenting cl-print.el.
499See the Info node "(cl) Printing".
500
501** Miscellaneous 521** Miscellaneous
502 522
503--- 523+++
504*** New command 'kill-matching-buffers-no-ask'. 524*** New command 'kill-matching-buffers-no-ask'.
505This works like 'kill-matching-buffers', but without asking for 525This works like 'kill-matching-buffers', but without asking for
506confirmation. 526confirmation.
@@ -512,9 +532,9 @@ between the auto save file and the current file.
512 532
513+++ 533+++
514*** 'read-passwd' can toggle the visibility of passwords. 534*** 'read-passwd' can toggle the visibility of passwords.
515Use 'TAB' in the minibuffer to show or hide the password. Likewise, 535Use 'TAB' in the minibuffer to show or hide the password.
516there is an icon on the mode-line, which toggles the visibility of the 536Alternatively, click the new show-password icon on the mode-line with
517password when clicking with 'mouse-1'. 537'mouse-1' to toggle the visibility of the password.
518 538
519*** 'advice-remove' is now an interactive command. 539*** 'advice-remove' is now an interactive command.
520When called interactively, 'advice-remove' now prompts for an advised 540When called interactively, 'advice-remove' now prompts for an advised
@@ -541,8 +561,8 @@ remote buffers. The default is nil.
541 561
542+++ 562+++
543*** New user option 'remote-file-name-access-timeout'. 563*** New user option 'remote-file-name-access-timeout'.
544When a positive number, this option limits the call of 'access-file' 564If a positive number, this option limits the call of 'access-file'
545for remote files to this number of seconds. Default is nil. 565for remote files to that number of seconds. Default is nil.
546 566
547+++ 567+++
548*** New user option 'yes-or-no-prompt'. 568*** New user option 'yes-or-no-prompt'.
@@ -554,7 +574,8 @@ This allows the user to customize the prompt that is appended by
554*** New user option 'menu-bar-close-window'. 574*** New user option 'menu-bar-close-window'.
555When non-nil, selecting "Close" from the "File" menu or clicking 575When non-nil, selecting "Close" from the "File" menu or clicking
556"Close" in the tool bar will result in the current window being 576"Close" in the tool bar will result in the current window being
557closed, if possible. 577deleted, if possible. The default is nil, and these gestures kill the
578buffer shown in the current window, but don't delete the window.
558 579
559--- 580---
560*** New face 'display-time-date-and-time'. 581*** New face 'display-time-date-and-time'.
@@ -585,8 +606,9 @@ Homebrew.
585 606
586+++ 607+++
587*** 'write-region-inhibit-fsync' now defaults to t in interactive mode, 608*** 'write-region-inhibit-fsync' now defaults to t in interactive mode,
588as it has in batch mode since Emacs 24. 609as it did in batch mode since Emacs 24.
589 610
611---
590*** The default value of 'read-process-output-max' was increased to 65536. 612*** The default value of 'read-process-output-max' was increased to 65536.
591 613
592+++ 614+++
@@ -613,11 +635,11 @@ buffers.
613(This minor mode is the 'adaptive-wrap' ELPA package renamed and 635(This minor mode is the 'adaptive-wrap' ELPA package renamed and
614lightly edited for inclusion in Emacs.) 636lightly edited for inclusion in Emacs.)
615 637
616--- 638+++
617** New global minor mode 'kill-ring-deindent-mode'. 639** New global minor mode 'kill-ring-deindent-mode'.
618When enabled, text being saved to the kill ring will be de-indented by 640When enabled, text being saved to the kill ring will be de-indented by
619the column number at its start. For example, saving the entire 641the column number at its start. For example, saving the entire
620function call within: 642function call within an indented block:
621 643
622foo () 644foo ()
623{ 645{
@@ -626,16 +648,16 @@ foo ()
626 argument_3_compute ()); 648 argument_3_compute ());
627} 649}
628 650
629will save: 651will save this to the kill ring:
630 652
631long_function_with_several_arguments (argument_1_compute (), 653long_function_with_several_arguments (argument_1_compute (),
632 argument_2_compute (), 654 argument_2_compute (),
633 argument_3_compute ()) 655 argument_3_compute ())
634 656
635to the kill ring, omitting the two columns of extra indentation that 657This omits the two columns of extra indentation that would otherwise be
636would otherwise be present in the second and third lines of the 658copied from the second and third lines and saved to the kill ring.
637function call.
638 659
660---
639** New command 'replace-regexp-as-diff'. 661** New command 'replace-regexp-as-diff'.
640It reads a regexp to search for and a string to replace with, then 662It reads a regexp to search for and a string to replace with, then
641displays a buffer with replacements as diffs. After reviewing the 663displays a buffer with replacements as diffs. After reviewing the
@@ -706,6 +728,7 @@ whereas if the mouse pointer is in the left half of a glyph, point
706will be put in front the buffer position corresponding to that glyph. 728will be put in front the buffer position corresponding to that glyph.
707By default this is disabled. 729By default this is disabled.
708 730
731---
709** New pre-defined values for 'electric-quote-chars'. 732** New pre-defined values for 'electric-quote-chars'.
710The available customization options for 'electric-quote-chars' have been 733The available customization options for 'electric-quote-chars' have been
711updated with common pairs of quotation characters, including "‘", "’", 734updated with common pairs of quotation characters, including "‘", "’",
@@ -713,7 +736,7 @@ updated with common pairs of quotation characters, including "‘", "’",
713The default is unchanged. 736The default is unchanged.
714 737
715+++ 738+++
716** 'M-TAB' now invokes 'completion-at-point' also in Text mode. 739** 'M-TAB' now invokes 'completion-at-point' in Text mode.
717By default, Text mode no longer binds 'M-TAB' to 'ispell-complete-word'. 740By default, Text mode no longer binds 'M-TAB' to 'ispell-complete-word'.
718Instead, this mode arranges for 'completion-at-point', globally bound to 741Instead, this mode arranges for 'completion-at-point', globally bound to
719'M-TAB', to perform word completion as well. You can have Text mode 742'M-TAB', to perform word completion as well. You can have Text mode
@@ -764,14 +787,17 @@ These languages are spoken in Pakistan and Afghanistan.
764*** New input method "english-colemak". 787*** New input method "english-colemak".
765This input method supports the Colemak keyboard layout. 788This input method supports the Colemak keyboard layout.
766 789
790---
767*** Additional 'C-x 8' key translations for "æ" and "Æ". 791*** Additional 'C-x 8' key translations for "æ" and "Æ".
768These characters can now be input with 'C-x 8 a e' and 'C-x 8 A E', 792These characters can now be input with 'C-x 8 a e' and 'C-x 8 A E',
769respectively, in addition to the existing translations 'C-x 8 / e' and 793respectively, in addition to the existing translations 'C-x 8 / e' and
770'C-x 8 / E'. 794'C-x 8 / E'.
771 795
796---
772*** New 'C-x 8' key translations for "low" quotes "„", and "‚". 797*** New 'C-x 8' key translations for "low" quotes "„", and "‚".
773These can now be entered with 'C-x , "' and 'C-x , ''. 798These can now be entered with 'C-x , "' and 'C-x , ''.
774 799
800---
775*** New German language 'C-x 8' key translations for quotation marks. 801*** New German language 'C-x 8' key translations for quotation marks.
776The characters "„", "“", and "”" can now be entered with 'C-x 8 v', 802The characters "„", "“", and "”" can now be entered with 'C-x 8 v',
777'C-x 8 b' and 'C-x 8 n'. The single versions "‚", "‘", and "’" can now 803'C-x 8 b' and 'C-x 8 n'. The single versions "‚", "‘", and "’" can now
@@ -779,6 +805,7 @@ be entered with 'C-x 8 V', 'C-x 8 B' and 'C-x 8 N'. These characters
779are used for the official German quoting style. Using them requires 805are used for the official German quoting style. Using them requires
780activating German language support via 'iso-transl-set-language'. 806activating German language support via 'iso-transl-set-language'.
781 807
808---
782*** "latin-prefix" and "latin-postfix" quotation marks additions. 809*** "latin-prefix" and "latin-postfix" quotation marks additions.
783These input methods can now produce single, double and "low" left and 810These input methods can now produce single, double and "low" left and
784right quotation marks: 811right quotation marks:
@@ -788,17 +815,20 @@ right quotation marks:
788by using "[", "]", and "," for "left", "right", and "low" respectively 815by using "[", "]", and "," for "left", "right", and "low" respectively
789to modify "'" and """. 816to modify "'" and """.
790 817
818---
791*** "latin-prefix" and "latin-postfix" guillemets support. 819*** "latin-prefix" and "latin-postfix" guillemets support.
792These input methods can now produce single guillemets "‹" and "›". For 820These input methods can now produce single guillemets "‹" and "›". For
793"latin-prefix" use "~~<" and "~~>", for "latin-postfix" use "<~" and 821"latin-prefix" use "~~<" and "~~>", for "latin-postfix" use "<~" and
794">~". Double guillemets ("«" and "»") were already supported. 822">~". Double guillemets ("«" and "»") were already supported.
795 823
824---
796*** New French language 'C-x 8' key translations for "‹" and "›". 825*** New French language 'C-x 8' key translations for "‹" and "›".
797These characters can now be entered using 'C-x 8 ~ <' and 'C-x 8 ~ >' 826These characters can now be entered using 'C-x 8 ~ <' and 'C-x 8 ~ >'
798respectively, after activating French language support via 827respectively, after activating French language support via
799'iso-transl-set-language'. Double guillemets were already supported via 828'iso-transl-set-language'. Double guillemets were already supported via
800'C-x 8 <' and 'C-x 8 >' 829'C-x 8 <' and 'C-x 8 >'
801 830
831---
802*** Additional 'C-x 8' key translation for Euro "€" currency symbol. 832*** Additional 'C-x 8' key translation for Euro "€" currency symbol.
803This can now be entered using 'C-x 8 E' in addition to the existing 833This can now be entered using 'C-x 8 E' in addition to the existing
804'C-x 8 * E' translation. 834'C-x 8 * E' translation.
@@ -808,11 +838,12 @@ This can now be entered using 'C-x 8 E' in addition to the existing
808 838
809** Outline mode 839** Outline mode
810 840
841+++
811*** New commands to show/hide outlines by regexp. 842*** New commands to show/hide outlines by regexp.
812'/ h' ('outline-hide-by-heading-regexp') asks for a regexp and then 843'C-c / h' ('outline-hide-by-heading-regexp') asks for a regexp and then
813hides the body lines of all outlines whose heading lines match the 844hides the body lines of all outlines whose heading lines match the
814regexp. '/ s' ('outline-show-by-heading-regexp') does the same but 845regexp. 'C-c / s' ('outline-show-by-heading-regexp') does the inverse:
815shows the matched outlines. 846it shows the bodies of outlines that matched a regexp.
816 847
817+++ 848+++
818*** 'outline-minor-mode' is supported in tree-sitter major modes. 849*** 'outline-minor-mode' is supported in tree-sitter major modes.
@@ -828,6 +859,7 @@ This user option associates manual names with URLs. It affects the
828Emacs-included manuals are set. Further associations can be added for 859Emacs-included manuals are set. Further associations can be added for
829arbitrary Info manuals. 860arbitrary Info manuals.
830 861
862---
831*** Emacs can now display Info manuals compressed with 'lzip'. 863*** Emacs can now display Info manuals compressed with 'lzip'.
832This requires the 'lzip' program to be installed on your system. 864This requires the 'lzip' program to be installed on your system.
833 865
@@ -859,7 +891,7 @@ If you want to get back the old behavior, set the user option to the value
859 (setopt gdb-locals-table-row-config 891 (setopt gdb-locals-table-row-config
860 `((type . 0) (name . 0) (value . ,gdb-locals-value-limit))) 892 `((type . 0) (name . 0) (value . ,gdb-locals-value-limit)))
861 893
862--- 894+++
863*** New user option 'gdb-display-io-buffer'. 895*** New user option 'gdb-display-io-buffer'.
864If this is nil, 'M-x gdb' will neither create nor display a separate 896If this is nil, 'M-x gdb' will neither create nor display a separate
865buffer for the I/O of the program being debugged, but will instead 897buffer for the I/O of the program being debugged, but will instead
@@ -868,11 +900,13 @@ default is t, to preserve previous behavior.
868 900
869** Grep 901** Grep
870 902
903+++
871*** New user option 'grep-use-headings'. 904*** New user option 'grep-use-headings'.
872When non-nil, the output of Grep is split into sections, one for each 905When non-nil, the output of Grep is split into sections, one for each
873file, instead of having file names prefixed to each line. It is 906file, instead of having file names prefixed to each line. It is
874equivalent to the "--heading" option of some tools such as 'git grep' 907equivalent to the "--heading" option of some tools such as 'git grep'
875and 'rg'. The headings are displayed using the new 'grep-heading' face. 908and 'rg'. The headings are displayed using the new 'grep-heading' face.
909The default is nil.
876 910
877** Compilation mode 911** Compilation mode
878 912
@@ -882,6 +916,7 @@ This is because it partly acts by modifying other rules which may
882occasionally be surprising. It can be re-enabled by adding 'omake' to 916occasionally be surprising. It can be re-enabled by adding 'omake' to
883'compilation-error-regexp-alist'. 917'compilation-error-regexp-alist'.
884 918
919---
885*** Lua errors and stack traces are now recognized. 920*** Lua errors and stack traces are now recognized.
886Compilation mode now recognizes Lua language errors and stack traces. 921Compilation mode now recognizes Lua language errors and stack traces.
887Every Lua error is recognized as a compilation error, and every Lua 922Every Lua error is recognized as a compilation error, and every Lua
@@ -895,22 +930,26 @@ When non-nil, display the name of the current project on the mode
895line. Clicking 'mouse-1' on the project name pops up the project 930line. Clicking 'mouse-1' on the project name pops up the project
896menu. The default value is nil. 931menu. The default value is nil.
897 932
933---
898*** New user option 'project-file-history-behavior'. 934*** New user option 'project-file-history-behavior'.
899Customizing it to 'relativize' makes commands like 'project-find-file' 935Customizing it to 'relativize' makes commands like 'project-find-file'
900and 'project-find-dir' display previous history entries relative to 936and 'project-find-dir' display previous history entries relative to
901the current project. 937the current project.
902 938
939--
903*** New user option 'project-key-prompt-style'. 940*** New user option 'project-key-prompt-style'.
904The look of the key prompt in the project switcher has been changed 941The look of the key prompt in the project switcher has been changed
905slightly. To get the previous one, set this option to 'brackets'. 942slightly. To get the previous one, set this option to 'brackets'.
906 943
944---
907*** 'project-try-vc' tries harder to find the responsible VCS. 945*** 'project-try-vc' tries harder to find the responsible VCS.
908When 'project-vc-extra-root-markers' is non-nil, and causes a 946When 'project-vc-extra-root-markers' is non-nil, and causes a
909subdirectory project to be detected which is not a VCS root, we now 947subdirectory project to be detected which is not a VCS root, Project now
910additionally traverse the parent directories until a VCS root is found 948additionally traverses the parent directories until a VCS root is found
911(if any), so that the ignore rules for that repository are used, and 949(if any), so that the ignore rules for that repository are used, and
912the file listing's performance is still optimized. 950the file listing's performance is still optimized.
913 951
952+++
914*** New commands 'project-any-command' and 'project-prefix-or-any-command'. 953*** New commands 'project-any-command' and 'project-prefix-or-any-command'.
915The former is now bound to 'C-x p o' by default. 954The former is now bound to 'C-x p o' by default.
916The latter is designed primarily for use as a value of 955The latter is designed primarily for use as a value of
@@ -948,15 +987,16 @@ With this value only the revision number is displayed on the mode-line.
948*** Obsolete command 'vc-switch-backend' re-added as 'vc-change-backend'. 987*** Obsolete command 'vc-switch-backend' re-added as 'vc-change-backend'.
949The command was previously obsoleted and unbound in Emacs 28. 988The command was previously obsoleted and unbound in Emacs 28.
950 989
990---
951*** Support for viewing VC change history across renames. 991*** Support for viewing VC change history across renames.
952When a fileset's VC change history ('C-x v l') ends at a rename, we 992When a fileset's VC change history ends at a rename, ('C-x v l') now
953now print the old name(s) and a button which jumps to their history. 993prints the old name(s) and shows a button which jumps to the history of
954Git and Hg are supported. Naturally, 'vc-git-print-log-follow' should 994the files under the old names. This feature is supported for Git and
955be nil for this to work (or '--follow' should not be in 995Hg. Naturally, 'vc-git-print-log-follow' should be nil for this to work
956'vc-hg-print-log-switches', in Hg's case). Unlike when the '--follow' 996(or '--follow' should not be in 'vc-hg-print-log-switches', in Hg's
957switch is used, commands to see the diff of the old revision ('d'), 997case). Unlike when the '--follow' switch is used, commands to see the
958check out an old file version ('f') or annotate it right away ('a'), 998diff of the old revision ('d'), to check out an old file version ('f')
959also work on revisions which precede renames. 999or to annotate it ('a'), also work on revisions which precede renames.
960 1000
961--- 1001---
962*** 'vc-annotate' now abbreviates the Git revision in the buffer name. 1002*** 'vc-annotate' now abbreviates the Git revision in the buffer name.
@@ -964,6 +1004,7 @@ When using the Git backend, 'vc-annotate' will use an abbreviated
964revision identifier in its buffer name. To restore the previous 1004revision identifier in its buffer name. To restore the previous
965behavior, set 'vc-annotate-use-short-revision' to nil. 1005behavior, set 'vc-annotate-use-short-revision' to nil.
966 1006
1007---
967*** New option 'vc-git-file-name-changes-switches'. 1008*** New option 'vc-git-file-name-changes-switches'.
968It allows tweaking the thresholds for rename and copy detection. 1009It allows tweaking the thresholds for rename and copy detection.
969 1010
@@ -989,6 +1030,7 @@ This allows changing which type of whitespace changes are ignored when
989regenerating hunks with 'diff-ignore-whitespace-hunk'. Defaults to 1030regenerating hunks with 'diff-ignore-whitespace-hunk'. Defaults to
990the previously hard-coded "-b". 1031the previously hard-coded "-b".
991 1032
1033+++
992*** New command 'diff-apply-buffer' bound to 'C-c RET a'. 1034*** New command 'diff-apply-buffer' bound to 'C-c RET a'.
993It applies the diff in the entire diff buffer and 1035It applies the diff in the entire diff buffer and
994saves all modified file buffers. 1036saves all modified file buffers.
@@ -1003,6 +1045,7 @@ It also controls how to move point when encountering a boundary
1003(e.g., if every line is visible, invoking 'dired-next-line' at 1045(e.g., if every line is visible, invoking 'dired-next-line' at
1004the last line will move to the first line). The default is nil. 1046the last line will move to the first line). The default is nil.
1005 1047
1048---
1006*** New user option 'dired-filename-display-length'. 1049*** New user option 'dired-filename-display-length'.
1007It is an integer representing the maximum display length of filenames. 1050It is an integer representing the maximum display length of filenames.
1008The middle part of a filename whose length exceeds the restriction is 1051The middle part of a filename whose length exceeds the restriction is
@@ -1010,6 +1053,7 @@ hidden and an ellipsis is displayed instead. A value of 'window'
1010means using the right edge of window as the display restriction. The 1053means using the right edge of window as the display restriction. The
1011default is nil. 1054default is nil.
1012 1055
1056---
1013*** New user option 'shell-command-guess-functions'. 1057*** New user option 'shell-command-guess-functions'.
1014It defines how to populate a list of commands available 1058It defines how to populate a list of commands available
1015for 'M-!', 'M-&', '!', '&' and the context menu "Open With" 1059for 'M-!', 'M-&', '!', '&' and the context menu "Open With"
@@ -1018,16 +1062,19 @@ based on marked files in Dired. Possible backends are
1018and a universal command such as "open" or "start" 1062and a universal command such as "open" or "start"
1019that delegates to the OS. 1063that delegates to the OS.
1020 1064
1065+++
1021*** New command 'dired-do-open'. 1066*** New command 'dired-do-open'.
1022This command is bound to 'E' (mnemonics "External"). Also it can be 1067This command is bound to 'E' (mnemonics "External"). Also it can be
1023used by clicking "Open" in the context menu; it "opens" the marked or 1068used by clicking "Open" in the context menu; it "opens" the marked or
1024clicked on files according to the OS conventions. For example, on 1069clicked on files according to the OS conventions. For example, on
1025systems supporting XDG, this runs 'xdg-open' on the files. 1070systems supporting XDG, this runs 'xdg-open' on the files.
1026 1071
1072+++
1027*** New variable 'dired-guess-shell-alist-optional'. 1073*** New variable 'dired-guess-shell-alist-optional'.
1028It contains commands for external viewers and players for various media 1074It contains commands for external viewers and players for various media
1029formats, moved to this list from 'dired-guess-shell-alist-default'. 1075formats, moved to this list from 'dired-guess-shell-alist-default'.
1030 1076
1077---
1031*** The default value of 'dired-omit-size-limit' was increased. 1078*** The default value of 'dired-omit-size-limit' was increased.
1032After performance improvements to omitting in large directories, the new 1079After performance improvements to omitting in large directories, the new
1033default value is 300k, up from 100k. This means 'dired-omit-mode' will 1080default value is 300k, up from 100k. This means 'dired-omit-mode' will
diff --git a/java/res/drawable/emacs_background.xml b/java/res/drawable/emacs_background.xml
index 448ca48d1cb..c6b6decc3b0 100644
--- a/java/res/drawable/emacs_background.xml
+++ b/java/res/drawable/emacs_background.xml
@@ -21,22 +21,26 @@ along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>. -->
21 xmlns:aapt="http://schemas.android.com/aapt" 21 xmlns:aapt="http://schemas.android.com/aapt"
22 android:width="108dp" 22 android:width="108dp"
23 android:height="108dp" 23 android:height="108dp"
24 android:viewportWidth="512" 24 android:viewportWidth="108"
25 android:viewportHeight="512"> 25 android:viewportHeight="108">
26 <path 26 <path android:pathData="M0,0h108v108h-108z"
27 android:pathData="M-4.99,-5.79h521.12v526.76h-521.12z" 27 android:strokeWidth="0"
28 android:strokeWidth="10.6667"> 28 android:strokeColor="#00000000">
29 <aapt:attr name="android:fillColor"> 29 <aapt:attr name="android:fillColor">
30 <gradient 30 <gradient android:startX="28.44"
31 android:startX="0" 31 android:startY="22.95"
32 android:startY="0" 32 android:endX="75.57"
33 android:endX="512" 33 android:endY="86.47"
34 android:endY="512" 34 android:type="linear">
35 android:type="linear">
36 <item android:offset="0" android:color="#FF8381C5"/> 35 <item android:offset="0" android:color="#FF8381C5"/>
37 <item android:offset="0.64" android:color="#FE806BBC"/> 36 <item android:offset="0.64" android:color="#FE7E55B3"/>
38 <item android:offset="1" android:color="#FDA52ECB"/> 37 <item android:offset="1" android:color="#FDA52ECB"/>
39 </gradient> 38 </gradient>
40 </aapt:attr> 39 </aapt:attr>
41 </path> 40 </path>
41 <path
42 android:pathData="m0,0v108h108v-108zM54,21a33,33 0,0 1,33 33,33 33,0 0,1 -33,33 33,33 0,0 1,-33 -33,33 33,0 0,1 33,-33z"
43 android:strokeWidth="0"
44 android:fillColor="#ffffff"
45 android:strokeColor="#ffffff"/>
42</vector> 46</vector>
diff --git a/java/res/drawable/emacs_foreground.xml b/java/res/drawable/emacs_foreground.xml
index d4d71f8e29a..06a03240e28 100644
--- a/java/res/drawable/emacs_foreground.xml
+++ b/java/res/drawable/emacs_foreground.xml
@@ -21,19 +21,13 @@ along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>. -->
21 xmlns:aapt="http://schemas.android.com/aapt" 21 xmlns:aapt="http://schemas.android.com/aapt"
22 android:width="108dp" 22 android:width="108dp"
23 android:height="108dp" 23 android:height="108dp"
24 android:viewportWidth="512" 24 android:viewportWidth="108"
25 android:viewportHeight="512"> 25 android:viewportHeight="108">
26 <group android:scaleX="0.6" 26 <path android:pathData="m44.28,77.94c0,0 2.74,0.2 6.25,-0.12 1.42,-0.13 6.84,-0.67 10.88,-1.57 0,0 4.93,-1.08 7.57,-2.07 2.76,-1.04 4.26,-1.92 4.94,-3.17 -0.03,-0.26 0.21,-1.16 -1.06,-1.71C69.6,67.91 65.83,68.17 58.36,68 50.07,67.71 47.32,66.3 45.85,65.16 44.44,64.01 45.15,60.81 51.18,57.99 54.22,56.5 66.13,53.73 66.13,53.73 62.12,51.71 54.64,48.15 53.1,47.39 51.75,46.71 49.6,45.7 49.13,44.47c-0.53,-1.18 1.25,-2.19 2.25,-2.48 3.21,-0.94 7.73,-1.53 11.86,-1.6 2.07,-0.03 2.41,-0.17 2.41,-0.17 2.86,-0.48 4.74,-2.48 3.96,-5.64 -0.7,-3.22 -4.42,-5.12 -7.94,-4.46 -3.32,0.62 -11.33,2.99 -11.33,2.99 9.89,-0.09 11.55,0.08 12.29,1.14 0.44,0.62 -0.2,1.48 -2.84,1.92 -2.87,0.48 -8.85,1.05 -8.85,1.05 -5.73,0.35 -9.76,0.37 -10.98,2.98 -0.79,1.71 0.84,3.22 1.56,4.16 3.03,3.43 7.4,5.28 10.21,6.65 1.06,0.51 4.17,1.48 4.17,1.48 -9.13,-0.51 -15.71,2.35 -19.58,5.64 -4.37,4.12 -2.44,9.03 6.51,12.06 5.29,1.79 7.91,2.63 15.79,1.9 4.64,-0.26 5.38,-0.1 5.42,0.29 0.07,0.55 -5.16,1.91 -6.59,2.33 -3.63,1.07 -13.14,3.22 -13.19,3.23z"
27 android:scaleY="0.6" 27 android:strokeLineJoin="miter"
28 android:translateX="102.4" 28 android:strokeWidth="0"
29 android:translateY="102.4"> 29 android:fillColor="#ffffff"
30 <path 30 android:strokeColor="#00000000"
31 android:pathData="m174.83,422.11c0,0 19.74,1.4 45.13,-0.84 10.28,-0.91 49.33,-4.74 78.52,-11.14 0,0 35.59,-7.62 54.63,-14.63 19.92,-7.34 30.76,-13.57 35.64,-22.4 -0.21,-1.81 1.5,-8.22 -7.68,-12.08 -23.49,-9.85 -50.73,-8.07 -104.63,-9.21 -59.78,-2.05 -79.66,-12.06 -90.26,-20.12 -10.16,-8.18 -5.05,-30.79 38.47,-50.71 21.92,-10.61 107.87,-30.19 107.87,-30.19 -28.95,-14.31 -82.92,-39.46 -94.01,-44.89 -9.73,-4.76 -25.3,-11.94 -28.68,-20.61 -3.83,-8.33 9.04,-15.51 16.22,-17.56 23.14,-6.68 55.82,-10.83 85.55,-11.29 14.95,-0.23 17.37,-1.2 17.37,-1.2 20.62,-3.42 34.2,-17.53 28.54,-39.88 -5.08,-22.81 -31.86,-36.21 -57.31,-31.57 -23.97,4.37 -81.74,21.15 -81.74,21.15 71.41,-0.62 83.36,0.57 88.7,8.04 3.15,4.41 -1.43,10.45 -20.48,13.56 -20.73,3.39 -63.83,7.46 -63.83,7.46 -41.34,2.46 -70.47,2.62 -79.2,21.11 -5.71,12.08 6.09,22.76 11.25,29.45 21.84,24.29 53.39,37.39 73.69,47.04 7.64,3.63 30.06,10.48 30.06,10.48 -65.88,-3.62 -113.4,16.61 -141.28,39.9 -31.53,29.16 -17.58,63.92 47.01,85.33 38.15,12.64 57.07,18.59 113.98,13.46 33.52,-1.81 38.8,-0.73 39.14,2.02 0.47,3.87 -37.23,13.49 -47.52,16.46 -26.19,7.55 -94.83,22.8 -95.17,22.88z" 31 android:fillType="evenOdd"
32 android:strokeLineJoin="miter" 32 android:strokeLineCap="butt"/>
33 android:strokeWidth="0"
34 android:fillColor="#ffffff"
35 android:strokeColor="#a0000000"
36 android:fillType="evenOdd"
37 android:strokeLineCap="butt"/>
38 </group>
39</vector> 33</vector>
diff --git a/src/emacs.c b/src/emacs.c
index 77929817447..22b7a4f1038 100644
--- a/src/emacs.c
+++ b/src/emacs.c
@@ -1395,6 +1395,10 @@ main (int argc, char **argv)
1395 the additional call here is harmless.) */ 1395 the additional call here is harmless.) */
1396 cache_system_info (); 1396 cache_system_info ();
1397#ifdef WINDOWSNT 1397#ifdef WINDOWSNT
1398 /* This must be called to initialize w32_unicode_filenames and
1399 is_windows_9x prior to w32_init_current_directory. */
1400 globals_of_w32 ();
1401
1398 /* On Windows 9X, we have to load UNICOWS.DLL as early as possible, 1402 /* On Windows 9X, we have to load UNICOWS.DLL as early as possible,
1399 to have non-stub implementations of APIs we need to convert file 1403 to have non-stub implementations of APIs we need to convert file
1400 names between UTF-8 and the system's ANSI codepage. */ 1404 names between UTF-8 and the system's ANSI codepage. */
@@ -1506,11 +1510,10 @@ main (int argc, char **argv)
1506 } 1510 }
1507 } 1511 }
1508#endif 1512#endif
1509
1510 emacs_wd = emacs_get_current_dir_name (); 1513 emacs_wd = emacs_get_current_dir_name ();
1511#ifdef WINDOWSNT 1514#ifdef WINDOWSNT
1512 initial_wd = emacs_wd; 1515 initial_wd = emacs_wd;
1513#endif 1516#endif /* WINDOWSNT */
1514#ifdef HAVE_PDUMPER 1517#ifdef HAVE_PDUMPER
1515 if (dumped_with_pdumper_p ()) 1518 if (dumped_with_pdumper_p ())
1516 pdumper_record_wd (emacs_wd); 1519 pdumper_record_wd (emacs_wd);
@@ -2165,7 +2168,6 @@ Using an Emacs configured with --with-x-toolkit=lucid does not have this problem
2165 init_atimer (); 2168 init_atimer ();
2166 2169
2167#ifdef WINDOWSNT 2170#ifdef WINDOWSNT
2168 globals_of_w32 ();
2169#ifdef HAVE_W32NOTIFY 2171#ifdef HAVE_W32NOTIFY
2170 globals_of_w32notify (); 2172 globals_of_w32notify ();
2171#endif 2173#endif
diff --git a/src/w32.c b/src/w32.c
index 1c6a56bcbd9..4986d4c6676 100644
--- a/src/w32.c
+++ b/src/w32.c
@@ -10624,6 +10624,7 @@ maybe_load_unicows_dll (void)
10624 pWideCharToMultiByte = (WideCharToMultiByte_Proc) 10624 pWideCharToMultiByte = (WideCharToMultiByte_Proc)
10625 get_proc_addr (ret, "WideCharToMultiByte"); 10625 get_proc_addr (ret, "WideCharToMultiByte");
10626 multiByteToWideCharFlags = MB_ERR_INVALID_CHARS; 10626 multiByteToWideCharFlags = MB_ERR_INVALID_CHARS;
10627 load_unicows_dll_for_w32fns (ret);
10627 return ret; 10628 return ret;
10628 } 10629 }
10629 else 10630 else
@@ -10658,6 +10659,7 @@ maybe_load_unicows_dll (void)
10658 multiByteToWideCharFlags = 0; 10659 multiByteToWideCharFlags = 0;
10659 else 10660 else
10660 multiByteToWideCharFlags = MB_ERR_INVALID_CHARS; 10661 multiByteToWideCharFlags = MB_ERR_INVALID_CHARS;
10662 load_unicows_dll_for_w32fns (NULL);
10661 return LoadLibrary ("Gdi32.dll"); 10663 return LoadLibrary ("Gdi32.dll");
10662 } 10664 }
10663} 10665}
diff --git a/src/w32.h b/src/w32.h
index cf470ae9901..3dc79dabf4b 100644
--- a/src/w32.h
+++ b/src/w32.h
@@ -170,6 +170,7 @@ extern void release_listen_threads (void);
170extern void init_ntproc (int); 170extern void init_ntproc (int);
171extern void term_ntproc (int); 171extern void term_ntproc (int);
172extern HANDLE maybe_load_unicows_dll (void); 172extern HANDLE maybe_load_unicows_dll (void);
173extern void load_unicows_dll_for_w32fns (HMODULE);
173extern void globals_of_w32 (void); 174extern void globals_of_w32 (void);
174 175
175extern void term_timers (void); 176extern void term_timers (void);
diff --git a/src/w32fns.c b/src/w32fns.c
index 4c2f18abd08..6090eb34e82 100644
--- a/src/w32fns.c
+++ b/src/w32fns.c
@@ -2612,6 +2612,7 @@ my_post_msg (W32Msg * wmsg, HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
2612} 2612}
2613 2613
2614#ifdef WINDOWSNT 2614#ifdef WINDOWSNT
2615
2615/* The Windows keyboard hook callback. */ 2616/* The Windows keyboard hook callback. */
2616static LRESULT CALLBACK 2617static LRESULT CALLBACK
2617funhook (int code, WPARAM w, LPARAM l) 2618funhook (int code, WPARAM w, LPARAM l)
@@ -2688,8 +2689,8 @@ funhook (int code, WPARAM w, LPARAM l)
2688 can prevent this by setting the 2689 can prevent this by setting the
2689 w32-pass-[lr]window-to-system variable to 2690 w32-pass-[lr]window-to-system variable to
2690 NIL. */ 2691 NIL. */
2691 if ((hs->vkCode == VK_LWIN && !NILP (Vw32_pass_lwindow_to_system)) || 2692 if ((hs->vkCode == VK_LWIN && !NILP (Vw32_pass_lwindow_to_system))
2692 (hs->vkCode == VK_RWIN && !NILP (Vw32_pass_rwindow_to_system))) 2693 || (hs->vkCode == VK_RWIN && !NILP (Vw32_pass_rwindow_to_system)))
2693 { 2694 {
2694 /* Not prevented - Simulate the keypress to the system. */ 2695 /* Not prevented - Simulate the keypress to the system. */
2695 memset (inputs, 0, sizeof (inputs)); 2696 memset (inputs, 0, sizeof (inputs));
@@ -2704,7 +2705,6 @@ funhook (int code, WPARAM w, LPARAM l)
2704 inputs[1].ki.dwFlags 2705 inputs[1].ki.dwFlags
2705 = KEYEVENTF_EXTENDEDKEY | KEYEVENTF_KEYUP; 2706 = KEYEVENTF_EXTENDEDKEY | KEYEVENTF_KEYUP;
2706 inputs[1].ki.time = 0; 2707 inputs[1].ki.time = 0;
2707 SendInput (2, inputs, sizeof (INPUT));
2708 } 2708 }
2709 else if (focus != NULL) 2709 else if (focus != NULL)
2710 { 2710 {
@@ -6150,7 +6150,8 @@ DEFUN ("x-create-frame", Fx_create_frame, Sx_create_frame,
6150 if (harfbuzz_available) 6150 if (harfbuzz_available)
6151 register_font_driver (&harfbuzz_font_driver, f); 6151 register_font_driver (&harfbuzz_font_driver, f);
6152#endif 6152#endif
6153 register_font_driver (&uniscribe_font_driver, f); 6153 if (uniscribe_available)
6154 register_font_driver (&uniscribe_font_driver, f);
6154 register_font_driver (&w32font_driver, f); 6155 register_font_driver (&w32font_driver, f);
6155 6156
6156 gui_default_parameter (f, parameters, Qfont_backend, Qnil, 6157 gui_default_parameter (f, parameters, Qfont_backend, Qnil,
@@ -7227,7 +7228,8 @@ w32_create_tip_frame (struct w32_display_info *dpyinfo, Lisp_Object parms)
7227 if (harfbuzz_available) 7228 if (harfbuzz_available)
7228 register_font_driver (&harfbuzz_font_driver, f); 7229 register_font_driver (&harfbuzz_font_driver, f);
7229#endif 7230#endif
7230 register_font_driver (&uniscribe_font_driver, f); 7231 if (uniscribe_available)
7232 register_font_driver (&uniscribe_font_driver, f);
7231 register_font_driver (&w32font_driver, f); 7233 register_font_driver (&w32font_driver, f);
7232 7234
7233 gui_default_parameter (f, parms, Qfont_backend, Qnil, 7235 gui_default_parameter (f, parms, Qfont_backend, Qnil,
@@ -8265,6 +8267,8 @@ DEFUN ("x-file-dialog", Fx_file_dialog, Sx_file_dialog, 2, 5, 0,
8265 8267
8266 8268
8267#ifdef WINDOWSNT 8269#ifdef WINDOWSNT
8270static int (WINAPI *pfnSHFileOperationW) (LPSHFILEOPSTRUCTW);
8271
8268/* Moving files to the system recycle bin. 8272/* Moving files to the system recycle bin.
8269 Used by `move-file-to-trash' instead of the default moving to ~/.Trash */ 8273 Used by `move-file-to-trash' instead of the default moving to ~/.Trash */
8270DEFUN ("system-move-file-to-trash", Fsystem_move_file_to_trash, 8274DEFUN ("system-move-file-to-trash", Fsystem_move_file_to_trash,
@@ -8276,6 +8280,9 @@ DEFUN ("system-move-file-to-trash", Fsystem_move_file_to_trash,
8276 Lisp_Object encoded_file; 8280 Lisp_Object encoded_file;
8277 Lisp_Object operation; 8281 Lisp_Object operation;
8278 8282
8283 /* Required on Windows 9X. */
8284 maybe_load_unicows_dll ();
8285
8279 operation = Qdelete_file; 8286 operation = Qdelete_file;
8280 if (!NILP (Ffile_directory_p (filename)) 8287 if (!NILP (Ffile_directory_p (filename))
8281 && NILP (Ffile_symlink_p (filename))) 8288 && NILP (Ffile_symlink_p (filename)))
@@ -8324,7 +8331,10 @@ DEFUN ("system-move-file-to-trash", Fsystem_move_file_to_trash,
8324 | FOF_NOERRORUI | FOF_NO_CONNECTED_ELEMENTS; 8331 | FOF_NOERRORUI | FOF_NO_CONNECTED_ELEMENTS;
8325 file_op_w.fAnyOperationsAborted = FALSE; 8332 file_op_w.fAnyOperationsAborted = FALSE;
8326 8333
8327 result = SHFileOperationW (&file_op_w); 8334 /* This is stated to exist on all versions of Windows NT Emacs
8335 supports. */
8336 eassert (pfnSHFileOperationW);
8337 result = (*pfnSHFileOperationW) (&file_op_w);
8328 } 8338 }
8329 else 8339 else
8330 { 8340 {
@@ -8389,6 +8399,10 @@ If optional parameter FRAME is not specified, use selected frame. */)
8389 return Qnil; 8399 return Qnil;
8390} 8400}
8391 8401
8402#ifndef CYGWIN
8403static BOOL (WINAPI *pfnShellExecuteExW) (LPSHELLEXECUTEINFOW);
8404#endif /* !CYGWIN */
8405
8392DEFUN ("w32-shell-execute", Fw32_shell_execute, Sw32_shell_execute, 2, 4, 0, 8406DEFUN ("w32-shell-execute", Fw32_shell_execute, Sw32_shell_execute, 2, 4, 0,
8393 doc: /* Get Windows to perform OPERATION on DOCUMENT. 8407 doc: /* Get Windows to perform OPERATION on DOCUMENT.
8394This is a wrapper around the ShellExecute system function, which 8408This is a wrapper around the ShellExecute system function, which
@@ -8539,6 +8553,9 @@ a ShowWindow flag:
8539 const int file_url_len = sizeof (file_url_str) - 1; 8553 const int file_url_len = sizeof (file_url_str) - 1;
8540 int doclen; 8554 int doclen;
8541 8555
8556 /* Required on Windows 9X. */
8557 maybe_load_unicows_dll ();
8558
8542 if (strncmp (SSDATA (document), file_url_str, file_url_len) == 0) 8559 if (strncmp (SSDATA (document), file_url_str, file_url_len) == 0)
8543 { 8560 {
8544 /* Passing "file:///" URLs to ShellExecute causes shlwapi.dll to 8561 /* Passing "file:///" URLs to ShellExecute causes shlwapi.dll to
@@ -8598,7 +8615,7 @@ a ShowWindow flag:
8598 doc_w = xmalloc (doclen * sizeof (wchar_t)); 8615 doc_w = xmalloc (doclen * sizeof (wchar_t));
8599 pMultiByteToWideChar (CP_UTF8, multiByteToWideCharFlags, 8616 pMultiByteToWideChar (CP_UTF8, multiByteToWideCharFlags,
8600 SSDATA (document), -1, doc_w, doclen); 8617 SSDATA (document), -1, doc_w, doclen);
8601 if (use_unicode) 8618 if (use_unicode && pfnShellExecuteExW)
8602 { 8619 {
8603 wchar_t current_dir_w[MAX_PATH]; 8620 wchar_t current_dir_w[MAX_PATH];
8604 SHELLEXECUTEINFOW shexinfo_w; 8621 SHELLEXECUTEINFOW shexinfo_w;
@@ -8650,7 +8667,7 @@ a ShowWindow flag:
8650 shexinfo_w.lpDirectory = current_dir_w; 8667 shexinfo_w.lpDirectory = current_dir_w;
8651 shexinfo_w.nShow = 8668 shexinfo_w.nShow =
8652 (FIXNUMP (show_flag) ? XFIXNUM (show_flag) : SW_SHOWDEFAULT); 8669 (FIXNUMP (show_flag) ? XFIXNUM (show_flag) : SW_SHOWDEFAULT);
8653 success = ShellExecuteExW (&shexinfo_w); 8670 success = (*pfnShellExecuteExW) (&shexinfo_w);
8654 xfree (doc_w); 8671 xfree (doc_w);
8655 } 8672 }
8656 else 8673 else
@@ -9121,6 +9138,7 @@ and width values are in pixels.
9121 menu_bar.cbSize = sizeof (menu_bar); 9138 menu_bar.cbSize = sizeof (menu_bar);
9122 menu_bar.rcBar.right = menu_bar.rcBar.left = 0; 9139 menu_bar.rcBar.right = menu_bar.rcBar.left = 0;
9123 menu_bar.rcBar.top = menu_bar.rcBar.bottom = 0; 9140 menu_bar.rcBar.top = menu_bar.rcBar.bottom = 0;
9141
9124 GetMenuBarInfo (FRAME_W32_WINDOW (f), 0xFFFFFFFD, 0, &menu_bar); 9142 GetMenuBarInfo (FRAME_W32_WINDOW (f), 0xFFFFFFFD, 0, &menu_bar);
9125 single_menu_bar_height = GetSystemMetrics (SM_CYMENU); 9143 single_menu_bar_height = GetSystemMetrics (SM_CYMENU);
9126 wrapped_menu_bar_height = GetSystemMetrics (SM_CYMENUSIZE); 9144 wrapped_menu_bar_height = GetSystemMetrics (SM_CYMENUSIZE);
@@ -10007,6 +10025,8 @@ Internal use only. */)
10007 10025
10008#if defined WINDOWSNT && !defined HAVE_DBUS 10026#if defined WINDOWSNT && !defined HAVE_DBUS
10009 10027
10028static BOOL (WINAPI *pfnShell_NotifyIconW) (DWORD, PNOTIFYICONDATAW);
10029
10010/*********************************************************************** 10030/***********************************************************************
10011 Tray notifications 10031 Tray notifications
10012 ***********************************************************************/ 10032 ***********************************************************************/
@@ -10273,7 +10293,7 @@ add_tray_notification (struct frame *f, const char *icon, const char *tip,
10273 } 10293 }
10274 } 10294 }
10275 10295
10276 if (!Shell_NotifyIconW (NIM_ADD, (PNOTIFYICONDATAW)&nidw)) 10296 if (!(*pfnShell_NotifyIconW) (NIM_ADD, (PNOTIFYICONDATAW)&nidw))
10277 { 10297 {
10278 /* GetLastError returns meaningless results when 10298 /* GetLastError returns meaningless results when
10279 Shell_NotifyIcon fails. */ 10299 Shell_NotifyIcon fails. */
@@ -10305,7 +10325,7 @@ delete_tray_notification (struct frame *f, int id)
10305 nidw.hWnd = FRAME_W32_WINDOW (f); 10325 nidw.hWnd = FRAME_W32_WINDOW (f);
10306 nidw.uID = id; 10326 nidw.uID = id;
10307 10327
10308 if (!Shell_NotifyIconW (NIM_DELETE, (PNOTIFYICONDATAW)&nidw)) 10328 if (!(*pfnShell_NotifyIconW) (NIM_DELETE, (PNOTIFYICONDATAW)&nidw))
10309 { 10329 {
10310 /* GetLastError returns meaningless results when 10330 /* GetLastError returns meaningless results when
10311 Shell_NotifyIcon fails. */ 10331 Shell_NotifyIcon fails. */
@@ -10372,8 +10392,8 @@ The following parameters are supported:
10372 characters long, and will be truncated if it's longer. 10392 characters long, and will be truncated if it's longer.
10373 10393
10374Note that versions of Windows before W2K support only `:icon' and `:tip'. 10394Note that versions of Windows before W2K support only `:icon' and `:tip'.
10375You can pass the other parameters, but they will be ignored on those 10395You can pass the other parameters, but they will be ignored on
10376old systems. 10396those old systems.
10377 10397
10378There can be at most one active notification at any given time. An 10398There can be at most one active notification at any given time. An
10379active notification must be removed by calling `w32-notification-close' 10399active notification must be removed by calling `w32-notification-close'
@@ -10389,7 +10409,10 @@ usage: (w32-notification-notify &rest PARAMS) */)
10389 enum NI_Severity severity; 10409 enum NI_Severity severity;
10390 unsigned timeout = 0; 10410 unsigned timeout = 0;
10391 10411
10392 if (nargs == 0) 10412 /* Required on Windows 9X. */
10413 maybe_load_unicows_dll ();
10414
10415 if (nargs == 0 || !pfnShell_NotifyIconW)
10393 return Qnil; 10416 return Qnil;
10394 10417
10395 arg_plist = Flist (nargs, args); 10418 arg_plist = Flist (nargs, args);
@@ -10448,7 +10471,7 @@ DEFUN ("w32-notification-close",
10448{ 10471{
10449 struct frame *f = SELECTED_FRAME (); 10472 struct frame *f = SELECTED_FRAME ();
10450 10473
10451 if (FIXNUMP (id)) 10474 if (FIXNUMP (id) && !pfnShell_NotifyIconW)
10452 delete_tray_notification (f, XFIXNUM (id)); 10475 delete_tray_notification (f, XFIXNUM (id));
10453 10476
10454 return Qnil; 10477 return Qnil;
@@ -11499,7 +11522,7 @@ globals_of_w32fns (void)
11499 get_proc_addr (wtsapi32_lib, "WTSRegisterSessionNotification"); 11522 get_proc_addr (wtsapi32_lib, "WTSRegisterSessionNotification");
11500 WTSUnRegisterSessionNotification_fn = (WTSUnRegisterSessionNotification_Proc) 11523 WTSUnRegisterSessionNotification_fn = (WTSUnRegisterSessionNotification_Proc)
11501 get_proc_addr (wtsapi32_lib, "WTSUnRegisterSessionNotification"); 11524 get_proc_addr (wtsapi32_lib, "WTSUnRegisterSessionNotification");
11502#endif 11525#endif /* WINDOWSNT */
11503 11526
11504 /* Support OS dark mode on Windows 10 version 1809 and higher. 11527 /* Support OS dark mode on Windows 10 version 1809 and higher.
11505 See `w32_applytheme' which uses appropriate APIs per version of Windows. 11528 See `w32_applytheme' which uses appropriate APIs per version of Windows.
@@ -11580,6 +11603,32 @@ Changing the value takes effect only for frames created after the change. */);
11580 syms_of_w32uniscribe (); 11603 syms_of_w32uniscribe ();
11581} 11604}
11582 11605
11606#ifdef WINDOWSNT
11607
11608/* Initialize pointers to functions whose real implementations exist in
11609 UNICOWS.DLL on Windows 9X. UNICOWS should be a pointer to a loaded
11610 handle referencing UNICOWS.DLL, or NULL on Windows NT systems. */
11611
11612void
11613load_unicows_dll_for_w32fns (HMODULE unicows)
11614{
11615 if (!unicows)
11616 /* The functions following are defined by SHELL32.DLL onw Windows
11617 NT. */
11618 unicows = GetModuleHandle ("shell32");
11619
11620 pfnSHFileOperationW
11621 = (void *) get_proc_addr (unicows, "SHFileOperationW");
11622 pfnShellExecuteExW
11623 = (void *) get_proc_addr (unicows, "ShellExecuteExW");
11624#ifndef HAVE_DBUS
11625 pfnShell_NotifyIconW
11626 = (void *) get_proc_addr (unicows, "Shell_NotifyIconW");
11627#endif /* !HAVE_DBUS */
11628}
11629
11630#endif /* WINDOWSNT */
11631
11583#ifdef NTGUI_UNICODE 11632#ifdef NTGUI_UNICODE
11584 11633
11585Lisp_Object 11634Lisp_Object
diff --git a/src/w32notify.c b/src/w32notify.c
index c93e8796fe2..1001c85fdbe 100644
--- a/src/w32notify.c
+++ b/src/w32notify.c
@@ -120,6 +120,10 @@ struct notification {
120/* Used for communicating notifications to the main thread. */ 120/* Used for communicating notifications to the main thread. */
121struct notifications_set *notifications_set_head; 121struct notifications_set *notifications_set_head;
122 122
123/* Function pointers. */
124static BOOL (WINAPI *pfnReadDirectoryChangesW) (HANDLE, PVOID, DWORD, BOOL,
125 DWORD, PDWORD, LPOVERLAPPED,
126 LPOVERLAPPED_COMPLETION_ROUTINE);
123static Lisp_Object watch_list; 127static Lisp_Object watch_list;
124 128
125/* Signal to the main thread that we have file notifications for it to 129/* Signal to the main thread that we have file notifications for it to
@@ -252,10 +256,10 @@ watch_completion (DWORD status, DWORD bytes_ret, OVERLAPPED *io_info)
252 256
253 /* Calling ReadDirectoryChangesW quickly to watch again for new 257 /* Calling ReadDirectoryChangesW quickly to watch again for new
254 notifications. */ 258 notifications. */
255 if (!ReadDirectoryChangesW (dirwatch->dir, dirwatch->buf, 259 if (!(*pfnReadDirectoryChangesW) (dirwatch->dir, dirwatch->buf,
256 DIRWATCH_BUFFER_SIZE, dirwatch->subtree, 260 DIRWATCH_BUFFER_SIZE, dirwatch->subtree,
257 dirwatch->filter, &_bytes, dirwatch->io_info, 261 dirwatch->filter, &_bytes,
258 watch_completion)) 262 dirwatch->io_info, watch_completion))
259 { 263 {
260 DebPrint (("ReadDirectoryChangesW error: %lu\n", GetLastError ())); 264 DebPrint (("ReadDirectoryChangesW error: %lu\n", GetLastError ()));
261 /* If this call fails, it means that the directory is not 265 /* If this call fails, it means that the directory is not
@@ -270,7 +274,7 @@ watch_completion (DWORD status, DWORD bytes_ret, OVERLAPPED *io_info)
270 274
271 /* If we were asked to terminate the thread, then fire the event. */ 275 /* If we were asked to terminate the thread, then fire the event. */
272 if (terminate) 276 if (terminate)
273 SetEvent(dirwatch->terminate); 277 SetEvent (dirwatch->terminate);
274} 278}
275 279
276/* Worker routine for the watch thread. */ 280/* Worker routine for the watch thread. */
@@ -284,10 +288,10 @@ watch_worker (LPVOID arg)
284 288
285 if (dirwatch->dir) 289 if (dirwatch->dir)
286 { 290 {
287 bErr = ReadDirectoryChangesW (dirwatch->dir, dirwatch->buf, 291 bErr = (*pfnReadDirectoryChangesW) (dirwatch->dir, dirwatch->buf,
288 DIRWATCH_BUFFER_SIZE, dirwatch->subtree, 292 DIRWATCH_BUFFER_SIZE, dirwatch->subtree,
289 dirwatch->filter, &_bytes, 293 dirwatch->filter, &_bytes,
290 dirwatch->io_info, watch_completion); 294 dirwatch->io_info, watch_completion);
291 if (!bErr) 295 if (!bErr)
292 { 296 {
293 DebPrint (("ReadDirectoryChangesW: %lu\n", GetLastError ())); 297 DebPrint (("ReadDirectoryChangesW: %lu\n", GetLastError ()));
@@ -436,7 +440,7 @@ remove_watch (struct notification *dirwatch)
436 DebPrint (("QueueUserAPC failed (%lu)!\n", GetLastError ())); 440 DebPrint (("QueueUserAPC failed (%lu)!\n", GetLastError ()));
437 441
438 /* We also signal the thread that it can terminate. */ 442 /* We also signal the thread that it can terminate. */
439 SetEvent(dirwatch->terminate); 443 SetEvent (dirwatch->terminate);
440 444
441 /* Wait for the thread to exit. FIXME: is there a better method 445 /* Wait for the thread to exit. FIXME: is there a better method
442 that is not overly complex? */ 446 that is not overly complex? */
@@ -466,7 +470,7 @@ remove_watch (struct notification *dirwatch)
466 CloseHandle (dirwatch->thr); 470 CloseHandle (dirwatch->thr);
467 dirwatch->thr = NULL; 471 dirwatch->thr = NULL;
468 } 472 }
469 CloseHandle(dirwatch->terminate); 473 CloseHandle (dirwatch->terminate);
470 xfree (dirwatch->buf); 474 xfree (dirwatch->buf);
471 xfree (dirwatch->io_info); 475 xfree (dirwatch->io_info);
472 xfree (dirwatch->watchee); 476 xfree (dirwatch->watchee);
@@ -575,6 +579,8 @@ generate notifications correctly, though. */)
575 report_file_notify_error ("Watching filesystem events is not supported", 579 report_file_notify_error ("Watching filesystem events is not supported",
576 Qnil); 580 Qnil);
577 } 581 }
582 else
583 eassert (pfnReadDirectoryChangesW);
578 584
579 /* filenotify.el always passes us a directory, either the parent 585 /* filenotify.el always passes us a directory, either the parent
580 directory of a file to be watched, or the directory to be 586 directory of a file to be watched, or the directory to be
@@ -649,7 +655,7 @@ WATCH-DESCRIPTOR should be an object returned by `w32notify-add-watch'. */)
649 if (!NILP (watch_object)) 655 if (!NILP (watch_object))
650 { 656 {
651 watch_list = Fdelete (watch_object, watch_list); 657 watch_list = Fdelete (watch_object, watch_list);
652 dirwatch = (struct notification *)xmint_pointer (watch_descriptor); 658 dirwatch = (struct notification *) xmint_pointer (watch_descriptor);
653 if (w32_valid_pointer_p (dirwatch, sizeof(struct notification))) 659 if (w32_valid_pointer_p (dirwatch, sizeof(struct notification)))
654 status = remove_watch (dirwatch); 660 status = remove_watch (dirwatch);
655 } 661 }
@@ -687,7 +693,7 @@ watch by calling `w32notify-rm-watch' also makes it invalid. */)
687 if (!NILP (watch_object)) 693 if (!NILP (watch_object))
688 { 694 {
689 struct notification *dirwatch = 695 struct notification *dirwatch =
690 (struct notification *)xmint_pointer (watch_descriptor); 696 (struct notification *) xmint_pointer (watch_descriptor);
691 if (w32_valid_pointer_p (dirwatch, sizeof(struct notification)) 697 if (w32_valid_pointer_p (dirwatch, sizeof(struct notification))
692 && dirwatch->dir != NULL) 698 && dirwatch->dir != NULL)
693 return Qt; 699 return Qt;
@@ -699,6 +705,16 @@ watch by calling `w32notify-rm-watch' also makes it invalid. */)
699void 705void
700globals_of_w32notify (void) 706globals_of_w32notify (void)
701{ 707{
708 HANDLE kernel32 = GetModuleHandle ("kernel32");
709
710 /* Initialize pointers to IO functions that provide file
711 notifications. In the event that these are absent, no harm will be
712 done, since their absence indicates that Emacs is running on
713 Windows 9X, where file notifications are unavailable at the
714 outset. */
715 pfnReadDirectoryChangesW
716 = (void *) get_proc_addr (kernel32, "ReadDirectoryChangesW");
717
702 watch_list = Qnil; 718 watch_list = Qnil;
703} 719}
704 720
diff --git a/src/w32uniscribe.c b/src/w32uniscribe.c
index dacd6dd766e..471bdf544d8 100644
--- a/src/w32uniscribe.c
+++ b/src/w32uniscribe.c
@@ -109,6 +109,31 @@ memq_no_quit (Lisp_Object elt, Lisp_Object list)
109} 109}
110 110
111 111
112/* Uniscribe function pointers. */
113static HRESULT (WINAPI * pfnScriptItemize) (const WCHAR *,
114 int,
115 int,
116 const SCRIPT_CONTROL *,
117 const SCRIPT_STATE *,
118 SCRIPT_ITEM *, int *);
119static HRESULT (WINAPI * pfnScriptShape) (HDC, SCRIPT_CACHE *,
120 const WCHAR *,
121 int, int, SCRIPT_ANALYSIS *,
122 WORD *, WORD *, SCRIPT_VISATTR *,
123 int *);
124static HRESULT (WINAPI * pfnScriptPlace) (HDC, SCRIPT_CACHE *,
125 const WORD *, int,
126 const SCRIPT_VISATTR *,
127 SCRIPT_ANALYSIS *,
128 int *, GOFFSET *, ABC *);
129static HRESULT (WINAPI * pfnScriptGetGlyphABCWidth) (HDC, SCRIPT_CACHE *,
130 WORD, ABC *);
131static HRESULT (WINAPI * pfnScriptFreeCache) (SCRIPT_CACHE *);
132static HRESULT (WINAPI * pfnScriptGetCMap) (HDC, SCRIPT_CACHE *,
133 const WCHAR *,
134 int, DWORD, WORD *);
135
136
112/* Font backend interface implementation. */ 137/* Font backend interface implementation. */
113static Lisp_Object 138static Lisp_Object
114uniscribe_list (struct frame *f, Lisp_Object font_spec) 139uniscribe_list (struct frame *f, Lisp_Object font_spec)
@@ -202,7 +227,7 @@ uniscribe_close (struct font *font)
202 else 227 else
203#endif 228#endif
204 if (uniscribe_font->cache) 229 if (uniscribe_font->cache)
205 ScriptFreeCache ((SCRIPT_CACHE) &(uniscribe_font->cache)); 230 (*pfnScriptFreeCache) ((SCRIPT_CACHE) &(uniscribe_font->cache));
206 231
207 uniscribe_font->cache = NULL; 232 uniscribe_font->cache = NULL;
208 233
@@ -320,8 +345,8 @@ uniscribe_shape (Lisp_Object lgstring, Lisp_Object direction)
320 max_items = 2; 345 max_items = 2;
321 items = xmalloc (sizeof (SCRIPT_ITEM) * max_items + 1); 346 items = xmalloc (sizeof (SCRIPT_ITEM) * max_items + 1);
322 347
323 while ((result = ScriptItemize (chars, nchars, max_items, NULL, NULL, 348 while ((result = (*pfnScriptItemize) (chars, nchars, max_items, NULL, NULL,
324 items, &nitems)) == E_OUTOFMEMORY) 349 items, &nitems)) == E_OUTOFMEMORY)
325 { 350 {
326 /* If that wasn't enough, keep trying with one more run. */ 351 /* If that wasn't enough, keep trying with one more run. */
327 max_items++; 352 max_items++;
@@ -344,17 +369,18 @@ uniscribe_shape (Lisp_Object lgstring, Lisp_Object direction)
344 { 369 {
345 int nglyphs, nchars_in_run; 370 int nglyphs, nchars_in_run;
346 nchars_in_run = items[i+1].iCharPos - items[i].iCharPos; 371 nchars_in_run = items[i+1].iCharPos - items[i].iCharPos;
347 /* Force ScriptShape to generate glyphs in the same order as 372 /* Force (*pfnScriptShape) to generate glyphs in the same order as
348 they are in the input LGSTRING, which is in the logical 373 they are in the input LGSTRING, which is in the logical
349 order. */ 374 order. */
350 items[i].a.fLogicalOrder = 1; 375 items[i].a.fLogicalOrder = 1;
351 376
352 /* Context may be NULL here, in which case the cache should be 377 /* Context may be NULL here, in which case the cache should be
353 used without needing to select the font. */ 378 used without needing to select the font. */
354 result = ScriptShape (context, (SCRIPT_CACHE) &(uniscribe_font->cache), 379 result
355 chars + items[i].iCharPos, nchars_in_run, 380 = (*pfnScriptShape) (context, (SCRIPT_CACHE) &(uniscribe_font->cache),
356 max_glyphs - done_glyphs, &(items[i].a), 381 chars + items[i].iCharPos, nchars_in_run,
357 glyphs, clusters, attributes, &nglyphs); 382 max_glyphs - done_glyphs, &(items[i].a),
383 glyphs, clusters, attributes, &nglyphs);
358 384
359 if (result == E_PENDING && !context) 385 if (result == E_PENDING && !context)
360 { 386 {
@@ -365,10 +391,12 @@ uniscribe_shape (Lisp_Object lgstring, Lisp_Object direction)
365 context = get_frame_dc (f); 391 context = get_frame_dc (f);
366 old_font = SelectObject (context, FONT_HANDLE (font)); 392 old_font = SelectObject (context, FONT_HANDLE (font));
367 393
368 result = ScriptShape (context, (SCRIPT_CACHE) &(uniscribe_font->cache), 394 result
369 chars + items[i].iCharPos, nchars_in_run, 395 = (*pfnScriptShape) (context,
370 max_glyphs - done_glyphs, &(items[i].a), 396 (SCRIPT_CACHE) &(uniscribe_font->cache),
371 glyphs, clusters, attributes, &nglyphs); 397 chars + items[i].iCharPos, nchars_in_run,
398 max_glyphs - done_glyphs, &(items[i].a),
399 glyphs, clusters, attributes, &nglyphs);
372 } 400 }
373 401
374 if (result == E_OUTOFMEMORY) 402 if (result == E_OUTOFMEMORY)
@@ -390,9 +418,11 @@ uniscribe_shape (Lisp_Object lgstring, Lisp_Object direction)
390 } 418 }
391 else 419 else
392 { 420 {
393 result = ScriptPlace (context, (SCRIPT_CACHE) &(uniscribe_font->cache), 421 result
394 glyphs, nglyphs, attributes, &(items[i].a), 422 = (*pfnScriptPlace) (context,
395 advances, offsets, &overall_metrics); 423 (SCRIPT_CACHE) &(uniscribe_font->cache),
424 glyphs, nglyphs, attributes, &(items[i].a),
425 advances, offsets, &overall_metrics);
396 if (result == E_PENDING && !context) 426 if (result == E_PENDING && !context)
397 { 427 {
398 /* Cache not complete... */ 428 /* Cache not complete... */
@@ -400,10 +430,11 @@ uniscribe_shape (Lisp_Object lgstring, Lisp_Object direction)
400 context = get_frame_dc (f); 430 context = get_frame_dc (f);
401 old_font = SelectObject (context, FONT_HANDLE (font)); 431 old_font = SelectObject (context, FONT_HANDLE (font));
402 432
403 result = ScriptPlace (context, 433 result
404 (SCRIPT_CACHE) &(uniscribe_font->cache), 434 = (*pfnScriptPlace) (context,
405 glyphs, nglyphs, attributes, &(items[i].a), 435 (SCRIPT_CACHE) &(uniscribe_font->cache),
406 advances, offsets, &overall_metrics); 436 glyphs, nglyphs, attributes, &(items[i].a),
437 advances, offsets, &overall_metrics);
407 } 438 }
408 if (SUCCEEDED (result)) 439 if (SUCCEEDED (result))
409 { 440 {
@@ -469,7 +500,7 @@ uniscribe_shape (Lisp_Object lgstring, Lisp_Object direction)
469 then updated for each successive glyph in the 500 then updated for each successive glyph in the
470 grapheme cluster. */ 501 grapheme cluster. */
471 /* FIXME: Should we use DIRECTION here instead 502 /* FIXME: Should we use DIRECTION here instead
472 of what ScriptItemize guessed? */ 503 of what (*pfnScriptItemize) guessed? */
473 if (items[i].a.fRTL) 504 if (items[i].a.fRTL)
474 { 505 {
475 int j1 = j; 506 int j1 = j;
@@ -496,7 +527,7 @@ uniscribe_shape (Lisp_Object lgstring, Lisp_Object direction)
496 LGLYPH_SET_ASCENT (lglyph, font->ascent); 527 LGLYPH_SET_ASCENT (lglyph, font->ascent);
497 LGLYPH_SET_DESCENT (lglyph, font->descent); 528 LGLYPH_SET_DESCENT (lglyph, font->descent);
498 529
499 result = ScriptGetGlyphABCWidth 530 result = (*pfnScriptGetGlyphABCWidth)
500 (context, (SCRIPT_CACHE) &(uniscribe_font->cache), 531 (context, (SCRIPT_CACHE) &(uniscribe_font->cache),
501 glyphs[j], &char_metric); 532 glyphs[j], &char_metric);
502 if (result == E_PENDING && !context) 533 if (result == E_PENDING && !context)
@@ -505,7 +536,7 @@ uniscribe_shape (Lisp_Object lgstring, Lisp_Object direction)
505 f = XFRAME (selected_frame); 536 f = XFRAME (selected_frame);
506 context = get_frame_dc (f); 537 context = get_frame_dc (f);
507 old_font = SelectObject (context, FONT_HANDLE (font)); 538 old_font = SelectObject (context, FONT_HANDLE (font));
508 result = ScriptGetGlyphABCWidth 539 result = (*pfnScriptGetGlyphABCWidth)
509 (context, (SCRIPT_CACHE) &(uniscribe_font->cache), 540 (context, (SCRIPT_CACHE) &(uniscribe_font->cache),
510 glyphs[j], &char_metric); 541 glyphs[j], &char_metric);
511 } 542 }
@@ -624,7 +655,8 @@ uniscribe_encode_char (struct font *font, int c)
624 convert surrogate pairs to glyph indexes correctly. */ 655 convert surrogate pairs to glyph indexes correctly. */
625 { 656 {
626 items = (SCRIPT_ITEM *) alloca (sizeof (SCRIPT_ITEM) * 2 + 1); 657 items = (SCRIPT_ITEM *) alloca (sizeof (SCRIPT_ITEM) * 2 + 1);
627 if (SUCCEEDED (ScriptItemize (ch, len, 2, NULL, NULL, items, &nitems))) 658 if (SUCCEEDED ((*pfnScriptItemize) (ch, len, 2, NULL, NULL, items,
659 &nitems)))
628 { 660 {
629 HRESULT result; 661 HRESULT result;
630 /* Surrogates seem to need 2 here, even though only one glyph is 662 /* Surrogates seem to need 2 here, even though only one glyph is
@@ -635,14 +667,14 @@ uniscribe_encode_char (struct font *font, int c)
635 SCRIPT_VISATTR attrs[2]; 667 SCRIPT_VISATTR attrs[2];
636 int nglyphs; 668 int nglyphs;
637 669
638 /* Force ScriptShape to generate glyphs in the logical 670 /* Force (*pfnScriptShape) to generate glyphs in the logical
639 order. */ 671 order. */
640 items[0].a.fLogicalOrder = 1; 672 items[0].a.fLogicalOrder = 1;
641 673
642 result = ScriptShape (context, 674 result = (*pfnScriptShape) (context,
643 (SCRIPT_CACHE) &(uniscribe_font->cache), 675 (SCRIPT_CACHE) &(uniscribe_font->cache),
644 ch, len, 2, &(items[0].a), 676 ch, len, 2, &(items[0].a),
645 glyphs, clusters, attrs, &nglyphs); 677 glyphs, clusters, attrs, &nglyphs);
646 678
647 if (result == E_PENDING) 679 if (result == E_PENDING)
648 { 680 {
@@ -651,10 +683,11 @@ uniscribe_encode_char (struct font *font, int c)
651 f = XFRAME (selected_frame); 683 f = XFRAME (selected_frame);
652 context = get_frame_dc (f); 684 context = get_frame_dc (f);
653 old_font = SelectObject (context, FONT_HANDLE (font)); 685 old_font = SelectObject (context, FONT_HANDLE (font));
654 result = ScriptShape (context, 686 result
655 (SCRIPT_CACHE) &(uniscribe_font->cache), 687 = (*pfnScriptShape) (context,
656 ch, len, 2, &(items[0].a), 688 (SCRIPT_CACHE) &(uniscribe_font->cache),
657 glyphs, clusters, attrs, &nglyphs); 689 ch, len, 2, &(items[0].a),
690 glyphs, clusters, attrs, &nglyphs);
658 } 691 }
659 692
660 if (SUCCEEDED (result) && nglyphs == 1) 693 if (SUCCEEDED (result) && nglyphs == 1)
@@ -670,9 +703,10 @@ uniscribe_encode_char (struct font *font, int c)
670 when shaped. But we still need the return from here 703 when shaped. But we still need the return from here
671 to be valid for the shaping engine to be invoked 704 to be valid for the shaping engine to be invoked
672 later. */ 705 later. */
673 result = ScriptGetCMap (context, 706 result
674 (SCRIPT_CACHE) &(uniscribe_font->cache), 707 = (*pfnScriptGetCMap) (context,
675 ch, len, 0, glyphs); 708 (SCRIPT_CACHE) &(uniscribe_font->cache),
709 ch, len, 0, glyphs);
676 if (SUCCEEDED (result) && glyphs[0]) 710 if (SUCCEEDED (result) && glyphs[0])
677 code = glyphs[0]; 711 code = glyphs[0];
678 } 712 }
@@ -942,7 +976,7 @@ uniscribe_check_otf_1 (HDC context, Lisp_Object script, Lisp_Object lang,
942 976
943 no_support: 977 no_support:
944 if (cache) 978 if (cache)
945 ScriptFreeCache (&cache); 979 (*pfnScriptFreeCache) (&cache);
946 return ret; 980 return ret;
947} 981}
948 982
@@ -1505,11 +1539,43 @@ syms_of_w32uniscribe_for_pdumper (void)
1505 return; 1539 return;
1506 1540
1507 /* Don't register if Uniscribe is not available. */ 1541 /* Don't register if Uniscribe is not available. */
1508 HMODULE uniscribe = GetModuleHandle ("usp10"); 1542 HMODULE uniscribe;
1543
1544#ifdef WINDOWSNT
1545 uniscribe = LoadLibrary ("usp10.dll");
1509 if (!uniscribe) 1546 if (!uniscribe)
1510 return; 1547 return;
1511 1548
1549 pfnScriptItemize = (void *) get_proc_addr (uniscribe, "ScriptItemize");
1550 pfnScriptShape = (void *) get_proc_addr (uniscribe, "ScriptShape");
1551 pfnScriptPlace = (void *) get_proc_addr (uniscribe, "ScriptPlace");
1552 pfnScriptGetGlyphABCWidth
1553 = (void *) get_proc_addr (uniscribe, "ScriptGetGlyphABCWidth");
1554 pfnScriptFreeCache
1555 = (void *) get_proc_addr (uniscribe, "ScriptFreeCache");
1556 pfnScriptGetCMap
1557 = (void *) get_proc_addr (uniscribe, "ScriptGetCMap");
1558 if (!pfnScriptItemize || !pfnScriptShape || !pfnScriptPlace
1559 || !pfnScriptGetGlyphABCWidth || !pfnScriptFreeCache
1560 || !pfnScriptGetCMap)
1561 {
1562 FreeLibrary (uniscribe);
1563 return;
1564 }
1565#else /* Cygwin */
1566 uniscribe = GetModuleHandle ("usp10.dll");
1567 if (!uniscribe)
1568 return;
1569
1570 pfnScriptItemize = &ScriptItemize;
1571 pfnScriptShape = &ScriptShape;
1572 pfnScriptPlace = &ScriptPlace;
1573 pfnScriptGetGlyphABCWidth = &ScriptGetGlyphABCWidth;
1574 pfnScriptFreeCache = &ScriptFreeCache;
1575 pfnScriptGetCMap = &ScriptGetCMap;
1576
1512 uniscribe_available = 1; 1577 uniscribe_available = 1;
1578#endif /* Cygwin */
1513 1579
1514 register_font_driver (&uniscribe_font_driver, NULL); 1580 register_font_driver (&uniscribe_font_driver, NULL);
1515 1581
diff --git a/test/lisp/net/dbus-tests.el b/test/lisp/net/dbus-tests.el
index 413901b0205..b3337132fb6 100644
--- a/test/lisp/net/dbus-tests.el
+++ b/test/lisp/net/dbus-tests.el
@@ -792,6 +792,58 @@ is in progress."
792 ;; Cleanup. 792 ;; Cleanup.
793 (dbus-unregister-service :session dbus--test-service))) 793 (dbus-unregister-service :session dbus--test-service)))
794 794
795(ert-deftest dbus-test05-register-signal-with-nils ()
796 "Check signal registration for an own service.
797SERVICE, PATH, INTERFACE and SIGNAL are ‘nil’. This is interpreted as a
798wildcard for the respective argument."
799 (skip-unless dbus--test-enabled-session-bus)
800 (dbus-ignore-errors (dbus-unregister-service :session dbus--test-service))
801
802 (unwind-protect
803 (let ((member "Member")
804 (handler #'dbus--test-signal-handler)
805 registered)
806
807 ;; Register signal handler.
808 (should
809 (equal
810 (setq
811 registered
812 (dbus-register-signal
813 :session nil nil nil nil handler))
814 `((:signal :session nil nil)
815 (nil nil ,handler))))
816
817 (dbus-register-signal
818 :session nil dbus--test-path
819 dbus--test-interface member handler)
820 (dbus-register-signal
821 :session dbus--test-service nil
822 dbus--test-interface member handler)
823 (dbus-register-signal
824 :session dbus--test-service dbus--test-path
825 nil member handler)
826 (dbus-register-signal
827 :session dbus--test-service dbus--test-path
828 dbus--test-interface nil handler)
829
830 ;; Send one argument, basic type.
831 (setq dbus--test-signal-received nil)
832 (dbus-send-signal
833 :session dbus--test-service dbus--test-path
834 dbus--test-interface member "foo")
835 (with-timeout (1 (dbus--test-timeout-handler))
836 (while (null dbus--test-signal-received)
837 (read-event nil nil 0.1)))
838 (should (equal dbus--test-signal-received '("foo")))
839
840 ;; Unregister signal.
841 (should (dbus-unregister-object registered))
842 (should-not (dbus-unregister-object registered)))
843
844 ;; Cleanup.
845 (dbus-unregister-service :session dbus--test-service)))
846
795(ert-deftest dbus-test06-register-property () 847(ert-deftest dbus-test06-register-property ()
796 "Check property registration for an own service." 848 "Check property registration for an own service."
797 (skip-unless dbus--test-enabled-session-bus) 849 (skip-unless dbus--test-enabled-session-bus)