1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-01-30 19:53:09 +00:00
Commit Graph

44079 Commits

Author SHA1 Message Date
Miha Rihtaršič
d80552df71 Allow kmacros to end with C-g in minibuffer
* src/keyboard.c (cmd_error): If a command causes a minibuffer-quit
condition, record its key in a keyboard macro (bug#48603).
2021-09-08 09:40:28 +02:00
Eli Zaretskii
db74a93659 Fix display of tab-bar buttons
* src/xterm.c (x_draw_image_relief):
* src/w32term.c (w32_draw_image_relief): Fix calculation of relief
thickness for tab-bar buttons.

* lisp/tab-bar.el (tab-bar--load-buttons)
(tab-bar-history-mode): Fix the :margin specification for tab-bar
buttons.  (Bug#50424)
2021-09-07 13:24:01 +03:00
Basil L. Contovounesios
534e631b00 Avoid segfault in command-modes
* src/data.c (Fcommand_modes): Check that bytecode object is
interactive before accessing its interactive spec to avoid
segfaulting (bug#50376).
2021-09-04 21:28:31 +02:00
Eli Zaretskii
0daad76704 Improve documentation of line truncation and wrapping
* doc/emacs/display.texi (Line Truncation, Visual Line Mode):
* doc/lispref/display.texi (Truncation): Document that turning on
line truncation disables wrapping, and vice versa.

* src/buffer.c (syms_of_buffer) <truncate-lines>:
* src/xdisp.c (syms_of_xdisp) <truncate-partial-width-windows>:
Warn against turning on when 'visual-line-mode' is in effect.
* lisp/simple.el (visual-line-mode): Document that this mode
disables line truncation.  (Bug#29664)
2021-09-04 13:34:32 +03:00
Stefan Kangas
0cabf8bc36 ; Fix typos 2021-09-03 13:05:32 +02:00
Eli Zaretskii
3d26490749 Fix expansion of non-ASCII $HOME
* src/fileio.c (Fexpand_file_name): Make the file name multibyte
if the value of $HOME is multibyte.  (Bug#50266)
2021-09-02 18:49:01 +03:00
Eli Zaretskii
110db95e13 Fix 'clone-frame' on TTY frames
* src/frame.c (Fmake_terminal_frame): Make a separate copy of the
faces for the new frame before calling modify-frame-parameters, as
on TTY frames that needs the faces already set up.  (Bug#34715)
2021-09-02 14:58:41 +03:00
Eli Zaretskii
f85b8678c4 Fix segfault with invalid key-translation-map binding
* src/keyboard.c (access_keymap_keyremap): Don't assume an invalid
function is specified as a symbol.  Reported by Perry E. Metzger
<perry@piermont.com>.
2021-09-01 19:27:43 +03:00
Kien Nguyen
c0243d9e82 * Add a dll loader entry for gcc_jit_context_new_cast (bug#50315)
* src/comp.c: Add a dll loader entry for
'gcc_jit_context_new_cast' (bug#50315).
2021-09-01 15:26:04 +02:00
Miha Rihtaršič
45793b195c In batch mode, avoid killing Emacs with C-g in the minibuffer
* src/keyboard.c (Fcommand_error_default_function): Don't kill emacs
when handling the minibuffer-quit condition (bug#48603).
2021-09-01 10:10:44 +02:00
Lars Ingebrigtsen
b612821388 call-process doc string clarification
* src/callproc.c (Fcall_process): Explicitly say that "output"
means both stdout and stderr (bug#37906).
2021-08-31 04:13:58 +02:00
Lars Ingebrigtsen
50765f3f51 Make run-at-time try harder to run at integral multiples
* lisp/emacs-lisp/timer.el (timer): Add new slot integral-multiple.
(timerp): Adjust.
(timer-event-handler): Recompute the delay if requested
(bug#39099).
(run-at-time): Mark the timer as recomputable if given a t
parameter.

* src/keyboard.c (decode_timer): Adjust.
2021-08-31 03:04:22 +02:00
Andreas Schwab
6767e55659 Implement proper type conversion in native compiler
* src/comp.c (enum cast_kind_of_type): Remove.
(comp_t): Add cast_ptr_to_int, cast_int_to_ptr, remove
cast_type_sizes, cast_type_kind, cast_type_names, cast_union_fields,
cast_union_field_biggest_type.
(emit_coerce): Remove check for type size.
(struct cast_type): Remove bytes_size.
(define_type_punning): New function.
(define_cast_from_to): Implement proper type conversion.
(define_cast_functions): Adjust.  (bug#50230)
2021-08-30 19:00:46 +02:00
Eli Zaretskii
a2a0b70c8b ; * src/xfaces.c (gui_supports_face_attributes_p): Fix typo in comment. 2021-08-29 18:03:28 +03:00
Alan Third
b0fe06e656 Disable the NS app when no frames are left (bug#14619, bug#21357, bug#23586)
* src/nsfns.m (Fx_create_frame): Enable the app.
* src/nsterm.m (ns_delete_terminal): Disable the app.
2021-08-29 10:22:15 +01:00
Lars Ingebrigtsen
64b4c85637 Fix up deleting auto-save/killing buffer wrt. `auto-save-visited-mode'
* src/buffer.c (Fkill_buffer): Respect `auto-save-visited-mode'.
2021-08-25 11:58:27 +02:00
Lars Ingebrigtsen
de64510973 Further checks for kill-buffer-delete-auto-save-files
* src/buffer.c (Fkill_buffer): Check that the auto-save file
exists before asking whether to delete it.
2021-08-25 11:49:52 +02:00
Eli Zaretskii
8f43180f0d Improve documentation of 'inhibit-mouse-event-check'
* etc/NEWS:
* src/callint.c (syms_of_callint): Fix wording of the
documentation of 'inhibit-mouse-event-check'.
2021-08-23 22:14:03 +03:00
Juri Linkov
976594d905 * lisp/mouse.el (context-menu-open): New command bound to [S-f10].
* doc/emacs/frames.texi (Menu Mouse Clicks): Mention S-F10
to pop up the context menu.

* src/callint.c (Fcall_interactively):
Use inhibit_mouse_event_check for the case 'e'.
(inhibit-mouse-event-check): New variable.

https://lists.gnu.org/archive/html/emacs-devel/2021-08/msg00733.html
2021-08-23 20:42:16 +03:00
Eli Zaretskii
efddcc9fbe Improve recently-changed docs
* src/frame.c (Fnext_frame):
* doc/lispref/frames.texi (Finding All Frames): Improve wording
and style of the 'next-frame's documentation.
2021-08-23 19:11:49 +03:00
Lars Ingebrigtsen
4167d4b4b2 Clarify the documentation of `next-frame'
* doc/lispref/frames.texi (Finding All Frames): Clarify what it
means to "consider".
* src/frame.c (Fnext_frame): Rewrite doc string to say what the
parameters actually mean (bug#13339).
2021-08-23 16:32:33 +02:00
Lars Ingebrigtsen
591b8bd87a Add new variable 'kill-buffer/delete-auto-save-files'
* doc/emacs/files.texi (Auto Save Files): Document it.
* lisp/cus-start.el (standard): Add customize form.

* lisp/files.el (delete-auto-save-files): Move definition to C
(since it's used in the C layer).

* src/buffer.c (Fkill_buffer): Use the new variable (and remove
the old code that apparently didn't trigger for
kill-buffer/delete-auto-save-files.
(syms_of_buffer): Add new variable
kill-buffer-delete-auto-save-files and move definition of
delete-auto-save-files here (bug#21612).
2021-08-23 15:56:54 +02:00
Lars Ingebrigtsen
8c62871829 Clarify :stderr in the make-process doc string
* src/process.c (Fmake_process): Elaborate upon what :stderr does
(bug#50166).
2021-08-23 03:53:41 +02:00
Basil L. Contovounesios
ff2124d297 Fix recent parse-partial-sexp argument validation
* src/syntax.c (parse-partial-sexp): Also handle markers as
arguments (bug#49944).  Tweak error message to follow conventions in
"(elisp) Signaling Errors".
2021-08-22 23:52:23 +01:00
Andrea Corallo
6c007668b3 Set a unique ID for eln files on macOS (bug#45934)
* src/comp.c (Fcomp__compile_ctxt_to_file): Set gcc's -install_name
parameter to the real filename.
2021-08-22 22:15:29 +01:00
Masahiro Nakamura
48d4969453 Set label for NSToolbarItem (bug#50159)
* src/nsmenu.m (update_frame_tool_bar): Get label text and pass it to ...
([EmacsToolbar addDisplayItemWithImage:idx:tag:labelText:helpText:enabled:]):
... this that sets label for NSToolbarItem.
* src/nsterm.h
([EmacsToolbar addDisplayItemWithImage:idx:tag:labelText:helpText:enabled:]):
Add labelText argument.
2021-08-22 20:58:26 +01:00
Mattias Engdegård
7f5f99f2a0 Make Qhide declaration non-target-specific
* src/xfns.c (syms_of_xfns): Move DEFSYM from here...
* src/menu.c (syms_of_menu): ... to here.
This fixes the NS build after dd7d966eb4.
2021-08-22 10:59:17 +02:00
Juri Linkov
dd7d966eb4 Don't show menu titles with the text property 'hide' (bug#50067)
* lisp/mouse.el (context-menu-map): Add menu title "Context Menu"
propertized with the text property 'hide'.

* src/menu.c (x_popup_menu_1): Don't show the title with the non-nil
text property 'hide' on GTK and NS.
2021-08-22 11:46:08 +03:00
Eli Zaretskii
964151570b ; * src/syntax.c: Remove a stray comment. 2021-08-21 17:13:46 +03:00
Lars Ingebrigtsen
5da7103443 Tweak the comment-start-skip example in the manual
* doc/emacs/programs.texi (Options for Comments): Tweak the
example regexp for comment-start-skip (bug#15006).
2021-08-21 16:08:36 +02:00
Lars Ingebrigtsen
cabd22f5c6 Make parse-partial-sexp signal an error if TO is smaller than FROM
* src/syntax.c (Fparse_partial_sexp): Signal an error if TO is
smaller than FROM (bug#49944).
2021-08-21 15:24:15 +02:00
Alan Third
2837e25caf Fix display bug on macOS (bug#50112)
* src/nsterm.m ([EmacsLayer initWithColorSpace:]): Use the colorspace
setter.
([EmacsLayer setColorSpace:]): Sometimes we seem to get null
colorspaces, so set a default in this case.
([EmacsLayer getContext]): Check whether there's been a surface or
graphics context allocation failure and log it.
2021-08-21 13:12:56 +01:00
Mattias Engdegård
f4159568a1 Remove default "Select" title from NS popup menus (bug#50067)
* src/menu.c (x_popup_menu_1): Remove default "Select" title.
* src/nsmenu.m (ns_menu_show): Allow title to be absent.
2021-08-21 12:41:54 +02:00
Eli Zaretskii
1511f3cecc Fix inaccuracies in documentation of 'message-truncate-lines'
* doc/lispref/display.texi (Echo Area Customization):
* src/xdisp.c (syms_of_xdisp): Adjust the documentation of
message-truncate-lines to changes that fixed bug#46718.
2021-08-19 15:44:55 +03:00
Eli Zaretskii
8e93a37b77 ; * src/xdisp.c (hscroll_window_tree): Fix a typo in a comment. 2021-08-19 15:25:26 +03:00
Eli Zaretskii
4bd7be2b8f Fix errors with hscrolling mini-windows under truncate-lines
* src/xdisp.c (hscroll_window_tree): Disallow hscroll in
mini-windows that display echo-area messages.  (Bug#50096)
2021-08-19 15:24:14 +03:00
Eli Zaretskii
78b427648b Improve documentation of 'assoc'
* doc/lispref/lists.texi (Association Lists):
* src/fns.c (Fassoc): Document how TESTFN is called.  (Bug#50110)
2021-08-18 22:07:30 +03:00
Eli Zaretskii
0d5ff75e94 Improve documentation of last change.
* etc/NEWS: Mention the string value of 'auto-composition-mode'.

* src/composite.c (syms_of_composite) <auto-composition-mode>: Doc
fix.
2021-08-18 19:10:01 +03:00
Lars Ingebrigtsen
15a8026caf Disable auto compositions on the Linux console only
* lisp/term/linux.el (terminal-init-linux): Disable auto
compositions on "linux" consoles (bug#21363).

* src/composite.c (inhibit_auto_composition): New function to
implement this.
(composition_compute_stop_pos, composition_adjust_point)
(Ffind_composition_internal): Use it.
(syms_of_composite): Document it.

* src/lisp.h: Export tty_type_name.

* src/term.c (tty_type_name): Factored out.
(Ftty_type): Use it.
2021-08-18 16:24:40 +02:00
Eli Zaretskii
ee812f2a98 Yet another place inside redisplay_window to prevent quitting
* src/xdisp.c (handle_single_display_spec): Inhibit quitting
around the call to lookup_image.  (Bug#44448)
2021-08-18 16:14:29 +03:00
Eli Zaretskii
bf4f7388b6 Fix abort when turning on Hebrew or Arabic input methods
* src/xdisp.c (face_before_or_after_it_pos): Add the missing
initialization of the bidi scan direction.  (Bug#50107)
2021-08-18 16:01:57 +03:00
Eli Zaretskii
130d47bdcc Another fix for quitting while displaying non-selected windows
* src/xdisp.c (handle_face_prop, extend_face_to_end_of_line):
Inhibit quitting around the call to face_at_pos, to prevent
leaking wrong value of point when the user quits while we
redisplay a non-selected window.  (Bug#44448)
2021-08-17 21:29:58 +03:00
Eli Zaretskii
5f47d17d33 Fix TTY display performance degradation due to many markers
* src/coding.c (encode_coding_object): Don't assume that
src_object == dst_object means src_object is the current buffer.
Add the missing commentary that explains the arguments.
(Bug#49127)
2021-08-17 15:31:53 +03:00
Eli Zaretskii
6898ae6f8c Plug another hole for longjmp-ing from 'redisplay_window'
* src/fringe.c (update_window_fringes): Inhibit quitting, so as
not to longjmp out of redisplay_window.  (Bug#44448)
2021-08-16 22:06:26 +03:00
Lars Ingebrigtsen
5d7b1d5fc7 Make overlays-in treat zero-length overlays at point-max consistently
* doc/lispref/display.texi (Finding Overlays): Adjust documentation.

* src/buffer.c (overlays_in): Treat the end of the buffer and the
end of the narrowed-to buffer the same (bug#19422).
(Foverlays_in): Adjust doc string.
2021-08-16 15:40:43 +02:00
Lars Ingebrigtsen
55772baee1 Make Emacs compile with musl instead of glibc
* src/alloc.c: musl doesn't have malloc_info (bug#50058).
2021-08-15 13:25:23 +02:00
Eli Zaretskii
36964b2358 ; * src/xdisp.c (display_mode_lines): Fix comment. 2021-08-15 14:18:17 +03:00
Eli Zaretskii
fdf148cab4 Fix unwarranted point movement after C-g
When the same buffer is displayed in more than one window,
redisplay temporarily moves point to the window-point when it
works on non-selected windows.  If we allow C-g to quit out of
redisplay_window in this situation, point will appear to have
moved to the window-point of that non-selected window, which is
unwarranted.  These changes prevent quitting in strategic places,
so that we never quit out of redisplay_window.
* src/xdisp.c (run_window_scroll_functions):
Prevent quitting while running window-scroll-functions, so that we
don't quit out of redisplay_window with temporarily moved point.
(redisplay_window): While redisplaying the mode line, prevent
quitting, to avoid exiting while point is temporarily moved.
(decode_mode_spec): Use safe_call1 instead of call1, to trap any
errors instead of letting them throw out of redisplay.  (Bug#44448)
2021-08-15 14:11:23 +03:00
Eli Zaretskii
9c5dc3cbe0 * src/w32.c (_sys_read_ahead): Pacify a silly compiler warning. 2021-08-14 20:38:05 +03:00
Eli Zaretskii
482049e542 Fix 'random' on MS-Windows when integers are wider than 30 bits
* src/w32.c (random): Provide more random bits for MS-Windows
builds with EMACS_INT that is wider than 32 bits.  (Bug#32605)
2021-08-14 17:39:38 +03:00