In the newline command, last-input-event is 13 (carriage return), but
most, if not all, language servers that support
documentOnTypeFormattingProvider expect 10 (linefeed) to be the
trigger, so convert 13 to 10 for the purposes of the
textDocument/onTypeFormatting request.
Also make this common edit silent in the mode-line/messages.
* lisp/progmodes/eglot.el (eglot--post-self-insert-hook): Convert
linefeed to carriage return.
(eglot-format): Pass SILENT to eglot--apply-text-edits.
(eglot--apply-text-edits): Take new optional SILENT arg.
* etc/EGLOT-NEWS: Mention change
* java/org/gnu/emacs/EmacsContextMenu.java (EmacsContextMenu):
New field `title'.
(addSubmenu): New arg TITLE. Set that field.
(expandTo): Set MENU's header title if it's a context menu.
* src/androidmenu.c (android_init_emacs_context_menu): Adjust
signature of `createContextMenu'.
(android_menu_show): Use TITLE instead of pane titles if there's
only one pane.
* lisp/erc/erc-nicks.el (erc-nicks-mode, erc-nicks-enable): This local
module isn't autoloaded like most global modules, in part to dissuade
users from attempting to enable it by running M-x erc-nicks-mode RET.
However, rather than signal an error upon detecting such an attempt,
ERC should explain that the only supported means of activation is via
`erc-modules'. This change does that and then enables it anyway,
despite the degraded experience.
* doc/misc/erc.texi: Change name of example function from
`erc-my-enable-read-indicator-on-join' to
`erc-my-enable-keep-place-indicator-on-join'. Fix example functions
`erc-cmd-TRACK' and `erc-cmd-UNTRACK' to work with server buffers as
well as target buffers.
* etc/ERC-NEWS: Revise `keep-place' entry and make headlines less
redundant.
* lisp/erc/erc.el (erc-accidental-paste-threshold-seconds): Fix
portion of existing wording that was more likely interpreted as a
single multiline submission, whereas the intended meaning is three
separate submissions.
* lisp/touch-screen.el (touch-screen-handle-point-up): If what
is `restart-drag' (meaning that a drag has been restarted but
the touchpoint has not moved), translate the release into a
regular mouse click to deactivate the region.
* build-aux/makecounter.sh (curcount): Rename `counter' to
`emacs_shortlisp_counter'.
* doc/emacs/input.texi (Touchscreens): Document
`touch-screen-extend-selection'.
* doc/lispref/commands.texi (Touchscreen Events): Document
`touchscreen-restart-drag'.
* lisp/touch-screen.el (touch-screen-extend-selection): New user
option.
(touch-screen-restart-drag): New function.
(touch-screen-handle-point-update): Handle `restart-drag'
gestures.
(touch-screen-handle-touch): Check if the prerequisites for
extending a previous drag gesture are met, and generate such
events if so.
(touch-screen-translate-touch): Update doc string.
* src/Makefile.in (otherobj): Remove BUILD_COUNTER_OBJ.
($(lispsource)/international/charprop.el):
(%.elc): Don't depend on bootstrap-emacs if cross configuring
for Android.
(libemacs.so): Directly depend on and link with
BUILD_COUNTER_OBJ.
* build-aux/makecounter.sh: New script.
* src/Makefile.in (abs_top_builddir): New variable.
(BUILD_COUNTER_OBJ): Define to build-counter.o
if compiling for Android.
(build-counter.c): New target. Generate this file using
makecounter.sh upon changes to lisp.mk or shortlisp.
(lisp.mk): Make and load relative to abs_top_builddir.
(emacs$(EXEEXT)): Adjust acordingly.
(mostlyclean): Remove build-counter.c.
* lisp/mouse.el (minor-mode-menu-from-indicator): Instead of using the
word at point, search for a matching enabled minor mode from the
beginning of the string object when mode-line-compact is enabled.
This cures the inability to paste text containing NUL from other
applications on macOS, introduced by mistake in 7e3c2b553f
(bug#64697).
* src/nsfns.m ([NSString lispString]): Use make_string instead of
build_string which relies on NUL-termination.
* lisp/mouse.el (minor-mode-menu-from-indicator): New arg
WINDOW. If INDICATOR is a string object and mode-line-compat is
enabled within WINDOW, use the symbol within the object at its
position instead.
(mouse-minor-mode-menu): Pass posn-object and posn-window to
minor-mode-menu-from-indicator.
* lisp/touch-screen.el (touch-screen-hold)
(touch-screen-handle-point-up): Don't select inactive minibuffer
windows.
(touch-screen-handle-point-update): Improve detection of left
and right edges.
* doc/lispref/commands.texi (Touchscreen Events): Describe
treatment of canceled touch sequences during touch event
translation.
* java/org/gnu/emacs/EmacsNative.java (EmacsNative): Update JNI
prototypes.
* java/org/gnu/emacs/EmacsWindow.java (motionEvent): Set
cancelation flag in events sent where appropriate.
* lisp/touch-screen.el (touch-screen-handle-point-update):
Improve treatment of horizontal scrolling near window edges.
(touch-screen-handle-touch): Don't handle point up if the touch
sequence has been canceled.
* src/android.c (sendTouchDown, sendTouchUp, sendTouchMove): New
argument `flags'.
* src/androidgui.h (enum android_touch_event_flags): New enum.
(struct android_touch_event): New field `flags'.
* src/androidterm.c (handle_one_android_event): Report
cancelation in TOUCHSCREEN_END_EVENTs.
* src/keyboard.c (make_lispy_event): Fix botched merge.
* doc/lispref/commands.texi (Touchscreen Events):
* etc/NEWS: Describe new event parameter `canceled'.
* src/keyboard.c (make_lispy_event) <TOUCHSCREEN_END_EVENT>:
If event->modifiers, set canceled to t.
* src/termhooks.h (enum event_kind): Describe meaning of
modifiers in TOUCHSCREEN_END_EVENTs.
* src/xfns.c (setup_xi_event_mask): Select for
XI_TouchOwnership.
* src/xterm.c (xi_link_touch_point): Round X and Y and clear
ownership.
(xi_unlink_touch_point): Return 1 if the touch point is not
owned by Emacs, 2 otherwise.
(handle_one_xevent): Handle XI_TouchOwnership events and report
ownership correctly.
* src/xterm.h (enum xi_touch_ownership): New enum. Write
commentary on XI touch sequence ownership.
(struct xi_touch_point_t): Use integer X and Y. New field
`ownership'. Adjust for alignment.