1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-01-02 11:21:42 +00:00
Commit Graph

156567 Commits

Author SHA1 Message Date
Lars Ingebrigtsen
3faba1dff6 Improve previous apropos-documentation-check-elc-file change
* lisp/apropos.el (apropos-documentation-check-elc-file): Add
comment to explain what's going on and expand to lisp-directory
(bug#55492).
2022-05-18 13:20:26 +02:00
Alan Mackenzie
7969e41654 Fix M-x compile-defun when an interactive form is (list ...)
This is for when lexical-binding is nil.  The problem fixed was M-x
compile-defun leaving symbols with position in the compiled function's arglist
and interactive form.  This fixes bug #55323.  Also ensure the doc string is
correctly stripped when lexical-binding is t.

* lisp/emacs-lisp/bytecomp.el (byte-compile-lambda): For a (list ...)
interactive form when lexical-binding is nil, strip the positions from the
symbols in the form.  Also strip the position from the symbols in the arglist.
(byte-compile-make-closure): (Twice) strip symbols from positions in the doc
string expression.  Add comments.
2022-05-18 09:18:15 +00:00
Martin Rudalics
e1c972b247 Clean up and simplify 'quit-restore-window' code
* lisp/window.el (window--quit-restore-select-window): New internal
name for 'quit-restore-select-window'.
(quit-restore-window): Use 'window--quit-restore-select-window'
instead of 'quit-restore-select-window'.  Simplify code.
2022-05-18 11:09:58 +02:00
Mattias Engdegård
97400c4c24 Make printing mostly non-recursive (bug#55481)
Introduce explicit stacks for traversing common data types during
printing: conses, vectors, records, byte-code, hash-tables and
char-tables, all previously traversed using recursion in C.  This
greatly reduces the risk of crashing Emacs from C stack overflow
when printing deeply nested data.

* src/print.c (Fprinc, print, PRINT_CIRCLE_CANDIDATE_P):
Special-case Fprinc with a plain string argument to eliminate the need
for keeping track of print_depth during the preprocessing phase.
This also improves performance.
(struct print_pp_entry, struct print_pp_stack, ppstack)
(grow_pp_stack, pp_stack_push_value, pp_stack_push_values)
(pp_stack_empty_p, pp_stack_pop):
New stack for preprocessing.
(print_preprocess):
Make mostly nonrecursive, except for string properties.
(enum print_entry_type, struct print_stack_entry)
(struct print_stack, prstack, grow_print_stack)
(print_stack_push, print_stack_push_vector):
New stack for printing.
(print_vectorlike, print_object):
Make mostly nonrecursive, except for string properties and some less
heavily used types.
* test/src/print-tests.el (print-deeply-nested):
New test.
2022-05-18 10:40:15 +02:00
Michael Albinus
24f7719cb6 ; Fix thinko in etc/NEWS 2022-05-18 10:05:32 +02:00
Po Lu
997ce9eb3d Avoid dismissing GTK+ popup menus upon wheel movement
* src/xterm.c (handle_one_xevent): Don't forward XI button
events for wheel buttons to GTK+ when a popup menu is active.
2022-05-18 14:56:04 +08:00
Po Lu
c258528cfb Fix race conditions when calculating Haiku frame geometry
* src/haiku_support.cc (be_lock_window, be_unlock_window): New
functions.
* src/haiku_support.h: Update prototypes.

* src/haikufns.c (frame_geometry): Lock window before asking for
its dimensions and frame.
2022-05-18 04:07:31 +00:00
Po Lu
55198d1796 Don't allow moving fullscreen frames on Haiku
* src/haikuterm.c (haiku_set_window_size): Fix typo in comment.
(haiku_set_offset): Prevent offset from changing in fullboth
frames.
2022-05-18 01:23:32 +00:00
Po Lu
8b98f87b92 Fix a crash when an X connection is dropped in some situations
* src/xterm.c (x_flip_and_flush): Don't try to flush if
`inhibit-redisplay' is t.
2022-05-18 09:07:41 +08:00
Lars Ingebrigtsen
961cec0a7d Fix apropos-documentation with universal argument
* lisp/apropos.el (apropos-documentation-check-elc-file): Look up
.elc files in the load path (and don't bug out on deleted .elc
files) (bug#55492).
2022-05-18 01:22:26 +02:00
Stefan Kangas
f99980bf6c Recommend Wikipedia over Usenet in FAQ
* doc/misc/efaq.texi (Origin of the term Emacs): Recommend
Wikipedia over Usenet to find out more about TECO.
2022-05-18 01:10:22 +02:00
Stefan Kangas
3e3ba233cf Remove some ancient Emacs compat code
* lisp/cedet/mode-local.el (mode-local-describe-bindings-1):
* lisp/cedet/semantic/senator.el (senator-copy-tag-to-register):
* lisp/gnus/nnrss.el (nnrss-opml-export):
* lisp/net/newst-backend.el (newsticker-opml-export):
* lisp/textmodes/reftex.el (reftex-mode-menu):
* lisp/woman.el (woman-menu): Remove some ancient Emacs compat code.
2022-05-18 00:27:52 +02:00
Matthias Meulien
01f48477d0 Update comment about comint-osc-handlers
* lisp/comint.el: Update comment about comint-osc-handlers.
2022-05-17 23:36:27 +02:00
Lars Ingebrigtsen
092aea9a27 Allow running several commands in compilation-start
* lisp/progmodes/compile.el (compilation-start): Allow not erasing
the contents of the buffer (bug#28892).
2022-05-17 22:08:17 +02:00
Protesilaos Stavrou
89ca98c59c
Use better word for "buffer" in Greek TUTORIAL (bug#55332)
* TUTORIAL.el_GR: Replace all instances of "αποσβεστήρας" with the
more accurate "ενταμιευτής".
2022-05-17 22:16:31 +03:00
Lars Ingebrigtsen
f719250f77 Fix bogus future history entries for `M-x grep'
* lisp/net/mailcap.el (mailcap-file-default-commands): If we have
no matching MIME types, don't iterate over (nil) (bug#27236).

This fixes things like:

(mailcap-file-default-commands '("grep --color=auto -nH --null '' "))
=> ("/usr/bin/emacs -nw")
2022-05-17 21:00:25 +02:00
Lars Ingebrigtsen
514cfbb267 Explain more about jit-lock-mode calling conventions
* lisp/jit-lock.el (jit-lock-mode): Explicitly explain ARG
(bug#55451).
2022-05-17 20:01:11 +02:00
Lars Ingebrigtsen
6e61f9ec8a Fix pp-emacs-lisp-code printing of cons cells
* lisp/emacs-lisp/pp.el (pp--insert-lisp): Fix printing of cons
cells (bug#55478).
2022-05-17 19:45:20 +02:00
Robert Pluim
45ec56f5bd Correct cycle-spacing-actions type
* lisp/simple.el (cycle-spacing-actions): Fix type for predefined
action with fixed numeric arg case.
2022-05-17 17:39:14 +02:00
Robert Pluim
731ccac828 Clarify 'cycle-spacing-actions' docstring
* lisp/simple.el (cycle-spacing-actions): Clarify docstring.
2022-05-17 17:39:14 +02:00
Robert Pluim
9d38470142 ; * lisp/simple.el (cycle-spacing-actions): Fix typo 2022-05-17 17:39:14 +02:00
Michael Albinus
18b14916a7 ; Fix typos in etc/NEWS 2022-05-17 17:27:15 +02:00
Eli Zaretskii
1cf590065d ; * etc/NEWS: Rewrite entries for added support of old scripts. 2022-05-17 16:21:34 +03:00
Po Lu
5c656182ce Avoid race conditions when computing real frame positions on Haiku
* src/haiku_support.cc (DispatchMessage): Accept
SEND_MOVE_FRAME_EVENT.
(class EmacsWindow, FrameMoved): Include decorator frame in
MOVE_EVENT events.
(be_send_move_frame_event): New function.
* src/haiku_support.h (struct haiku_move_event): Include
decorator dimensions.  Update prototypes.

* src/haikufns.c (haiku_update_after_decoration_change): Ask for
a move frame event and don't do anything if configury is not yet
complete.

* src/haikuterm.c (haiku_read_socket): Adjust accordingly.
2022-05-17 13:13:41 +00:00
समीर सिंह Sameer Singh
2414fa3603 Add support for the Modi script
* lisp/language/indian.el ("Modi"): New language environment.
Add composition rules for Modi.  Add sample text and input
method.
Add sample text to various scripts.
Rename Punjabi to Gurmukhi.
* lisp/international/fontset.el (script-representative-chars)
(setup-default-fontset): Support Modi.
* lisp/leim/quail/indian.el ("modi"): New input method.
(Bug#55439)

* etc/HELLO: Add a Modi greeting.
Rename Hindi to Devanagari.
Add a Gurmukhi greeting.
Replace Odia greeting.
* etc/NEWS: Announce the new language environment and its
input method.
2022-05-17 16:08:45 +03:00
Alan Mackenzie
3ef68c2d7a CC Mode: Correct a rare error in the state cache
* lisp/progmodes/cc-engine.el (c-append-lower-brace-pair-to-state-cache): Do
not record a position in a macro as the starting position in
c-state-brace-pair-desert.  Instead record the position at the beginning of
that macro.
2022-05-17 11:26:05 +00:00
Alan Mackenzie
71249b774a Correct indentation of opening brace in xdisp.c, which isn't at start of defun
* xdisp.c (calc_pixel_width_or_height): indent the opening brace of a
substatement correctly.  It's previous position, in column 0, caused
indentation errors in C Mode.
2022-05-17 10:31:15 +00:00
Po Lu
38dfe9d2f7 Fix unused function warning on X
* src/xsettings.c (xg_settings_key_valid_p): Surround with
HAVE_PGTK and HAVE_GSETTINGS.
2022-05-17 18:18:32 +08:00
Pieter van Prooijen
1a6a4614ce Fix font options compilation with gsettings disabled
* src/xsettings.c (xsettings_get_font_options): Return a font_options
even if gsettings is not enabled.
2022-05-17 18:15:18 +08:00
Po Lu
e9ad64ef92 Rewrite Haiku frame geometry code to handle decorator frames
* doc/lispref/frames.texi (Frame Layout): Document changes to
Haiku frame layout.

* src/haiku_support.cc (class EmacsWindow, MoveToIncludingFrame)
(EmacsMoveTo, MakeFullscreen): Move to an offset including the
decorator frames.
(be_get_window_decorator_dimensions):
(be_get_window_decorator_frame): New functions.

* src/haiku_support.h: Update prototypes.

* src/haikufns.c (haiku_update_after_decoration_change): New
function.
(haiku_create_frame, haiku_set_undecorated)
(haiku_set_override_redirect): Call that function.
(frame_geometry): Actually calculate frame geometry based on
decorator and frame sizes.

* src/haikuterm.c (haiku_coords_from_parent): Use frame width
instead.
(haiku_read_socket): Set left and top positions based on
decorator width and height.
* src/haikuterm.h (struct haiku_output): New field `frame_x' and
`frame_y'.
2022-05-17 09:59:20 +00:00
Lars Ingebrigtsen
dc239872cc Fix package-quickstart breakage
* lisp/emacs-lisp/package.el (package-quickstart-refresh): Work
around syntax-ppss now clobbering match data (but it's not clear
whether that's supposed to be allowed) (bug#55447).
2022-05-17 11:48:12 +02:00
Lars Ingebrigtsen
608afd6e4e Improve Finternal__define_uninitialized_variable erroring
* src/eval.c (Finternal__define_uninitialized_variable): Say what
symbol we're bugging out on for easier debugging.
2022-05-17 11:06:33 +02:00
Lars Ingebrigtsen
90dccb0f00 Fix edebug-tests test failure after prin1 change
* lisp/emacs-lisp/ert-x.el (ert--make-print-advice): Fix test
failures in edebug-tests.
2022-05-17 10:09:58 +02:00
Po Lu
803041e014 Remove extra EmacsPopUpMenu class
* src/haiku_support.cc (class EmacsPopUpMenu): Delete class that
does nothing.
(BPopUpMenu_new): Use BPopUpMenu directly.
(BMenu_add_title): Clean up coding style.
2022-05-17 03:11:23 +00:00
Po Lu
316fbc8ccb Add more cursor bitmaps on Haiku
* src/haikufns.c (cursor_bitmaps_for_id): Add vertd, horizd and
hand bitmaps.
2022-05-17 02:51:42 +00:00
Po Lu
e52159d0dc Let XTread_socket read events for all non-DND displays
* src/xterm.c (XTread_socket): Allow reading events from
displays other than the DND display during drag-and-drop.
2022-05-17 09:21:19 +08:00
Po Lu
164ff4a012 Fix byte swapping of some drag-and-drop messages
* src/xterm.c (SWAPCARD16, SWAPCARD32): Actually swap the data
instead of just calling bswap_32/bswap_16.
2022-05-17 09:10:46 +08:00
Po Lu
3939a72fcb Fix detection of wheel movement during drag-and-drop
* src/xterm.c (x_dnd_send_position): Don't treat Button8 as the
mouse wheel.
2022-05-16 21:47:39 +08:00
kobarity
c44908c059 Fix Python highlighting of some assignment statements
* lisp/progmodes/python.el (python-rx): Limit not-simple-operator
to a single line (bug#51362).
2022-05-16 15:40:17 +02:00
Lars Ingebrigtsen
ed71839c33 Add new user option compilation-hidden-output
* doc/emacs/building.texi (Compilation Mode): Document it.
* lisp/progmodes/compile.el (compilation-hidden-output): New user
option.
(compilation-filter): Use it.
(compilation--hide-output): New function.
2022-05-16 15:30:50 +02:00
Lars Ingebrigtsen
f5ee56c5ea Don't expose Vprint_variable_mapping to Lisp
* src/print.c: Don't expose Vprint_variable_mapping to the Lisp
world, because it really should be immutable.
(print_create_variable_mapping): Initialization moved here from
syms_of_print.
(print_bind_overrides): Call it.
(syms_of_print): Protect the mapping variable.
2022-05-16 15:01:08 +02:00
Tassilo Horn
5a6e727ddb ; Fix Wrong type argument: number-or-marker-p, (4) in cycle-spacing 2022-05-16 14:27:04 +02:00
Lars Ingebrigtsen
006fd29ca1 Revert "Make TAB work in makefile mode when transient mark mode is on"
This reverts commit a4c96147d1.

This change made hitting RET after an assignment insert a TAB character
(bug#55446).
2022-05-16 14:24:41 +02:00
Lars Ingebrigtsen
bf22068aee Improve newsticker file name handling and printing
* lisp/net/newst-backend.el (newsticker--images-dir)
(newsticker--icons-dir, newsticker--cache-dir): Don't use concat
to construct file names.
(newsticker-download-images, newsticker-download-enclosures): Ditto.
(newsticker--cache-save-feed): Bind print-level etc when printing.

* lisp/net/newst-treeview.el (newsticker-treeview-save): Ditto.

This patch was mostly written by mailj2@protonmail.com, but was then
rewritten by me, and has some contributions from Xavier Capaldi (which
doesn't need copyright assignment).
2022-05-16 14:05:18 +02:00
Eli Zaretskii
0e88398632 ; Fix documentation of 'cycle-spacing'
* etc/NEWS:
* doc/emacs/killing.texi (Deletion): Fix wording and punctuation
of the documentation of 'cycle-spacing'.
2022-05-16 14:50:27 +03:00
Eli Zaretskii
de26ad23d5 ; * doc/emacs/frames.texi (Tooltips): Fix punctuation and wording. 2022-05-16 14:37:36 +03:00
Po Lu
1f76f50a04 Document recent tooltip changes on NS
* doc/emacs/frames.texi (Tooltips):
* etc/NEWS: Announce that non-system tooltips are now available
on Nextstep.
2022-05-16 17:29:50 +08:00
Tassilo Horn
e7a8136e34 ; cycle-spacing-actions: Add forgotten arg modifier - as customize choice 2022-05-16 10:08:40 +02:00
Andrea Corallo
2ba42e596a ; Fix two mail addresses
;* lisp/emacs-lisp/comp.el: Fix author's mail address.
;* lisp/emacs-lisp/comp-cstr.el: Likewise.
2022-05-16 09:54:15 +02:00
Po Lu
b8cfe8fa75 Improve error checking in `haiku-roster-launch'
* src/haikuselect.c (Fhaiku_roster_launch): Signal error if
FILE-OR-TYPE doesn't exist or ARGS does not apply.
2022-05-16 07:17:16 +00:00