1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-06 06:20:55 -08:00

Fix tabulated-list-widen-current-column widening wrong column

* tabulated-list.el (tabulated-list-widen-current-column): Use correct
comparison operation when checking if point is within the column
bounds  (bug#53375).

Copyright-paperwork-exempt: yes
This commit is contained in:
Thuna 2022-01-23 15:55:48 +01:00 committed by Lars Ingebrigtsen
parent d0f3de72b6
commit 80098a2830

View file

@ -739,17 +739,17 @@ Interactively, N is the prefix numeric argument, and defaults to
col-width)
(while (and (not found)
(< col-nb nb-cols))
(if (> start
(setq total-width
(+ total-width
(max (setq col-width
(cadr (aref tabulated-list-format
col-nb)))
(string-width (aref entry col-nb)))
(or (plist-get (nthcdr 3 (aref tabulated-list-format
col-nb))
:pad-right)
1))))
(if (>= start
(setq total-width
(+ total-width
(max (setq col-width
(cadr (aref tabulated-list-format
col-nb)))
(string-width (aref entry col-nb)))
(or (plist-get (nthcdr 3 (aref tabulated-list-format
col-nb))
:pad-right)
1))))
(setq col-nb (1+ col-nb))
(setq found t)
(setf (cadr (aref tabulated-list-format col-nb))