1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-12 14:30:42 -08:00
Commit graph

153376 commits

Author SHA1 Message Date
Po Lu
a7dbbcac57 Fix display of internal border in child frames on pgtk
* src/pgtkfns.c (Fx_create_frame): Fix child frame border
resource names.
* src/pgtkterm.c (pgtk_clear_under_internal_border): Fix test
for child frames.  (bug#53018)
2022-01-05 10:16:56 +08:00
Po Lu
6719a3ccab Correctly set up XI key input mask on X Toolkit builds
* src/xfns.c (setup_xi_event_mask): Also set the key event mask
on the outer window, which might also have the input focus.
(x_window) [USE_X_TOOLKIT]: Set up XI event mask a bit later.
2022-01-05 09:39:57 +08:00
Daniel Mendler
30d4cfc080 completion--nth-completion: Throw meaningful error
If a configured completion style does not exist, throw a meaningful
error. Also make completion-styles-alist a defvar, since completion
styles like orderless extend it.

* lisp/minibuffer.el (completion-styles-alist): Make it a defvar.
(completion--nth-completion): Give a more meaningful error.
2022-01-04 19:16:37 -05:00
Paul Eggert
c899d9742a Update from gnulib 2022-01-04 13:17:25 -08:00
Robert Pluim
a0263cfee3 Remove ambiguity from key-valid-p docstring
* lisp/keymap.el (key-valid-p): Be explicit about the separator
being one and only one space.
2022-01-04 16:43:03 +01:00
Lars Ingebrigtsen
0d315102fe Improve pp-emacs-lisp-code for #'
* lisp/emacs-lisp/pp.el (pp--insert-lisp): Format (function ...)
as #'.
2022-01-04 15:51:04 +01:00
Eli Zaretskii
38b4bbb7e1 A cleaner fix for display bug#52947
* src/xdisp.c (tab_bar_height, redisplay_tab_bar): Don't call
set_iterator_to_next here...
(display_tab_bar_line): ...call it here, even if we exit the loop
because we encounter a newline.
2022-01-04 15:37:16 +02:00
Jimmy Aguilar Mena
aa7d0e9a92 Autoload decorator for windmove-mode 2022-01-04 14:15:10 +01:00
Po Lu
c36741f9c5 Translate more modifiers to GDK ones in xwidgets
* src/xwidget.c (xw_translate_x_modifiers): Also handle Control
and ShiftMask.
2022-01-04 19:56:58 +08:00
Po Lu
377bf26ebe Stop assuming X kbd state works with GDK when forwarding events to xwidgets
* src/xwidget.c (xw_translate_x_modifiers): New function.
(Fxwidget_perform_lispy_event): Translate X modifiers to GDK
modifiers before sending them to the xwidget.
2022-01-04 19:30:07 +08:00
Po Lu
4309679742 Make `x-file-dialog' arity match documentation on Haiku
* lisp/term/haiku-win.el (x-file-dialog): Fix arity.
2022-01-04 11:18:15 +00:00
Alan Third
2d4b2e296b Remove macOS drop-shadows on some frames (bug#28512)
* src/nsterm.m ([EmacsWindow setParentChildRelationships]): Remove
shadows on undecorated child frames.
2022-01-04 10:55:12 +00:00
Po Lu
3e247bd34c ; * configure.ac: Move some AC_SUBSTs to the correct location. 2022-01-04 17:51:05 +08:00
Stefan Kangas
61b57ec6de Remove unnecessary autoload cookie in font-core.el
* lisp/font-core.el (font-lock-defaults): Remove autoload of
risky-local-variable property; this file is preloaded.
2022-01-04 09:52:27 +01:00
Yuuki Harano
183936ee8e Remove gsettings.m4 and write directly into Makefile.in
* configure.ac (HAVE_PGTK): Declare substitution
(HAVE_GSETTINGS): Declare substitution
* Makefile.in (HAVE_PGTK): New variable
(HAVE_GSETTINGS): New variable
(gsettingsschemadir): Don't use value from gsettings.m4
(distclean): Add clean-gsettings-schemas
(install-gsettings-schemas): Implement instead of gsettings.m4
(uninstall-gsettings-schemas): Implement instead of gsettings.m4
(clean-gsettings-schemas): Implement instead of gsettings.m4
($(gsettings_SCHEMAS:.xml=.valid)): Implement instead of gsettings.m4
* m4/gsettings.m4: Remove
2022-01-04 17:29:17 +09:00
Jim Porter
3eaf3aeec8 Prevent further cases of duplicated separators in context menus
In some cases, context menu items are added before the overall prompt
string.  This could cause multiple consecutive separators to appear if
they "surround" the prompt string.  (Bug#52293)

* lisp/mouse.el (context-menu-map): Improve the de-duplication logic
to ignore non-menu-items when checking for consecutive separators.

* test/lisp/mouse-tests.el
(context-menu-map-remove-consecutive-separators)
(context-menu-map-remove-separators-at-beginning-or-end): New tests.
2022-01-04 10:18:15 +02:00
Po Lu
9651be5b48 Fix unused variable warning in last change
* src/haiku_draw_support.c (BBitmap_transform_bitmap): Fix
unused variable warning.
2022-01-04 08:14:40 +00:00
Po Lu
a851e5a669 Rationalize Haiku rectangle handling
* src/haiku_draw_support.cc (BView_DrawBitmapWithEraseOp):
(BView_DrawMask):
(rotate_bitmap_270):
(rotate_bitmap_90):
(BBitmap_transform_bitmap):
* src/haiku_support.cc (UnZoom):
(GetParentWidthHeight):
(MakeFullscreen):
(AttachCairoSurface):
(AfterResize):
(DrawContent):
(BView_cr_dump_clipping): Use new rectangle handling macros.

* src/haiku_support.h (BE_RECT_WIDTH, BE_RECT_HEIGHT): New
macros.
2022-01-04 08:07:53 +00:00
Po Lu
cbbe235a90 Make menu bar key navigation work on Haiku
* src/haiku_support.cc (menu_bar_active_p): New variable.
(DispatchMessage): Pass through key events if the menu bar is
active.
(MenusBeginning, MenusEnd): Set `menu_bar_active_p' according
to the state of the menu bar.
(BMenuBar_delete): Clear `menu_bar_active_p'.

* src/haikufns.c (haiku_free_frame_resources): Block input only
after checking that F is a window system frame.
* src/haikumenu.c (Fhaiku_menu_bar_open): Update doc string.
2022-01-04 06:48:08 +00:00
Po Lu
693815e90f Improve Haiku frame restacking logic
* src/haiku_support.cc (BWindow_is_active):
* src/haiku_support.h (BWindow_is_active): New functions.

* src/haikufns.c (Fhaiku_frame_restack): Prevent the newly
raised frame from being sent to the back of the display.
2022-01-04 06:10:25 +00:00
Po Lu
3a7a88d2f8 Merge branch 'master' of git.sv.gnu.org:/srv/git/emacs 2022-01-04 05:26:40 +00:00
Po Lu
f3481f21f7 Find a way to make restacking frames work on Haiku
* doc/lispref/frames.texi (Raising and Lowering): Update
documentation to reflect that restacking frames is now
supported on Haiku.
* lisp/frame.el (haiku-frame-restack): New declaration.
(frame-restack): Use `haiku-frame-restack' on Haiku.

* src/haiku_support.cc (BWindow_send_behind):
* src/haiku_support.h (BWindow_send_behind):
* src/haikufns.c (Fhaiku_frame_restack): New functions.
(syms_of_haikufns): New subr `haiku-frame-restack'.
2022-01-04 05:22:56 +00:00
Stefan Kangas
565fd09d9b * test/src/doc-tests.el: New file. 2022-01-04 05:38:00 +01:00
Po Lu
6668a7608c Add effective group to xkey events when handling XI key press events
* src/xterm.c (handle_one_xevent): Add effective group to
xkey.state when translating XI key events.
2022-01-04 11:17:59 +08:00
Stefan Kangas
24a52df738 Fix two unused variable warnings in make-docfile.c
* lib-src/make-docfile.c (scan_lisp_file): Fix unused variable
warnings.
2022-01-04 03:52:42 +01:00
Stefan Kangas
417a3ebaa2 Test that buffer exists in shortdoc-all-groups-work
* test/lisp/emacs-lisp/shortdoc-tests.el
(shortdoc-all-groups-work): Test that the shortdoc buffer was created.
2022-01-04 03:52:42 +01:00
Po Lu
cd7e7834ba Fix Haiku bitmap sanity checks
* src/haikufns.c (haiku_get_pixel, haiku_put_pixel): Fix sanity
checking of coordinate values.
2022-01-04 02:21:23 +00:00
Po Lu
a89bc0fe9c Fix fringe bitmap display on haiku again
* src/haiku_draw_support.cc (BView_DrawBitmapWithEraseOp): Fix
off-by-one errors.
2022-01-04 02:01:30 +00:00
Po Lu
7eb86a1788 Fix duplicate file panel display on Haiku
* lisp/term/haiku-win.el (x-file-dialog): Fix up prompt to look
better.

* src/haiku_support.cc (be_popup_file_dialog): Remove duplicate
call to `Show'.
2022-01-04 01:30:27 +00:00
Stefan Kangas
5c63786cb9 New test shortdoc-all-groups-work
* test/lisp/emacs-lisp/shortdoc-tests.el
(shortdoc-all-groups-work): New test.  See Bug#52969.
2022-01-03 21:40:38 +01:00
Stefan Monnier
460f35e96d Revert part of 59732a83c8 to fix bug#52969
While we don't need to put docstrings of .elc files into etc/DOC,
we still need to put those of `loaddefs.el` there since we don't have
a "dynamic docstring" feature for the non-compiled files and keeping
the actual docstrings in the heap would be prohibitive.

* src/Makefile.in ($(etc)/DOC): Scan `lisp/loaddefs.el` still.

* lib-src/make-docfile.c (scan_lisp_file): New function.
(scan_file): Use it.
(skip_white, read_lisp_symbol, search_lisp_doc_at_eol): New functions.
2022-01-03 15:04:12 -05:00
Po Lu
ab5ee3e29e * src/haiku_font_support.cc (BFont_char_bounds): Fix bearings. 2022-01-03 13:57:13 +00:00
Po Lu
c7768382cc Synchronize at a better place when making a frame visible on Haiku
* src/haiku_support.cc (BWindow_set_visible): Stop synchronizing
here.

* src/haikufns.c (haiku_visualize_frame):
(haiku_unvisualize_frame): Sychronize after visibility changes.
2022-01-03 11:07:29 +00:00
Po Lu
4efaabaf27 Implement AC line status for the Haiku battery function
* lisp/battery.el (battery--search-haiku-acpi-status): Return
`fully-charged' instead of `normal'.
(battery-haiku-acpi-battery): Implement %L for AC line status.
2022-01-03 10:18:08 +00:00
Stefan Kangas
bd9a09bb6b elide-head: Make GPL regexp more forgiving
* lisp/elide-head.el (elide-head-headers-to-hide): Make GPL regexp
more forgiving.
* test/lisp/elide-head-tests.el (elide-head--add-test): New macro.
(elide-head--test-headers-to-hide/gpl2-1)
(elide-head--test-headers-to-hide/gpl3-1)
(elide-head--test-headers-to-hide/gpl3-2)
(elide-head--test-headers-to-hide/gpl3-3)
(elide-head--test-headers-to-hide/gpl3-4): New tests.
2022-01-03 09:04:09 +01:00
Po Lu
61c35e415c Fix battery load calculation on Haiku
* lisp/battery.el (battery-haiku-acpi-battery): Fix load
calculation.
2022-01-03 15:44:51 +08:00
Po Lu
f563fbf53b Add support for the Haiku ACPI battery driver
* lisp/battery.el (battery-status-function): Choose
`battery-haiku-acpi-battery' if the Haiku ACPI driver is
available.
(battery--search-haiku-acpi-status):
(battery-haiku-acpi-battery): New functions.
2022-01-03 15:40:48 +08:00
Stefan Kangas
d8959347d9 * lisp/elide-head.el (elide-head-headers-to-hide): Simplify. 2022-01-03 07:52:55 +01:00
Stefan Kangas
8d6a8f660d Silence byte-compiler in eieio tests
This is a temporary workaround for Bug#52971.
* test/lisp/emacs-lisp/eieio-tests/eieio-test-methodinvoke.el
(eieio-compat)
* test/lisp/emacs-lisp/eieio-tests/eieio-tests.el (eieio-compat):
Silence byte-compiler by wrapping require in with-no-warnings.
2022-01-03 05:00:11 +01:00
Po Lu
f6501fded7 Don't try to guess a delta if a scroll valuator's state is unknown
* src/xterm.c (x_get_scroll_valuator_delta): Return DBL_MAX if
the scroll valuator's value is unknown.
2022-01-03 11:21:16 +08:00
Po Lu
01047cf13f Revert "Stop sending touch-end events if coalescing scroll events"
This reverts commit a6952f78f3.
2022-01-03 11:17:43 +08:00
Po Lu
7544ede1bc Use XKB to find modifiers on x
* src/xterm.c (x_find_modifier_meanings): Look for virtual
modifiers with Xkb instead.
(handle_one_xevent): Add group when translating XI2 keycodes and
handle Xkb keymap events.
(x_term_init): Populate dpyinfo->xkb_event_type.

* src/xterm.h (struct x_display_info): New field
`xkb_event_type', and change modifier masks to `unsigned int'.
2022-01-03 10:56:45 +08:00
Po Lu
a4cb14b536 * src/haikumenu.c (haiku_menu_show): Fix input blocking. 2022-01-03 00:59:58 +00:00
Stefan Kangas
7ddfe1cab2 Move define-keymap and defvar-keymap to keymap.el
These functions deal with the "new" keymap binding interface, so they
belong in keymap.el rather than in subr.el.
* lisp/subr.el (define-keymap--compile, define-keymap)
(defvar-keymap): Move from here ...
* lisp/keymap.el (define-keymap--compile, define-keymap)
(defvar-keymap): ... to here.
2022-01-02 23:33:41 +01:00
Stefan Monnier
04c0245d36 Merge remote-tracking branch 'origin/emacs-28' into trunk 2022-01-02 17:07:42 -05:00
Eli Zaretskii
6e53178a37 Avoid inflooping when 'tab-bar-format' includes embedded newlines
* src/xdisp.c (tab_bar_height, redisplay_tab_bar): Support
'tab-bar-format' with embedded newlines.  (Bug#52947)
2022-01-02 21:36:13 +02:00
Stefan Kangas
9e7191048b elide-head: Add support for modified BSD license
* lisp/elide-head.el (elide-head-headers-to-hide): Add support for
the modified BSD license (3-clause BSD).
2022-01-02 19:26:34 +01:00
Juri Linkov
83da3a09d0 * lisp/tab-line.el: Revert part of the fix in a6adfe21e4 (bug#52881)
(tab-line--get-tab-property, tab-line-auto-hscroll): Use get-pos-property
instead of get-text-property that fails after previous-single-property-change.
2022-01-02 20:00:40 +02:00
Stefan Kangas
984391a9dc New :type key for defcustom
As compared to the old type key-sequence that deals with raw key
sequences, this :type conforms to the format used by the new keymap-*
functions.
* lisp/wid-edit.el (key): New widget type.  (Bug#52523)
(widget-key-prompt-value-history): New variable.
(widget-key-validate): New function.
(key-sequence): Doc fix.
* doc/lispref/customize.texi (Simple Types): Document above new type.
2022-01-02 16:46:02 +01:00
Mattias Engdegård
b2167d9843 Don't fail flymake-tests if gcc actually is Clang
* test/lisp/progmodes/flymake-tests.el (flymake-tests--gcc-is-clang)
(different-diagnostic-types, included-c-header-files): Skip tests that
depend on the `gcc` command really being GCC and not Clang.
2022-01-02 13:59:07 +01:00