Manuel Giraud [Tue, 1 Aug 2023 16:56:33 +0000 (18:56 +0200)]
Fix thumbnail update when thumb name is based on image content
* lisp/image/image-dired-util.el
(image-dired-update-thumbnail-at-point): New function to update
thumbnail when original image contents changed.
* lisp/image/image-dired-external.el
(image-dired-rotate-original): Use it.
* lisp/image/image-dired.el (image-dired-display-thumbs): Fix
spacing while here. (Bug#61394)
Don't allow the `eq` and `unbind` byte-ops to commute (bug#65017)
* lisp/emacs-lisp/byte-opt.el (byte-after-unwind-ops):
Cease sinking `eq` past `unwind`, because that optimised away the
let-binding in
(let ((symbols-with-pos-enabled nil))
(eq x y))
and `eq` is currently sensitive to `symbols-with-pos-enabled`.
* test/lisp/emacs-lisp/bytecomp-tests.el
(bytecomp--eq-symbols-with-pos-enabled): New test.
Stefan Kangas [Fri, 4 Aug 2023 07:50:43 +0000 (09:50 +0200)]
; Fix http/https thinko in org manual
* doc/misc/org.org (External Links): Change an HTTPS link back to
HTTP, as it's used as an example to show the supported protocols.
Ref: https://lists.gnu.org/r/emacs-devel/2023-08/msg00018.html
Eli Zaretskii [Fri, 4 Aug 2023 07:17:51 +0000 (03:17 -0400)]
Merge from origin/emacs-29
0f183770c56 Fix byte-compiled files that use 'bind-key' from use-package acfcf7f3690 Fix "Paste from Kill Menu" in non X toolkit builds 04996b21241 Handle tabs in the SQL shown in the column listing 573fcf27122 Add new keyword to 'typescript-ts-mode' db7d70d3cad ; Add commentary to 'describe-function's completion
Eli Zaretskii [Fri, 4 Aug 2023 07:17:50 +0000 (03:17 -0400)]
Merge from origin/emacs-29
6eddbfe33f2 Clarify the meaning of the argument of ':align-to' space ... 5c6a51668b0 ; * doc/misc/eshell.texi (Argument Modifiers): Fix typo i... da5e05a50e8 Fix handling of ".elpaignore" file when compiling packages
Eli Zaretskii [Fri, 4 Aug 2023 06:34:55 +0000 (09:34 +0300)]
Fix "Paste from Kill Menu" in non X toolkit builds
* src/keymap.c (possibly_translate_key_sequence): Don't signal an
error if 'key-valid-p' returns nil. Suggested by Stefan Monnier
<monnier@iro.umontreal.ca>. (Bug#64927)
Po Lu [Fri, 4 Aug 2023 06:29:55 +0000 (14:29 +0800)]
Optimize creation of multibyte menu items on Android
* src/androidvfs.c (android_verify_jni_string): Move to
android.c.
* src/android.c (android_verify_jni_string): New function.
(android_build_string): Forgo encoding menu text if TEXT is a
multibyte string that's also a valid JNI string.
* src/android.h: Update prototypes.
Michael Albinus [Thu, 3 Aug 2023 11:17:02 +0000 (13:17 +0200)]
Improve SELinux handling in Tramp
* lisp/net/tramp-sh.el (tramp-stat-file-attributes-with-selinux)
(tramp-stat-directory-files-and-attributes-with-selinux): New defconst.
(tramp-do-file-attributes-with-ls)
(tramp-do-file-attributes-with-stat)
(tramp-do-directory-files-and-attributes-with-stat): Return also
SELinux context.
(tramp-remote-selinux-p, tramp-do-copy-or-rename-file): Adapt docstring.
* lisp/net/tramp-sudoedit.el (tramp-sudoedit-do-copy-or-rename-file)
(tramp-sudoedit-remote-selinux-p): Adapt docstring.
(tramp-sudoedit-file-attributes-with-selinux): New defconst.
(tramp-sudoedit-handle-file-attributes): Use it.
Helmut Eller [Thu, 20 Jul 2023 14:27:34 +0000 (16:27 +0200)]
Improve interactive prompting for face colors
When displaying the completion candidates, show how the face would
look with the new foreground/background.
* lisp/faces.el (faces--string-with-color): New helper,
factored out from 'defined-colors-with-face-attributes'.
(defined-colors-with-face-attributes): Use it.
(read-color): Add optional argument FACE and pass
it to 'faces--string-with-color.'
(read-face-attribute): Call 'read-color' with more appropriate
foreground and face arguments.
* doc/lispref/minibuf.texi (High-Level Completion): Describe
the intention behind the arguments FOREGROUND and FACE of
'read-color'. (Bug#64725)
Po Lu [Thu, 3 Aug 2023 02:41:40 +0000 (10:41 +0800)]
Update Android port
* java/org/gnu/emacs/EmacsSafThread.java (CacheToplevel):
(EmacsSafThread):
(DocIdEntry):
(getCache):
(pruneCache):
(cacheDirectoryFromCursor):
(run):
(documentIdFromName1):
(statDocument1):
(openDocumentDirectory1):
(openDocument1): Introduce a file status cache and populate
it with files within directories as they are opened.
* java/org/gnu/emacs/EmacsService.java (createDocument):
(createDirectory):
(moveDocument): Invalidate the file status cache wherever
needed.
* src/fileio.c (check_vfs_filename):
(Fset_file_modes): Permit `set-file-modes' to silently fail
on asset and content files.
Harald Jörg [Wed, 2 Aug 2023 21:53:42 +0000 (23:53 +0200)]
cperl-mode.el: Subroutine names are fontified correctly in all places
Subroutine names are fontified as subroutine names even if the name is also
the name of a builtin (fixing an ancient unreported bug). Subroutine name
are just comments in comment and pod (fixing a bug introduced recently)
* lisp/progmodes/cperl-mode.el (cperl-init-faces): Move
fontification of sub declarations before that of builtins. Don't
override existing faces when fontifying subroutine declarations.
Don't fontify method calls even if the sub names match those of
builtins.
* test/lisp/progmodes/cperl-mode-tests.el (cperl-test-fontify-sub-names):
New tests with a subroutine name in several surroundings.
* test/lisp/progmodes/cperl-mode-resources/sub-names.pl: New resource
for the new test.
Stefan Kangas [Wed, 2 Aug 2023 19:46:55 +0000 (21:46 +0200)]
Don't hardcode ruby version in interpreter-mode-alist
* lisp/progmodes/ruby-mode.el (interpreter-mode-alist): Don't hardcode
ruby version. This adds support for modern versions of Ruby like
"ruby2.7", instead of the previously hardcoded "ruby1.9".
rx: better not-wordchar and (syntax word) translation
* lisp/emacs-lisp/rx.el:
Add tables of legacy syntax.
(rx--translate-symbol):
Translate the legacy construct `not-wordchar` as (not wordchar), which
is more intuitively obvious.
* lisp/emacs-lisp/rx.el (rx--translate-syntax):
Generate the shorter \w and \W instead of \sw and \Sw.
* test/lisp/emacs-lisp/rx-tests.el (rx-atoms, rx-syntax, rx-not):
Adapt tests.
* lisp/emacs-lisp/rx.el (rx--generate-alt):
Treat the intervals and classes lists separately without joining,
to reduce allocation. Handle special cases first.
(rx--union-intervals):
Implement directly instead of using intersection and complement.
* test/lisp/emacs-lisp/rx-tests.el (rx-any): Adapt test, as some
character alternatives are now slightly different.
(rx--complement-intervals, rx--union-intervals)
(rx--intersect-intervals): New unit tests.
Michael Albinus [Tue, 1 Aug 2023 18:24:44 +0000 (20:24 +0200)]
Add more `tramp-suppress-trace' properties in Tramp
* lisp/net/tramp-archive.el (tramp-archive-file-name-handler-alist):
Use `tramp-archive-handle-file-symlink-p'.
(tramp-archive-handle-file-symlink-p): New defun.
Po Lu [Tue, 1 Aug 2023 13:06:06 +0000 (21:06 +0800)]
Update Android port
* doc/emacs/android.texi (Android File System): Describe how to
access real files named /assets or /contents if so required.
* java/org/gnu/emacs/EmacsService.java (validAuthority):
* src/android.c (android_init_emacs_service):
* src/android.h: New function.
* src/androidvfs.c (android_saf_valid_authority_p): New
function. Wrap the Java function.
(android_saf_root_stat, android_saf_root_access): Don't return
success if no authority by vp->authority's name exists.
(android_saf_tree_from_name): Check validity of string data
before giving it to JNI.
Stefan Kangas [Tue, 1 Aug 2023 10:18:12 +0000 (12:18 +0200)]
Fix font locking of booleans in conf-toml-mode
* lisp/textmodes/conf-mode.el (conf-toml-mode): Do not use case
folding when font locking.
* test/lisp/textmodes/conf-mode-tests.el (conf-test-toml-mode):
Expand test.
* test/lisp/textmodes/conf-mode-tests.el (conf-test-javaprop-mode):
Attempt to give the test some meaning by repairing regexps,
and fixing it so that it passes.
Stefan Kangas [Tue, 1 Aug 2023 07:55:01 +0000 (09:55 +0200)]
Remove IE9 support tag from HTML5 skeleton
This is no longer recommended in 2023, and in any case seems like
overkill in an otherwise bare-bones HTML5 template.
Ref: https://stackoverflow.com/a/6771584
Po Lu [Tue, 1 Aug 2023 06:54:30 +0000 (14:54 +0800)]
Micro-optimize PUSHW/PUSHB
* src/sfnt.c (CHECK_STACK_AVAILABLE): New macro.
(PUSH):
(PUSH_UNCHECKED): Always define to unchecked versions,
even if TEST.
(PUSH2_UNCHECKED): New macro.
(NPUSHB):
(NPUSHW):
(PUSHB):
(PUSHW): Check the number of remaining stack elements
once.
(stack_overflow_test_args): Expect zero stack arguments.
Eli Zaretskii [Mon, 31 Jul 2023 18:50:45 +0000 (21:50 +0300)]
Fix 'string-pixel-width' under 'line-prefix'
* lisp/emacs-lisp/subr-x.el (string-pixel-width): Disable
'line-prefix' and 'wrap-prefix' to avoid their effect on the
calculated string width. (Bug#64971)
Michael Albinus [Mon, 31 Jul 2023 17:40:11 +0000 (19:40 +0200)]
Optimizations on Tramp symlink handling
* lisp/net/tramp-sh.el (cl-seq): Require.
(tramp-perl-file-truename): Print also whether the file is a symlink.
(tramp-bundle-read-file-names): Rename from
`tramp-vc-registered-read-file-names'. Print also the
`file-directory-p: value.
(tramp-sh-handle-make-symbolic-link): Combine two commands. Use
`tramp-skeleton-make-symbolic-link'.
(tramp-sh-handle-file-truename): Read also "file-symlink-marker"
property.
(tramp-sh-handle-file-directory-p): Simplify if-let clause.
(tramp-sh-handle-file-name-all-completions): Simplify command.
(tramp-bundle-read-file-names): New defun.
(tramp-sh-handle-vc-registered, tramp-get-remote-path): Use it.
(tramp-open-shell): Flush "scripts" connection property.
(tramp-open-connection-setup-interactive-shell): Combine two commands.
* lisp/net/tramp-smb.el (tramp-smb-handle-make-symbolic-link):
* lisp/net/tramp-sudoedit.el (tramp-sudoedit-handle-make-symbolic-link):
Use `tramp-skeleton-make-symbolic-link'.
* lisp/language/vietnamese.el (vietnamese-vscii): Update docstring.
(vietnamese-tcvn, tcvn, tcvn-5712): Make them aliases of
vietnamese-vscii.
("Vietnamese"): Drop vietnamese-tcvn from coding-system values.
Update docstring.
Eli Zaretskii [Mon, 31 Jul 2023 15:11:23 +0000 (11:11 -0400)]
; Merge from origin/emacs-29
The following commits were skipped:
0002d4f3166 Avoid spurious whitespace in the modeline of emacsclient ... 96d52f89444 Fix function help for advised aliases (bug#64797) 71419a60c37 Avoid crashes due to invalid 'mode-line-format' b2cb6e82160 ; Better documentation of HOME on MS-Windows 54e98b5f9bd ; Clarify documentation of 'server-after-make-frame-hook' d13029cdcde Avoid crashes under 'which-key-mode' cb1f7db2490 ; Minor documentation fixes 4a687bcc20d Bump Emacs version
Eli Zaretskii [Mon, 31 Jul 2023 15:11:23 +0000 (11:11 -0400)]
Merge from origin/emacs-29
a9b28224af0 ; Last-minute changes befor releasing 29.1 7da1cee56b3 Update CMake support due to upstream changes (bug#64922) c2d95dd00e6 Remove nullptr named node from c++-ts-mode (bug#64818) 4e977136d31 Make compat check also check typescript 906ecf442c4 ; * etc/HISTORY: Fix the 28.3 entry.