1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-26 07:11:34 -08:00
Commit graph

161477 commits

Author SHA1 Message Date
Stefan Kangas
bf0e4d1b03 Prefer defvar-keymap in make-mode.el
* lisp/progmodes/make-mode.el (makefile-mode-map)
(makefile-browser-map): Prefer defvar-keymap.
2022-10-28 22:23:08 +02:00
Stefan Kangas
6f42782a57 Prefer make-temp-name in make-mode.el
* lisp/progmodes/make-mode.el
(makefile-generate-temporary-filename): Make obsolete in favor of
'make-temp-name'.  Simplify.
(makefile-save-temporary): Don't use above obsolete function.
2022-10-28 22:23:08 +02:00
Stefan Kangas
dee3d93e73 Ensure temp file is deleted in makefile overview
* lisp/progmodes/make-mode.el (makefile-create-up-to-date-overview):
Ensure temp file is always deleted.
2022-10-28 22:23:08 +02:00
Stefan Kangas
943f95e03c Merge from origin/emacs-28
510020d30d ; Improve doc strings in whitespace.el

# Conflicts:
#	lisp/whitespace.el
2022-10-28 21:51:44 +02:00
Eli Zaretskii
27b817ad32 ; * doc/lispref/frames.texi (Drag and Drop): Fix typos and wording. 2022-10-28 22:06:31 +03:00
Alan Mackenzie
622724e95d CC Mode: Fontify cast types without adding them to c-found-types
* lisp/progmodes/cc-engine.el (c-forward-type): Test for the special new
value `just-one' of c-promote-possible-types, and if found, fontify the type,
but don't add it to c-found-types.
(c-forward-decl-or-cast-1): Add the new &optional parameter inside-macro.
Whilst checking for a cast construct, analyze the text following the closing
paren more rigorously.
Check for, and allow, the closing paren of a macro arglist before the putative
cast construct.

* lisp/progmodes/cc-fonts.el (c-font-lock-declarations): In the lambda
function, pass the parameter inside-macro to c-forward-decl-or-cast-1.

* lisp/progmodes/cc-langs.el (c-primary-expr-regexp-details): New
c-lang-defvar which calculates `c-primary-expr-regexp' and three match
numbers for various sub-expressions in the regexp.
(c-primary-expr-regexp): Now extracted from `c-primary-expr-regexp-details'.
(c-per-++---match, c-per-&*+--match, c-per-\(-match): New
c-lang-defconsts/vars extracted from `c-primary-expr-regexp-details'.
2022-10-28 17:50:33 +00:00
Stefan Monnier
d79cdcd4ff cconv.el: Fix regression in cconv-tests-interactive-closure-bug51695
The new code to make interpreted closures safe-for-space introduced
a regression in `cconv-tests-interactive-closure-bug51695`, only seen
when using TEST_LOAD_EL.
A few other issues were found and fixed along the way.

* lisp/emacs-lisp/cconv.el (cconv-fv): Change calling convention and
focus on finding the free variables.
(cconv-make-interpreted-closure): New function.

* lisp/loadup.el: Use `compiled-function-p` rather than
`byte-code-function-p` so we also use safe-for-space interpreted
closures when we build with native compilation.
(internal-make-interpreted-closure-function):
Use `cconv-make-interpreted-closure`.

* src/eval.c (syms_of_eval): Rename `internal-filter-closure-env-function`
to `internal-make-interpreted-closure-function`.
(Ffunction): Let that new var build the actual closure.

* test/lisp/emacs-lisp/cconv-tests.el
(cconv-tests-interactive-closure-bug51695): Test specifically the
interpreted case.
2022-10-28 11:33:24 -04:00
Jonas Bernoulli
de5a3fa1e5 * lisp/transient.el: Update to package version v0.3.7-173-g81b29ca 2022-10-28 16:27:25 +02:00
Po Lu
e8b59a9bb9 Improve Drag and Drop preamble in the Lisp reference manual
* doc/lispref/frames.texi (Drag and Drop): Reword contents and
clear up some ambiguities and redundancies.
2022-10-28 22:23:35 +08:00
Stefan Monnier
c0f7a276cf * lisp/emacs-lisp/re-builder.el: Cosmetic changes
(reb-valid-string): Declare it risky so the mode-line will obey its
text-properties.
(reb-lisp-syntax-p): No need to make it `defsubst`.
(reb-target-value): New function to replace the
`reb-target-binding` macro.  Adjust all callers.
(reb-auto-update): Give a more informative error message than just
"invalid" and give it a warning face.
(reb-update-regexp): Always update `reb-regexp-src` (it's harmless),
rather than only when it's necessary (reduces the need for advice in pcre.el).
2022-10-28 09:36:40 -04:00
Jonas Bernoulli
1073e16960 Include more information in error data for sqlite errors
Introduce a new 'sqlite-error' and use it for all errors signaled in
'src/sqlite.c', except those that already used 'sqlite-locked-error'.
Include the values of 'sqlite3_errcode', 'sqlite3_extended_errcode',
'sqlite3_errstr' and 'sqlite3_errmsg' in the error data.

* src/sqlite.c (load_dll_functions): Load 'sqlite3_extended_errcode'.
(sqlite-load-extension): Use 'xsignal1' as required by argument type.
(syms_of_sqlite): Introduce a new error type 'sqlite-error'.
(check_sqlite, sqlite-open, bind_values, sqlite-execute)
(sqlite-select, sqlite-load-extension, sqlite-next): Use it.
(sqlite_prepare_errdata): New function.
(sqlite_prepare_errmsg): Remove function.
(sqlite-execute, sqlite-select): Use new function.
(sqlite-locked-error): Derive from 'sqlite-error'.
2022-10-28 14:33:49 +02:00
Alan Mackenzie
f9ed80f9d0 CC Mode: Fix wrong fontification of enum foo bar; in Objective C Mode
This fixes bug #58795 and bug #58796.

* lisp/progmodes/cc-langs.el (c-type-prefix-kwds): Add the missing entry for
objc.
2022-10-28 12:15:18 +00:00
Po Lu
879c65a5fc Simplify scroll valuator reset handling
* src/xterm.c (xi_populate_device_from_info)
(xi_reset_scroll_valuators_for_device_id, xi_handle_device_changed)
(handle_one_xevent):
* src/xterm.h (struct xi_scroll_valuator_t): Get rid of
`pending_enter_reset', which was extremely convoluted and kept
hitting server bugs.  Now, valuators are reset upon all crossing
events.
2022-10-28 20:06:06 +08:00
Po Lu
90caddc986 Clean up some xwidgets code
* src/xterm.c (handle_one_xevent): [HAVE_XWIDGETS]: Fix coding
style and remove extra ifdefs.  Also avoid redundant frame
lookups in some cases.
2022-10-28 19:55:18 +08:00
Po Lu
93aff6e533 Fix Haiku subprocess support
* src/callproc.c: Disable posix_spawn on Haiku until some things
are fixed.
2022-10-28 11:41:08 +00:00
Po Lu
36ca409d72 Fix build without Cairo FreeType and fontconfig support
* src/xsettings.c (apply_xft_settings): Don't enable Xft code
unless Cairo FreeType support is present.  (bug#58830)
2022-10-28 19:35:39 +08:00
Wamm K. D
e893fd1073 Fix failing test for package Hierarchy
This fixes a typo in one of the tests of Hierarchy which was causing
the test to fail.
* test/lisp/emacs-lisp/hierarchy-tests.el (hierarchy-delayed-add-trees):
Fix typo.
2022-10-28 10:33:18 +03:00
Vincent Bernat
52d4c98cec Fix detection of DPI changes in builds without Xft
* src/xsettings.c (apply_xft_settings) [!HAVE_XFT]: Support
XSETTINGS changes in non-XFT builds.  (Bug#43128)

Copyright-paperwork-exempt: yes
2022-10-28 10:27:47 +03:00
Eli Zaretskii
e953490603 ; * lisp/progmodes/gud.el (gud-gdb): Doc fix. (Bug#58826) 2022-10-28 09:23:12 +03:00
Protesilaos Stavrou
1e7710d00f
Update to modus-themes version 3.0.0
* doc/misc/modus-themes.org
(Option for red-green color deficiency or deuteranopia)
(Option for more bold constructs, Option for more italic constructs)
(Option for font mixing, Option for box buttons)
(Option for mode line presentation)
(Option for accented background in tab interfaces)
(Option for completion framework aesthetics, Option for mail citations)
(Option for line numbers, Option for mouseover effects)
(Option for diff buffer looks, Option for org-mode block styles)
(Option for Org agenda constructs)
(Option for the headings' overall style)
(Option for variable-pitch font in UI elements, Note on SHR fonts):
Revise markup of "non-nil" so that it is rendered properly in texinfo.

(Option for fringe visibility, Option for line highlighting): Reword
description of user option.

(Full support for packages or face groups): Update list of supported
packages or face groups.

(Note on ERC escaped color sequences)
(What is the best setup for legibility?)
(Port the Modus themes to other platforms?): Prefer American English.

(Note on pdf-tools link hints): Use double spacing between sentences

(Acknowledgements): Update list of names that have contributed to the
project, which was user feedback in this case.

* etc/themes/modus-themes.el (modus-themes, modus-themes-faces):
Reword doc string.
(modus-themes--version): Update to current version.
(modus-themes-version): Refine function definition.
(modus-themes-completion-standard-first-match)
(modus-themes-completion-standard-selected)
(modus-themes-completion-extra-selected)
(modus-themes-completion-key-binding, modus-themes-intense-markup)
(modus-themes--heading-weights, modus-themes--completion): Delete
obsolete forms, which were deprecated many months/version ago.
(modus-themes-fringes, modus-themes-completions)
(modus-themes-hl-line): Update default value and reword doc string
accordingly.
(modus-themes-faces): Update list of supported faces and their
attributes.

* etc/themes/modus-operandi-theme.el:
* etc/themes/modus-vivendi-theme.el: Update version header.

Complete release notes: <https://protesilaos.com/codelog/2022-10-28-modus-themes-3-0-0/>.
2022-10-28 07:51:55 +03:00
Stefan Kangas
41d3d71a1e ; Fix typos in symbol names 2022-10-27 23:04:37 +02:00
Wamm K. D
c6ec08e49a Allow Hierarchy to delay computation of children
This adds an option to allow callers to specify that computing
the children of the hierarchy should be delayed to when the
user calls for them, by utilizing the tree-widget :expander
property.
* lisp/emacs-lisp/hierarchy.el (hierarchy-add-tree)
(hierarchy-add-trees): Add parameter 'delay-children-p'.
* lisp/emacs-lisp/hierarchy.el
(hierarchy--create-delayed-tree-widget): Add function.
* lisp/emacs-lisp/hierarchy.el (hierarchy-convert-to-tree-widget):
Utilize ':expander' if delaying children.  (Bug#55900)

* test/lisp/emacs-lisp/hierarchy-tests.el: Add tests for
delayed-children functionality.
2022-10-27 20:12:24 +03:00
Eli Zaretskii
d53febbd21 ; * lisp/subr.el (keyboard-translate): Doc fix. (Bug#58805) 2022-10-27 19:57:33 +03:00
kobarity
7ac3d91eb2 Disable completion/ElDoc/FFAP when Python program is running
* lisp/progmodes/python.el (python-completion-at-point)
(python-ffap-module-path, python-eldoc--get-doc-at-point): Add check
using `python-util-comint-end-of-output-p'.
(python-util-comint-end-of-output-p): New function.
* test/lisp/progmodes/python-tests.el (python-tests-shell-wait-for-prompt):
Use `python-util-comint-end-of-output-p'.
(python-completion-at-point-while-running-1)
(python-ffap-module-path-1)
(python-ffap-module-path-while-running-1)
(python-eldoc--get-doc-at-point-1)
(python-eldoc--get-doc-at-point-while-running-1): New tests.
(Bug#58713)
2022-10-27 19:04:14 +03:00
Eli Zaretskii
d820c39bd1 ; (rmail-summary-apply-filters-consecutively): Add :version. 2022-10-27 18:45:28 +03:00
Andrea Monaco
8728da58ab Allow applying Rmail summary filters consecutively
* lisp/mail/rmailsum.el (rmail-summary-currently-displayed-msgs):
New variable.
(rmail-summary-apply-filters-consecutively): New user option.
(rmail-summary-fill-displayed-messages, rmail-summary-negate): New
functions.
(rmail-summary-by-labels, rmail-summary-by-recipients)
(rmail-summary-by-regexp, rmail-summary-by-topic)
(rmail-summary-by-senders): Obey
'rmail-summary-apply-filters-consecutively'.
KEEP-FILTERING, to narrow the existing filtered summary.

* etc/NEWS: Announce the change.
2022-10-27 17:25:16 +03:00
Eli Zaretskii
582eaadde7 Revert "Allow applying filters to summary consecutively"
This reverts commit c8b9ba5fa1.
2022-10-27 17:15:51 +03:00
Andrea Monaco
c8b9ba5fa1 Allow applying filters to summary consecutively
* lisp/mail/rmailsum.el (rmail-summary-currently-displayed-msgs):
New variable.
(rmail-summary-fill-displayed-messages, rmail-summary-negate): New
functions.
(rmail-summary-by-labels, rmail-summary-by-recipients)
(rmail-summary-by-regexp, rmail-summary-by-topic)
(rmail-summary-by-senders): Accept an additional argument
KEEP-FILTERING, to narrow the existing filtered summary.

* etc/NEWS: Announce the change.
2022-10-27 16:56:12 +03:00
Eli Zaretskii
877f706c86 ; * src/keyboard.c (command_loop_1): Remove unused variable. 2022-10-27 15:29:46 +03:00
Eli Zaretskii
93fb14d0c8 Avoid recentering when point enters invisible text at BOL
* src/xdisp.c (try_cursor_movement): Don't say we must scroll when
point is inside invisible text at beginning of a glyph row.
(Bug#58793)
2022-10-27 15:24:53 +03:00
Po Lu
af46d8a7ec Fix reporting of iconic state on old window managers
* src/xterm.c (x_handle_wm_state): Handle IconicState if the
window manager does not support _NET_WM_STATE_HIDDEN.
2022-10-27 19:15:50 +08:00
Stefan Kangas
8deb797897 ; Fix quoting of non-nil in texinfo sources 2022-10-27 13:11:47 +02:00
Stephen Leake
e16ee5fde6 Fix auto-insert-alist ada-mode entry to match current ELPA ada-mode 2022-10-27 03:29:20 -07:00
Eli Zaretskii
510020d30d ; Improve doc strings in whitespace.el
* lisp/whitespace.el (whitespace-hspace-regexp)
(whitespace-space-regexp, whitespace-tab-regexp)
(whitespace-trailing-regexp, whitespace-space-before-tab-regexp)
(whitespace-indentation-regexp, whitespace-empty-at-bob-regexp)
(whitespace-empty-at-eob-regexp)
(whitespace-space-after-tab-regexp)
(whitespace-big-indent-regexp, whitespace-line-column)
(whitespace-display-mappings, whitespace-global-modes)
(whitespace-action, whitespace-style, whitespace-space)
(whitespace-hspace, whitespace-tab, whitespace-trailing)
(whitespace-space-before-tab, whitespace-indentation)
(whitespace-big-indent, whitespace-empty)
(whitespace-space-after-tab): Doc fixes.
2022-10-27 10:28:34 +03:00
Eli Zaretskii
37bde3d36c ; Simplify wording in Eglot manual
* doc/misc/eglot.texi (Customizing Eglot): Simplify wording.
Reported by Pedro Andres Aranda Gutierrez <paaguti@gmail.com>.
2022-10-27 09:21:04 +03:00
Stefan Kangas
db2ed9f333 ; Fix several symbol name typos 2022-10-26 23:04:23 +02:00
Stefan Kangas
c716d0cf56 ; Use auto-generated docstring in gnus-custom-mode
* lisp/gnus/gnus-cus.el (gnus-custom-mode): Change docstring to prefer
text auto-generated by 'define-derived-mode' instead.
2022-10-26 23:04:23 +02:00
Stefan Kangas
4b9e2f8080 ; * lisp/textmodes/table.el: Delete reference to ancient version. 2022-10-26 23:04:18 +02:00
Stefan Kangas
d73b86a90a Fix typo in textsec-restriction-level
* lisp/international/textsec.el (textsec-restriction-level):
* test/lisp/international/textsec-tests.el (test-restriction-level):
Fix typo in symbol name `moderately-restrictive'.
2022-10-26 23:02:30 +02:00
Stefan Kangas
68548af68a Declare variable Info-minibuf-history
* lisp/info.el (Info-minibuf-history): Declare variable.
(Bug#58786)
2022-10-26 21:09:14 +02:00
Filipp Gunbin
56706c6946 Compare addresses case-insensitively in message-update-smtp-method-header
* lisp/gnus/message.el (message-update-smtp-method-header): Compare
addresses case-insensitively.
2022-10-26 21:13:16 +03:00
Alan Mackenzie
b7e59b9e19 c-find-decl-spots: Replace an arbitrary search limit by a parameter
The old arbitrary limit led to errors thrown whilst fontifying large areas of
syntactic whitespace containing "#undef", as in src/comp.c.

* lisp/progmodes/cc-engine.el (c-find-decl-spots): Replace the limit argument
to two calls of c-forward-syntactic-ws by the parameter `cfd-limit'.
2022-10-26 16:02:49 +00:00
Mauro Aranda
5d46c0e329 Make completion-category-overrides choices dynamic
See https://lists.gnu.org/archive/html/emacs-devel/2022-10/msg01969.html

* lisp/minibuffer.el (completion--update-styles-options): New internal
function.

(completion--styles-type): Use it.
2022-10-26 11:28:54 -03:00
Eli Zaretskii
d6e08ff459 Fix rare problems with current-column when text is invisible
* src/indent.c (scan_for_column, compute_motion): Don't miss
compositions when the position to check for composition happens to
be inside invisible text.  (Bug#58791)
2022-10-26 17:21:45 +03:00
Po Lu
4a1e77ced6 Prevent gui_consider_frame_title from restoring dead top frames
* src/xdisp.c (unwind_format_mode_line): Check that
old_top_frame is live before selecting it.  It could have been
deleted, which leads to signals when the post-command-hook
installed by xterm-set-window-title runs upon the last frame of
a terminal being deleted.
(gui_consider_frame_title): Rearrange code to be more
understandable.
2022-10-26 21:46:58 +08:00
Basil L. Contovounesios
38bcad5451 Pacify recent unused/ignored lexvar warnings
Lexvars with special names like 'ignored' or 'unused' are no longer
treated specially.

* lisp/ansi-color.el (ansi-color-process-output):
* lisp/cus-edit.el (customize-apropos-options):
* lisp/cus-theme.el (customize-create-theme):
* lisp/dired-aux.el (dired-hide-all):
* lisp/emacs-lisp/crm.el (crm--choose-completion-string):
* lisp/emacs-lisp/tabulated-list.el (tabulated-list-revert):
* lisp/ido.el (ido-choose-completion-string):
* lisp/international/mule-diag.el (describe-font-internal):
* lisp/mail/sendmail.el (sendmail-user-agent-compose):
* lisp/progmodes/fortran.el (fortran-uncomment-region):
* lisp/progmodes/prolog.el (prolog-inferior-guess-flavor):
* lisp/progmodes/ruby-mode.el (ruby-indent-line, ruby-indent-exp):
* lisp/url/url.el (url-mm-callback):
* lisp/xwidget.el (xwidget-webkit-history-reload): Prepend an
underscore to unused function parameter names.
* lisp/emacs-lisp/cconv.el (cconv--dummy-var): Remove unused
constant.
* lisp/files.el (hack-local-variables-filter): Remove unused lexvar.
2022-10-26 16:35:59 +03:00
Po Lu
32dd769ca4 Clean up some event handling code
* src/xterm.c (handle_one_xevent): Use dpyinfo where
FRAME_DISPLAY_INFO could be substituted for it.
2022-10-26 20:38:05 +08:00
Michael Albinus
0fbafe6511 ; Tramp copyedit 2022-10-26 13:59:37 +02:00
Michael Albinus
2468b819e2 Modernize `auto-revert-notify-exclude-dir-regexp'
* lisp/autorevert.el (auto-revert-notify-exclude-dir-regexp): Use `rx'
and `mounted-file-systems'.
2022-10-26 13:58:42 +02:00
Mattias Engdegård
e54c395982 Dynamic validation of styles in completion-category-overrides
The type of the defcustom completion-category-overrides must be able
to accommodate dynamic changes to completion-styles-alist, because
some packages (eglot) make their own additions.

This change fixes a failure in test-custom-opts.  See discussion at:
https://lists.gnu.org/archive/html/emacs-devel/2022-10/msg01969.html

* lisp/minibuffer.el (completion--styles-type):
Add an "Other" case that accepts any symbol which is then validated
dynamically against completion-styles-alist.
2022-10-26 10:51:51 +02:00