1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-27 07:41:28 -08:00
Commit graph

153708 commits

Author SHA1 Message Date
Po Lu
ebe2b6fd0d * src/haikufns.c (Fx_display_mm_width): Fix copy-paste error. 2022-01-19 06:00:13 +00:00
Po Lu
95084cec09 Rename system tooltip variables to `use-system-tooltips'
* doc/emacs/frames.texi (Tooltips):
* doc/emacs/haiku.texi (Haiku Basics):
* doc/lispref/display.texi (Tooltips): Document
`use-system-tooltips' instead.

* etc/NEWS: Announce new option.
* lisp/cus-start.el (standard): Add new option.

* lisp/term/haiku-win.el (haiku-use-system-tooltips):
* lisp/term/pgtk-win.el (x-gtk-use-system-tooltips):
* lisp/term/x-win.el (x-gtk-use-system-tooltips): Add aliases
for old options.

* src/frame.c (syms_of_frame): New variable
`use-system-tooltips'.

* src/haikufns.c (Fx_show_tip):
(syms_of_haikufns):
* src/pgtkfns.c (x_hide_tip):
(Fx_show_tip):
(syms_of_pgtkfns):
* src/xfns.c (x_hide_tip):
(Fx_show_tip):
(syms_of_xfns): Use `use-system-tooltips' instead of the old
platform dependent options.
2022-01-19 13:12:18 +08:00
Po Lu
90dda33108 Use more reliable timestamps for some kinds of events on Haiku
* src/haiku_support.cc (DispatchMessage):
(MouseMoved):
(MouseDown):
(MouseUp): Set `time' field of event structures to input server
time.
* src/haiku_support.h (struct haiku_key_event):
(struct haiku_mouse_motion_event):
(struct haiku_button_event): New field `time'.
* src/haikuterm.c (haiku_read_socket): Use input server time
if provided.
2022-01-19 02:08:52 +00:00
Po Lu
d5723560d5 Fix event timestamp generation on Haiku
* src/haikuterm.c (haiku_read_socket): Use miliseconds for event
time.
2022-01-19 01:14:19 +00:00
Stefan Monnier
5a502ff1e5 cl-generic-tests.el: Fix warning
* test/lisp/emacs-lisp/cl-generic-tests.el (ert): Require at run-time
for `ert--get-explainer`.
2022-01-18 16:53:28 -05:00
Stefan Monnier
0f558e3be9 VC: Fix tests for SCCS and Mtn
* test/lisp/vc/vc-tests.el: Prefer closures to `(lambda ...).
(vc-test-mtn05-rename-file, vc-test-mtn06-version-diff): Skip.

* lisp/vc/vc.el (vc-responsible-backend): Fix vc-test--register on SCCS.
2022-01-18 16:42:19 -05:00
Stefan Monnier
ea1e5c97e3 autoload.el: Fix corner case and avoid encoding issues
* lisp/emacs-lisp/autoload.el (autoload-print-form): Don't burp when
autoloading a `cl-defmethod`.
(autoload-rubric): Support non-UTF-8 chars and enforce Unix EOLs.
2022-01-18 16:40:32 -05:00
Eli Zaretskii
877c4e849f Improve doc strings in textsec.el
* lisp/international/textsec.el (textsec-mixed-numbers-p)
(textsec-ascii-confusable-p, textsec-resolved-script-set)
(textsec-single-script-confusable-p)
(textsec-mixed-script-confusable-p)
(textsec-whole-script-confusable-p, textsec-domain-suspicious-p)
(textsec-local-address-suspicious-p, textsec-name-suspicious-p)
(textsec-suspicious-nonspacing-p): Doc fix.
2022-01-18 21:08:19 +02:00
Eli Zaretskii
f558c35a93 Remove 'cuneiform-numbers-and-punctuation' from w32font.c
* src/w32font.c (syms_of_w32font, font_supported_scripts): Remove
'cuneiform-numbers-and-punctuation'.  Reported by Kévin Le Gouguec
<kevin.legouguec@gmail.com>.
2022-01-18 16:24:36 +02:00
Lars Ingebrigtsen
5006e19856 The name in textsec-email-suspicious-p is optional
* lisp/international/textsec.el (textsec-email-suspicious-p): The
name is optional.
2022-01-18 13:34:39 +01:00
Lars Ingebrigtsen
ce63f91025 Add textsec functions for verifying email addresses
* lisp/international/characters.el (bidi-control-characters):
Rename from glyphless--bidi-control-characters for use in textsec,
and add LRM/RLM/ALM.
(update-glyphless-char-display): Adjust the code.

* lisp/international/textsec.el (textsec-local-address-suspicious-p)
(textsec-name-suspicious-p, textsec-suspicious-nonspacing-p)
(textsec-email-suspicious-p): New functions.
2022-01-18 13:20:04 +01:00
Po Lu
4f23dbaa67 Intern virtual modifier atoms the smart way on X
* src/xterm.c (x_find_modifier_meanings): Get rid of calls to
XInternAtom.
(x_term_init): Initialize atom refs for virtual modifiers and
make sure to only call `x_find_modifier_meanings' after they
are interned.
* src/xterm.h (struct x_display_info): New fields for virtual
modifier atoms.
2022-01-18 19:54:22 +08:00
Lars Ingebrigtsen
9f25c41ad4 Add textsec-domain-suspicious-p
* .gitignore: Ignore idna-mapping.el.

* admin/notes/unicode: Note idna-mapping file.
* admin/unidata/IdnaMappingTable.txt: New file.

* admin/unidata/Makefile.in (all): Generate idna-mapping.el.

* admin/unidata/unidata-gen.el (unidata-gen-idna-mapping): Generate.

* lisp/international/textsec.el (textsec-domain-suspicious-p): New
function.
2022-01-18 11:53:09 +01:00
Michael Albinus
702ce8dc3e Morka handling of multi-hops in Tramp more consistent
* lisp/net/tramp.el (tramp-make-tramp-file-name): Adapt argument list.
Add hops to `tramp-default-proxies-alist'.
(tramp-find-foreign-file-name-handler): Adapt argument list.
(tramp-handle-abbreviate-file-name): Abbreviate multi-hops.
(tramp-handle-file-remote-p): Adapt handling of hops.
(tramp-add-hops): New defun.
(tramp-compute-multi-hops): Use it.

* lisp/net/tramp.el (tramp-make-tramp-hop-name, tramp-get-buffer)
(tramp-file-name-handler, tramp-handle-file-truename)
(tramp-handle-insert-file-contents, tramp-local-host-p)
(tramp-read-passwd, tramp-clear-passwd):
* lisp/net/tramp-archive.el (tramp-archive-dissect-file-name)
(tramp-archive-gvfs-file-name):
* lisp/net/tramp-cache.el (tramp-get-hash-table):
* lisp/net/tramp-sh.el (tramp-sh-handle-file-truename)
(tramp-sh-handle-make-process, tramp-sh-handle-process-file)
(tramp-sh-file-name-handler-p, tramp-get-remote-path):
* lisp/net/tramp-sshfs.el (tramp-sshfs-handle-process-file):
* lisp/net/tramp-sudoedit.el (tramp-sudoedit-handle-file-truename):
Adapt callees.

* test/lisp/net/tramp-tests.el (tramp-test02-file-name-dissect)
(tramp-test02-file-name-dissect-simplified)
(tramp-test02-file-name-dissect-separate)
(tramp-test07-abbreviate-file-name): Adapt tests.
2022-01-18 11:27:15 +01:00
Po Lu
d0c0f5f648 * src/haikuterm.c (haiku_read_socket): Add work for frame size bug.
BWindow::ResizeTo seems to have the same rounding issues that
BRect has, but I have no idea how to solve it there.  As a
temporary workaround until a solution has been found, avoid
garbaging tooltip frames when FrameResized reports different
dimensions from what they were set to.
2022-01-18 09:42:21 +00:00
Lars Ingebrigtsen
4eebf528fc Add textsec predicates for different types of confusability
* lisp/international/textsec.el (textsec-resolved-script-set)
(textsec-single-script-confusable-p)
(textsec-mixed-script-confusable-p)
(textsec-whole-script-confusable-p): New functions.
2022-01-18 10:24:32 +01:00
Lars Ingebrigtsen
19fefea1ca Add textsec support for confusable characters
* admin/notes/unicode: Note the confusables.txt file.
* admin/unidata/Makefile.in (${unidir}/uni-confusable.el):
Generate the confusable file.

* admin/unidata/README (https): Add confusables.txt.

* admin/unidata/confusables.txt: New file.

* admin/unidata/unidata-gen.el (unidata-gen-confusable): Parse the
confusables.txt file.

* lisp/international/textsec.el (textsec-ascii-confusable-p)
(textsec-unconfuse-string): New functions.
2022-01-18 09:57:54 +01:00
Lars Ingebrigtsen
65c9f57856 Improve textsec-restriction-level doc string
* lisp/international/textsec.el (textsec-restriction-level):
Improve doc string.
2022-01-18 09:57:54 +01:00
Po Lu
68472c12e7 * src/haikufns.c (Fx_show_tip): Fix typo. 2022-01-18 08:21:43 +00:00
Po Lu
98286799a5 Fix default value of `no-special-glyphs' frame parameter on Haiku
* src/haikufns.c (haiku_create_frame): Make `no-special-glyphs'
nil by default.
2022-01-18 08:21:42 +00:00
Po Lu
d556e75af8 Improve tooltip implementation on Haiku
This fixes several issues: tooltips having no right internal
border, reusing tooltips occasionally freezing Emacs, and
inconsistent behaviour when compared to X.

* src/haiku_support.cc (BWindow_resize): Revert a recent change.
(BView_move_frame):
(BWindow_set_avoid_focus): Stop sync'ing when locked.  This
tends to cause lockups for an unknown reason.
* src/haikufns.c (initial_setup_back_buffer): New function.
(haiku_create_frame): Remove tooltip related code.
(haiku_set_internal_border_width): Handle cases where the face
cache is NULL and/or the window has not been created.
(haiku_set_inhibit_double_buffering): Likewise.
(haiku_create_tip_frame): New function.
(Fx_create_frame): Remove tooltip specific code.
(Fx_show_tip): Synchronize code with X.

* src/haikuterm.c (haiku_new_font): Don't adjust size on tooltip
frames.
(haiku_read_socket): Draw internal border on tooltip frames
during resize.
(haiku_clear_under_internal_border): Handle cases where the face
cache is NULL.
2022-01-18 08:21:42 +00:00
Po Lu
c99e28207a * lisp/tooltip.el (tooltip-show-help): Fix typo. 2022-01-18 15:56:08 +08:00
Po Lu
77b5bd4cdb * lisp/tooltip.el: Fix warning when built on a non-Haiku system. 2022-01-18 11:35:44 +08:00
Eli Zaretskii
8fe828db78 ; * lisp/international/fontset.el (setup-default-fontset): Fix last change. 2022-01-18 05:33:28 +02:00
Po Lu
0a010902d7 Fix system tooltips above menus
* src/haikufns.c (Fx_show_tip): Disable frame reuse inside a
menu.
(syms_of_haikufns): New symbol `tooltip-reuse-hidden-frame'.
2022-01-18 02:41:29 +00:00
Po Lu
0c0b77b3cc Allow non-system tooltips to display above menus on Haiku
* doc/emacs/haiku.texi (Haiku Basics): Document that tooltips
can now be displayed above the menu bar.

* lisp/tooltip.el (tooltip-show-help): Only display help text in
the echo area if Haiku system tooltips are enabled.

* src/haiku_support.cc (FlipBuffers): Stop flushing view.
* src/haikufns.c (Fx_show_tip): Fix a sizing bug leading to
tooltips needing two redisplays to display correctly.
* src/haikuterm.c (haiku_read_socket): Ignore resize events on
tooltips.
2022-01-18 02:06:00 +00:00
Stefan Monnier
2dad332a14 (hack-local-variables--find-variables): Use user-error
* lisp/files.el (hack-local-variables--find-variables):
Incorrect formatting are not coding errors.
2022-01-17 16:28:02 -05:00
Eli Zaretskii
0ddc03cf8c Fix minor inconsistencies in 'char-script-table'
* admin/unidata/blocks.awk (name2alias): Map some obscure blocks
to their native scripts, to follow Scripts.txt.

* lisp/international/characters.el (char-script-table): Add
few exceptions.
* lisp/international/fontset.el (script-representative-chars):
Remove scripts no longer used.
2022-01-17 21:49:58 +02:00
Robert Pluim
346747451f ; textsec.el: fix typo
* lisp/international/textsec.el (textsec-covering-scripts): Fix typo
in docstring.
2022-01-17 18:24:31 +01:00
Eli Zaretskii
ef1f5dfe2b Doc fixes in textsec.el
* lisp/international/textsec.el (textsec-scripts)
(textsec-single-script-p, textsec-covering-scripts): Clarify "script".
2022-01-17 19:15:30 +02:00
Eli Zaretskii
fd17eb67c0 ; * admin/notes/unicode: Update. 2022-01-17 19:09:22 +02:00
Lars Ingebrigtsen
9f902eb808 Change textsec-mixed-numbers-p to use recommended algorithm
* lisp/international/textsec.el (textsec-mixed-numbers-p): New
function.
2022-01-17 18:01:59 +01:00
Lars Ingebrigtsen
1c7307673b Add new function textsec-mixed-numbers-p
* lisp/international/textsec.el (textsec-mixed-numbers-p): New
function.
2022-01-17 17:32:58 +01:00
Lars Ingebrigtsen
9b358a99d6 Add some textsec-restriction-level comments
* lisp/international/textsec.el (textsec-restriction-level): Add
comment about source of the list of languages.
2022-01-17 16:27:10 +01:00
Lars Ingebrigtsen
a1ffee1e82 Add textsec-restriction-level function
* lisp/international/textsec.el (textsec-restriction-level): New
function.
2022-01-17 16:24:17 +01:00
Lars Ingebrigtsen
523a96a99e Fix some doc strings in textsec.el
* lisp/international/textsec.el (textsec-single-script-p): Fix
typo in doc string.
(textsec-covering-scripts): Improve doc string and sort the results.
2022-01-17 16:06:04 +01:00
Lars Ingebrigtsen
5b6aa79aef Avoid loading the possibly stale unidata-gen.elc file
* admin/unidata/Makefile.in (${unidir}/uni-scripts.el): Fix .elc
  staleness.  (Should probably be fixed in a different way.)
2022-01-17 15:51:58 +01:00
Lars Ingebrigtsen
e2c8091113 Add support for functions that deal with Unicode scripts
* admin/unidata/Makefile.in (${unidir}/uni-scripts.el): Build
uni-scripts.el.

* admin/unidata/Scripts.txt:
* admin/unidata/ScriptExtensions.txt:
* admin/unidata/PropertyValueAliases.txt: New files from Unicode.

* admin/unidata/README: Update.

* admin/unidata/unidata-gen.el (unidata-gen-charprop): Allow
writing other data, too.
(unidata-gen-scripts, unidata-gen--read-script-aliases)
(unidata-gen--insert-file): New functions to parse the Script* files.

* lisp/international/textsec.el: Implement some functions that
work on scripts.
2022-01-17 15:47:50 +01:00
Lars Ingebrigtsen
39d4e1ca21 Move the Gnus range functions to a new range.el file
* lisp/emacs-lisp/range.el: New file.

* lisp/gnus/gnus-agent.el (range):
(gnus-agent-synchronize-group-flags):
(gnus-agent-possibly-alter-active):
(gnus-agent-fetch-headers):
(gnus-agent-read-agentview):
(gnus-agent-fetch-group-1):
(gnus-agent-read-p):
(gnus-agent-expire-group-1):
(gnus-agent-retrieve-headers): Adjust callers.

* lisp/gnus/gnus-art.el (range):
(gnus-article-describe-bindings):

* lisp/gnus/gnus-cloud.el (range):
(gnus-cloud-available-chunks):

* lisp/gnus/gnus-draft.el (gnus-group-send-queue):

* lisp/gnus/gnus-group.el (range):
(gnus-group-line-format-alist):
(gnus-number-of-unseen-articles-in-group):
(gnus-group-update-eval-form):
(gnus-group-read-group):
(gnus-group-delete-articles):
(gnus-group-catchup):
(gnus-group-expire-articles-1):
(gnus-add-marked-articles):

* lisp/gnus/gnus-int.el (gnus-request-marks):

* lisp/gnus/gnus-kill.el (gnus-apply-kill-file-internal):

* lisp/gnus/gnus-range.el (gnus-range-difference)
(gnus-sorted-range-intersection, gnus-uncompress-range)
(gnus-add-to-range, gnus-remove-from-range)
(gnus-member-of-range, gnus-list-range-intersection)
(gnus-list-range-difference, gnus-range-length, gnus-range-add)
(gnus-range-map): Make into obsolete aliases.

* lisp/gnus/gnus-start.el (gnus-make-articles-unread):
(gnus-convert-old-ticks):
(gnus-read-old-newsrc-el-file):

* lisp/gnus/gnus-sum.el (gnus-select-newsgroup):
(gnus-articles-to-read):
(gnus-articles-to-read):
(gnus-killed-articles):
(gnus-adjust-marked-articles):
(gnus-update-marks):
(gnus-update-marks):
(gnus-compute-read-articles):
(gnus-list-of-read-articles):
(gnus-summary-update-info):
(gnus-summary-move-article):
(gnus-summary-expire-articles):
(gnus-update-read-articles):
(gnus-summary-insert-old-articles):
(gnus-summary-insert-old-articles):
(gnus-summary-insert-old-articles):

* lisp/gnus/mail-source.el (gnus-range):
(gnus-compress-sequence):

* lisp/gnus/nnheader.el (range):
(gnus-range-add):
(nnheader-update-marks-actions):

* lisp/gnus/nnimap.el (nnimap-update-info):
(nnimap-update-info):
(nnimap-update-info):
(nnimap-update-qresync-info):
(nnimap-update-qresync-info):
(nnimap-update-qresync-info):
(nnimap-parse-copied-articles):

* lisp/gnus/nnmaildir.el (nnmaildir-request-update-info):
(nnmaildir-request-update-info):
(nnmaildir-request-expire-articles):
(nnmaildir-request-expire-articles):
(nnmaildir-request-set-mark):

* lisp/gnus/nnmairix.el (nnmairix-request-set-mark):

* lisp/gnus/nnmbox.el (nnmbox-record-active-article):
(nnmbox-record-deleted-article):

* lisp/gnus/nnml.el (nnml-request-compact-group):

* lisp/gnus/nnvirtual.el (nnvirtual-request-expire-articles):
* lisp/gnus/nnselect.el (numbers-by-group):
(nnselect-request-update-info):
(nnselect-push-info):
2022-01-17 15:47:50 +01:00
Po Lu
ab17e35325 Merge from origin/emacs-28
f393d0d441 Fix regression leading to flickering tooltips when the mou...
2022-01-17 21:45:44 +08:00
Po Lu
5205be5106 ; Merge from origin/emacs-28
The following commit was skipped:

9e64aeff40 * Fix native comp for non trivial function names (bug#52833)
2022-01-17 21:45:44 +08:00
Po Lu
f393d0d441 Fix regression leading to flickering tooltips when the mouse is moved
* lisp/tooltip.el (tooltip-show-help): Compare string with
previous tooltip string ignoring properties.
2022-01-17 21:42:31 +08:00
Eli Zaretskii
8cc1b9035c Revert "Add undelete-frame-max instead of undelete-frame-mode (bug#51883)"
This reverts commit 714e11d535.

That commit was unilateral and disregarded past discussions.
2022-01-17 14:51:53 +02:00
Eli Zaretskii
37d46cec60 Revert "* etc/NEWS: Improve wording of 'undelete-frame-max' (bug#51883)."
This reverts commit 65666c4786.

The original commit was unilateral and disregarded past
discussions.
2022-01-17 14:51:03 +02:00
Po Lu
412247c53f Fix Emacs icon not appearing on Haiku
* lib-src/be_resources.cc (main): Scale input bitmap
appropriately before setting it as the mini and large icons.
* src/Makefile.in (Emacs): Add dependency on
`lib-src/be-resources'.
2022-01-17 11:09:50 +00:00
Andrea Corallo
9e64aeff40 * Fix native comp for non trivial function names (bug#52833)
* lisp/emacs-lisp/comp.el (comp-c-func-name): Fix native compilation
for functions with function names containing non trivial
characters (bug#52833).

This commit is the backport of e7699bf290.

Do not merge to master
2022-01-17 11:54:52 +01:00
Po Lu
1cd6737a38 Use BControlLook to determine scroll bar size on Haiku
* src/haiku_support.cc (BScrollBar_default_size): Use
BControlLook instead of legacy constants.
2022-01-17 10:46:55 +00:00
Po Lu
2fa1eced39 Display override redirect frames in all workspaces on Haiku
* src/haiku_support.cc (class EmacsWindow): New field
`pre_override_redirect_workspaces'.
(BWindow_set_override_redirect): Set window to display on all
workspaces.
2022-01-17 10:08:04 +00:00
Michael Albinus
c9d06d080b Improve handling of INFILE in tramp*-process-file (Bug#53284)
* lisp/net/tramp-adb.el (tramp-adb-handle-process-file):
* lisp/net/tramp-sh.el (tramp-sh-handle-process-file):
* lisp/net/tramp-smb.el (tramp-smb-handle-process-file):
* lisp/net/tramp-sshfs.el (tramp-sshfs-handle-process-file):
Improve handling of INFILE.  Fix thinko using
`process-file-side-effects'.  (Bug#53284)

* lisp/net/tramp-sshfs.el (tramp-sshfs-file-name-handler-alist):
Use `tramp-sshfs-handle-set-file-times'.
(tramp-sshfs-handle-set-file-times): New defun.

* test/lisp/net/tramp-tests.el (tramp-test28-process-file): Extend test.
2022-01-17 10:46:58 +01:00
Juri Linkov
65666c4786 * etc/NEWS: Improve wording of 'undelete-frame-max' (bug#51883). 2022-01-17 10:24:20 +02:00