1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-11-25 07:28:20 +00:00
Commit Graph

290 Commits

Author SHA1 Message Date
Stefan Kangas
4df832750c Don't start docstrings with "This function"
* lisp/calculator.el (calculator-add-operators):
* lisp/erc/erc-log.el (erc-generate-log-file-name-with-date)
(erc-generate-log-file-name-short):
* lisp/eshell/esh-mode.el (eshell-begin-on-new-line):
* lisp/progmodes/hideif.el (hif-merge-ifdef-region):
* lisp/tab-bar.el (tab-bar--event-to-item):
* lisp/textmodes/artist.el (artist-no-rb-unset-point2)
(artist-no-rb-unset-points):
* lisp/which-key.el (which-key--hide-popup): Don't start function
docstrings with "This function".
2024-11-01 23:56:12 +01:00
Juri Linkov
2c062dfdf5 Call tab-bar-tab-post-open-functions during tabs initialization
* lisp/tab-bar.el (tab-bar-tabs): Run the hook
'tab-bar-tab-post-open-functions' after creating the first tab
in the selected frame's tab-bar list of tabs (bug#74087).
Suggested by Ship Mints <shipmints@gmail.com>.
2024-10-30 20:32:28 +02:00
Eli Zaretskii
6dcd3d2404 Merge from origin/emacs-30
b420e149b1 Fix a typo in ediff-init.el
e1304e9b1b Fix 'chart-space-usage' on MS-Windows
04c44405bf Fix alignment and documentation of vtable.el
4d6fadb8d2 ; * lisp/which-key.el: Fix ':package-version' (bug#73072).
54071b9cef ; Improve doc strings of 'tab-bar-mode' and 'tab-line-mode'
87a8b12a0c Fix test failure in erc-networks-tests
dad0935cfc ; * doc/emacs/building.texi (Lisp Libraries): Update (bug...
e4dc6711b0 Fix :hook in 'use-package'
c1cd036d27 ; * doc/lispref/modes.texi (Mode Line Data): Fox wording.
ae2463796f ; Caveats about using :eval in 'mode-line-format'
4047072c7d Update FSF's address
24f12bdd77 Support the new option in ruby-ts-mode too
6c15b7710d Add new option ruby-bracketed-args-indent
7799ef4335 Fix Rmail base64 and qp decoding of MIME payloads
0def396fa8 Update to Org 9.7.11
8c044bd972 ; Fix recent changes in documentation
e0d8879bcd * test/lisp/emacs-lisp/tabulated-list-tests.el: Add missi...
4ff4b78f92 ; Small doc fixes
da980ad838 ; Reword some "allows Xing"
2ca7d5649c ; More accurate text about how `equal` compares various o...

# Conflicts:
#	etc/NEWS
2024-09-07 06:25:15 -04:00
Eli Zaretskii
54071b9cef ; Improve doc strings of 'tab-bar-mode' and 'tab-line-mode'
* lisp/tab-line.el (tab-line-mode):
* lisp/tab-bar.el (tab-bar-mode): Doc fixes (bug#73049)
2024-09-05 22:09:40 +03:00
Sean Whitton
da980ad838 ; Reword some "allows Xing"
* doc/emacs/anti.texi (Antinews):
* etc/NEWS:
* etc/NEWS.29:
* lisp/tab-bar.el (tab-bar-select-restore-windows):
* lisp/vc/vc-git.el (vc-git-print-log-follow): Reword to avoid
"allows Xing".  This is reported to be better for non-native
readers.  Based on suggestions of Eli Zaretskii <eliz@gnu.org>.
2024-09-01 11:20:25 +01:00
Eli Zaretskii
d1f896b5f8 Merge from origin/emacs-30
4b60267d83 Make Python skeletons available in 'python-ts-mode' as well
62dcbfb776 Merge branch 'emacs-30' of git.savannah.gnu.org:/srv/git/...
1baa62b2ac ; * etc/NEWS: Fix typos.
dfcfaa0ef5 More accurate documentation of 'equal' in ELisp Reference
baaf97ce1a ; Fix some ungrammatical uses of "allows to"

# Conflicts:
#	etc/NEWS
2024-08-31 08:14:13 -04:00
Sean Whitton
baaf97ce1a ; Fix some ungrammatical uses of "allows to"
* doc/emacs/anti.texi (Antinews):
* etc/NEWS:
* etc/NEWS.29:
* lib/cdefs.h:
* lisp/tab-bar.el (tab-bar-select-restore-windows):
* lisp/vc/vc-git.el (vc-git-print-log-follow):
* m4/gnulib-common.m4 (gl_CHECK_FUNCS_SET_RESULTS):
(gl_CHECK_FUNCS_ANDROID): Fix ungrammatical uses of "allows to".
2024-08-30 11:47:35 +01:00
Juri Linkov
60da504cf7 * lisp/tab-bar.el: Improve tab-bar-auto-width-predicate-default (bug#71883).
(tab-bar--auto-width-faces-default): New variable with the
value from the default value of tab-bar-auto-width-faces.
(tab-bar-auto-width-faces): Set the default value to
tab-bar--auto-width-faces-default.
(tab-bar-auto-width-predicate-default): For backwards-compatibility
use the old logic of checking tab-bar-auto-width-faces when its value
was changed.  Otherwise, check for a symbol, but remove "current-group"
from the list of symbols.
2024-08-19 19:56:31 +03:00
Joseph Turner
9ed761a793 Add abnormal hook to determine which tabs to auto-widen
* lisp/tab-bar.el (tab-bar-auto-width-predicate-default):  Default value
for tab-bar-auto-width-functions.
(tab-bar-auto-width-functions): New abnormal hook.
(tab-bar-auto-width): Run new abnormal hook until success instead of
comparing text properties.
2024-08-19 19:50:02 +03:00
Juri Linkov
7b49261b5e * lisp/tab-bar.el (tab-bar--format-tab-group): Add 'current-group'.
Use current-group symbol for current tab group item (bug#71883).
2024-08-06 10:01:05 +03:00
Juri Linkov
7a14f60b90 * lisp/tab-bar.el (tab-bar-tab-group-format-default): Hide hints.
Don't display hints when tab-bar-show-inactive-group-tabs is customized
to t (bug#71939).  Suggested by Ship Mints <shipmints@gmail.com>.
2024-08-05 09:56:38 +03:00
Po Lu
96097d3623 Merge from savannah/emacs-30
1154d8aafe Better resolve bug#72188
ceb5a15222 MacOS: Let EmacsView implement NSTextInputClient
9f7c1ace9f NS: Set frame position when entering/exiting fullscreen (...
74fe889a93 Merge branch 'emacs-30' of git.savannah.gnu.org:/srv/git/...
abefd9514b * lisp/tab-bar.el (tab-bar-move-tab-to-group): Fix for a ...
e09982f8f5 Merge branch 'emacs-30' of git.savannah.gnu.org:/srv/git/...
5cf64d8377 Fix sporadic crashes and `select' failures in dumped images
a475360af9 Correct display of Doc View documents after tab switching
b0d927e1dc Merge branch 'emacs-30' of git.savannah.gnu.org:/srv/git/...
469bc7c968 Use 'kill-process' as a fallback when a pipe gets broken ...
158835668d ; * doc/lispref/modes.texi (Mode Line Data): Fix formatting.
2024-08-01 08:25:31 +08:00
Juri Linkov
63e609f6aa * lisp/tab-bar.el (tab-bar-show-inactive-group-tabs): New defcustom.
(tab-bar-format-tabs-groups): Use it (bug#71939).
Suggested by Ship Mints <shipmints@gmail.com>.
2024-07-29 21:27:30 +03:00
Juri Linkov
abefd9514b * lisp/tab-bar.el (tab-bar-move-tab-to-group): Fix for a new group's tab.
Move tab with a new group to the end of the tab bar (bug#72352)
Suggested by Ship Mints <shipmints@gmail.com>
2024-07-29 21:16:16 +03:00
Juri Linkov
339310d020 * lisp/tab-bar.el (tab-bar-select-restore-windows): Improve the docstring.
Suggested by Kévin Le Gouguec <kevin.legouguec@gmail.com> in bug#71779.
2024-06-27 19:58:27 +03:00
Juri Linkov
4a0958642d * lisp/tab-bar.el (tab-bar-tab-group-face-function): Improve doc (bug#71733). 2024-06-24 19:57:57 +03:00
Po Lu
ed122417b9 Improve scaling of tab bar items on high-density displays
* lisp/tab-bar.el (tab-bar-auto-width-max)
(tab-bar-auto-width-min): Accept values of a new format where
the pixel width is a list and is subject to scaling.
(tab-bar-auto-width-1): New function.
(tab-bar-auto-width): Scale pixel values from t-b-a-w-min and
t-b-a-w-max.
2024-06-08 15:18:27 +08:00
Juri Linkov
13d8b0eb63 * lisp/tab-bar.el (tab-bar-mouse-1): Avoid infinite recursion (bug#70086). 2024-05-06 20:10:43 +03:00
Juri Linkov
6e835dfaca * lisp/tab-bar.el (tab-bar-select-restore-windows): Use 'special-mode'. 2024-05-06 19:48:04 +03:00
Juri Linkov
9ecd65a660 * lisp/tab-bar.el: Support mouse clicks for multi-item 'global-mode-string'.
(tab-bar-format-global): Split elements of 'global-mode-string'
to separate items of the tab bar, so events for each item are
handled separately (bug#70086).
2024-05-06 19:43:50 +03:00
Juri Linkov
14cd4fce4b * lisp/tab-bar.el: Support mouse clicks bound in keymap properties.
(tab-bar--event-to-item): Handle mouse bindings for commands
bound in keymap properties of global-mode-string (bug#70086).
(tab-bar-mouse-down-1, tab-bar-mouse-1, tab-bar-touchscreen-begin):
Add the symbol 'global' to the list of handled items.
2024-05-02 20:55:03 +03:00
Juri Linkov
a914667a00 Make the buffer displayed by tab-bar-select-restore-windows internal
* lisp/tab-bar.el (tab-bar-select-restore-windows): Make the buffer
" *Old buffer %s*" internal with the leading space in its name.
2024-05-02 20:44:04 +03:00
Juri Linkov
50fab7062d * lisp/tab-bar.el (tab-bar-mode-map): New keymap (bug#69578).
(tab-bar-select-tab-modifiers): Call tab-bar--undefine-keys
before set-default in :set of defcustom.
(tab-bar--define-keys, tab-bar--undefine-keys):
Change keybindings in tab-bar-mode-map instead of the global map.
Move checking of global-key-binding to tab-bar-mode--tab-key-bind.
(tab-bar-mode--tab-key-bind): New internal function.
2024-04-05 19:23:08 +03:00
Juri Linkov
c3781bf59e New functions to set and use context of window points (bug#33871)
* lisp/dired.el (dired-mode): Set buffer-local
'window-point-context-set-function' to remember 'dired-filename'
or 'position' in the window with the Dired buffer.
Set buffer-local 'window-point-context-use-function' to restore
the remembered position of the window point.

* lisp/tab-bar.el (tab-bar--tab): Use window-point-context-set.
(tab-bar-select-restore-context): New user option.
(tab-bar-select-tab): Use window-point-context-use.

* lisp/window.el: Add '(context . writable)' to
'window-persistent-parameters'.
(window-point-context-set, window-point-context-use): New functions.
(window-point-context-set-default-function)
(window-point-context-use-default-function): New functions.
(window-point-context-set-function)
(window-point-context-use-function): New variables.
2024-04-02 20:19:21 +03:00
Juri Linkov
c29b6df227 * lisp/tab-bar.el (tab-bar-select-restore-windows): New defcustom.
(tab-bar-select-restore-windows): New function.
(tab-bar-select-tab): Let-bind window-restore-killed-buffer-windows
to tab-bar-select-restore-windows (bug#68235).
2024-03-17 19:57:05 +02:00
Juri Linkov
3cb0614507 * lisp/tab-bar.el (tab-bar-tab-post-select-functions): New hook (bug#69093).
(tab-bar-select-tab): Call tab-bar-tab-post-select-functions at the end.
2024-03-05 19:14:28 +02:00
Juri Linkov
29e59b835c * lisp/tab-bar.el: Fixes for point in window configuration (bug#68235)
(tab-bar--tab): Instead of 'point-marker', use 'copy-marker' with the TYPE
argument set to 'window-point-insertion-type'.  This will allow point to
follow the output after switching tabs when point is at the end of
a comint/compilation buffer.
(tab-bar-select-tab): Remove ad-hoc rule for the reverted dired buffer.
2024-01-09 19:22:40 +02:00
Po Lu
ecf08f0621 Merge from savannah/emacs-29
dc4e6b1329 ; Update copyright years in more files
64b3777631 ; Run set-copyright from admin.el
8e1c56ae46 ; Add 2024 to copyright years

# Conflicts:
#	doc/misc/modus-themes.org
#	doc/misc/texinfo.tex
#	etc/NEWS
#	etc/refcards/ru-refcard.tex
#	etc/themes/modus-operandi-theme.el
#	etc/themes/modus-themes.el
#	etc/themes/modus-vivendi-theme.el
#	lib/alloca.in.h
#	lib/binary-io.h
#	lib/c-ctype.h
#	lib/c-strcasecmp.c
#	lib/c-strncasecmp.c
#	lib/careadlinkat.c
#	lib/cloexec.c
#	lib/close-stream.c
#	lib/diffseq.h
#	lib/dup2.c
#	lib/filemode.h
#	lib/fpending.c
#	lib/fpending.h
#	lib/fsusage.c
#	lib/getgroups.c
#	lib/getloadavg.c
#	lib/gettext.h
#	lib/gettime.c
#	lib/gettimeofday.c
#	lib/group-member.c
#	lib/malloc.c
#	lib/md5-stream.c
#	lib/md5.c
#	lib/md5.h
#	lib/memmem.c
#	lib/memrchr.c
#	lib/nanosleep.c
#	lib/save-cwd.h
#	lib/sha1.c
#	lib/sig2str.c
#	lib/stdlib.in.h
#	lib/strtoimax.c
#	lib/strtol.c
#	lib/strtoll.c
#	lib/time_r.c
#	lib/xalloc-oversized.h
#	lisp/auth-source-pass.el
#	lisp/emacs-lisp/lisp-mnt.el
#	lisp/emacs-lisp/timer.el
#	lisp/info-look.el
#	lisp/jit-lock.el
#	lisp/loadhist.el
#	lisp/mail/rmail.el
#	lisp/net/ntlm.el
#	lisp/net/webjump.el
#	lisp/progmodes/asm-mode.el
#	lisp/progmodes/project.el
#	lisp/progmodes/sh-script.el
#	lisp/textmodes/flyspell.el
#	lisp/textmodes/reftex-toc.el
#	lisp/textmodes/reftex.el
#	lisp/textmodes/tex-mode.el
#	lisp/url/url-gw.el
#	m4/alloca.m4
#	m4/clock_time.m4
#	m4/d-type.m4
#	m4/dirent_h.m4
#	m4/dup2.m4
#	m4/euidaccess.m4
#	m4/fchmodat.m4
#	m4/filemode.m4
#	m4/fsusage.m4
#	m4/getgroups.m4
#	m4/getloadavg.m4
#	m4/getrandom.m4
#	m4/gettime.m4
#	m4/gettimeofday.m4
#	m4/gnulib-common.m4
#	m4/group-member.m4
#	m4/inttypes.m4
#	m4/malloc.m4
#	m4/manywarnings.m4
#	m4/mempcpy.m4
#	m4/memrchr.m4
#	m4/mkostemp.m4
#	m4/mktime.m4
#	m4/nproc.m4
#	m4/nstrftime.m4
#	m4/pathmax.m4
#	m4/pipe2.m4
#	m4/pselect.m4
#	m4/pthread_sigmask.m4
#	m4/readlink.m4
#	m4/realloc.m4
#	m4/sig2str.m4
#	m4/ssize_t.m4
#	m4/stat-time.m4
#	m4/stddef_h.m4
#	m4/stdint.m4
#	m4/stdio_h.m4
#	m4/stdlib_h.m4
#	m4/stpcpy.m4
#	m4/strnlen.m4
#	m4/strtoimax.m4
#	m4/strtoll.m4
#	m4/time_h.m4
#	m4/timegm.m4
#	m4/timer_time.m4
#	m4/timespec.m4
#	m4/unistd_h.m4
#	m4/warnings.m4
#	nt/configure.bat
#	nt/preprep.c
#	test/lisp/register-tests.el
2024-01-02 10:28:14 +08:00
Po Lu
8e1c56ae46 ; Add 2024 to copyright years 2024-01-02 09:47:10 +08:00
Po Lu
451e00e786 ; Fix compiler warnings
* lisp/tab-bar.el (touch-screen-delay):

* lisp/tab-line.el (touch-screen-delay): Declare variables.

* lisp/touch-screen.el (touch-screen-hold): Autoload.
2023-12-07 13:14:51 +08:00
Petteri Hintsanen
f39cd59ed4 * lisp/tab-bar.el: Fix the close button with auto-width (bug#66678).
(tab-bar-auto-width): Take into account the length of tab-bar-close-button
more than one character: " x".
2023-10-22 20:41:14 +03:00
Petteri Hintsanen
5d1e6f759f * lisp/tab-bar.el: Fix the close button with auto-width (bug#66678).
(tab-bar-auto-width): Take into account the length of tab-bar-close-button
more than one character: " x".
Don't merge to master.
2023-10-22 20:39:16 +03:00
Juri Linkov
74dffcdf4f * lisp/tab-bar.el (tab-bar-auto-width): Don't check if width changes.
Remove the condition '(< curr-width prev-width)' that was intended to check
if the width stopped to change.  But actually it's not only unneeded,
but causes a bug: when the name contains a combining character, then
the width doesn't change, and the name truncation stops too early.
2023-09-19 20:51:07 +03:00
Juri Linkov
3c14cab797 ; * tab-bar, tab-line: Use integer 1 instead of float for height em. 2023-09-19 20:44:16 +03:00
Stefan Monnier
913ae070e6 * lisp/tab-bar.el (cl--set-substring): Remove left-over autoload
And remove left-over `require` of `seq` while at it.
2023-09-04 16:41:40 -04:00
Juri Linkov
30decd1d97 Fix height of new SVG icons on tab-bar and tab-line (bug#62562)
* lisp/tab-bar.el (tab-bar--load-buttons): Add ':height (1.0 . em)'
to icons tab-bar-new, tab-bar-menu-bar.
(tab-bar-history-mode): Add ':height (1.0 . em)'
to icons tab-bar-back, tab-bar-forward.

* lisp/tab-line.el (tab-line-new, tab-line-left, tab-line-right):
Add ':height (1.0 . em)' to these icons.
2023-09-01 09:56:59 +03:00
Juri Linkov
76938e1789 * lisp/tab-bar.el: Add tab-bar-tab-name-format-functions (bug#65554)
(tab-bar-tab-name-format-truncated)
(tab-bar-tab-name-format-hints)
(tab-bar-tab-name-format-close-button)
(tab-bar-tab-name-format-face): New functions.
(tab-bar-tab-name-format-functions): New defcustom.
(tab-bar-tab-name-format-default): Rewrite to use
'tab-bar-tab-name-format-functions'.
2023-08-28 19:57:16 +03:00
Juri Linkov
123060841d * lisp/tab-bar.el: Show full tab names on tooltips (bug#65554).
(tab-bar--format-tab): Use tab names for :help strings.
It's useful to see original tab names when the tab-bar displays names
truncated by tab-bar-auto-width, etc.
(tab-bar-format-menu-bar): Fix string case for consistency with other items.
2023-08-28 09:52:36 +03:00
Juri Linkov
9500e7df86 Use new SVG icons in tab-bar and tab-line (bug#62562)
* lisp/tab-bar.el (tab-bar--load-buttons):
Add "symbols/plus_16.svg" to tab-bar-new.
Add "symbols/cross_16.svg" to tab-bar-close.
Add "symbols/menu_16.svg" to tab-bar-menu-bar.
(tab-bar-tab-name-format-default): Use 'add-face-text-property'.
(tab-bar-history-mode):
Add "symbols/chevron_left_16.svg" to tab-bar-back.
Add "symbols/chevron_right_16.svg" to tab-bar-forward.

* lisp/tab-line.el (tab-line-new): New icon with "symbols/plus_16.svg".
(tab-line-new-button): Use it with nil rear-nonsticky.
(tab-line-close): New icon with "symbols/cross_16.svg".
(tab-line-close-button): Use it with nil rear-nonsticky.
(tab-line-left): New icon with "symbols/chevron_left_16.svg".
(tab-line-left-button): Use it with nil rear-nonsticky.
(tab-line-right): New icon with "symbols/chevron_right_16.svg".
(tab-line-right-button): Use it with nil rear-nonsticky.
(tab-line-tab-name-format-default): Use 'add-face-text-property'.
(tab-line-auto-hscroll): Append the face in 'add-face-text-property'.
2023-08-27 20:27:35 +03:00
Po Lu
2867f62484 Merge remote-tracking branch 'origin/master' into feature/android 2023-08-06 07:38:10 +08:00
Michael Albinus
479c0543b6 Merge from origin/emacs-29
f2b2c752a5 Fix documentation of saveplace facilities for Dired
4ed9d61c89 ; * lisp/tab-bar.el: Autoload cl--set-substring, as that ...
30976ecd8d ; * lisp/bindings.el (mode-line-modes): Fix typo (bug#650...
8574ef314c Fix loaddef generation with ";;;foo-autoload" cookies in ...
8cbd4a02a2 Delete comment saying that project.el is experimental
2023-08-05 18:18:30 +02:00
Eli Zaretskii
4ed9d61c89 ; * lisp/tab-bar.el: Autoload cl--set-substring, as that is needed for loadup. 2023-08-05 10:31:20 +03:00
Po Lu
089a710ab0 Improve word selection behavior
* lisp/tab-bar.el (tab-bar-map): Don't bind touch-screen-drag.
* lisp/touch-screen.el (touch-screen-drag): Extend the region
based on the position of the mark, not the position of point
relative to EVENT.
(touch-screen-translate-touch): Don't generate virtual function
keys for non-mouse events.
(function-key-map): Remove redundant definitions.
* src/keyboard.c (read_key_sequence): Don't generate *-bar
prefix keys for mock input (such as input from function key
translation.)
2023-07-17 12:58:29 +08:00
Po Lu
64256d2923 Update Android port
* doc/lispref/commands.texi (Touchscreen Events): Improve
documentation.
* lisp/tab-bar.el (tab-bar-map): Bind `[tab-bar
touchscreen-hold]'.
* lisp/touch-screen.el (touch-screen-hold, touch-screen-drag):
New functions.
(touch-screen-handle-timeout): Generate a `touchscreen-hold'
event instead.
(touch-screen-handle-point-update): Generate a
`touchscreen-drag' event upon dragging.
(touch-screen-translate-touch): Cancel touch screen timer upon
exit.
* src/keyboard.c (access_keymap_keyremap): Take unsigned int
start and end instead.
2023-07-16 17:29:58 +08:00
Po Lu
dcf0fc2c43 Merge remote-tracking branch 'origin/master' into feature/android 2023-07-08 08:53:55 +08:00
Juri Linkov
51807e12da * lisp/tab-bar.el: Fix tab-bar-tab-name-current for active minibuffer.
(tab-bar-tab-name-current): Use get-mru-window in the active minibuffer
when minibuffer-selected-window is nil after switching to another tab.
(tab-bar-tab-name-current-with-count)
(tab-bar-tab-name-truncated): Use tab-bar-tab-name-current.
2023-07-07 10:18:43 +03:00
Juri Linkov
0522049864 * lisp/tab-bar.el: Improve tab-bar-minibuffer-restore-tab (bug#64373).
(tab-bar-select-tab): Set tab-bar-minibuffer-restore-tab and
minibuffer-exit-hook minibuffer-locally to handle recursive minibuffers
for non-nil read-minibuffer-restore-windows.
(tab-bar-minibuffer-restore-tab): No need to reset minibuffer-local values.
2023-07-07 09:33:56 +03:00
Po Lu
af8232a150 Merge remote-tracking branch 'origin/master' into feature/android 2023-07-06 08:34:26 +08:00
Juri Linkov
1dc2d5441e * lisp/tab-bar.el: Restore the original tab where minibuffer was activated.
(tab-bar-minibuffer-restore-tab): New variable and function.
(tab-bar-select-tab): Use them (bug#64373).
2023-07-05 20:20:48 +03:00
Po Lu
cdca0fddcc Merge remote-tracking branch 'origin/master' into feature/android 2023-05-27 09:49:49 +08:00