From debbugs-submit-bounces@debbugs.gnu.org Sun Oct 18 16:00:28 2020 Received: (at submit) by debbugs.gnu.org; 18 Oct 2020 20:00:28 +0000 Received: from localhost ([127.0.0.1]:39138 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUEqx-00016q-Ox for submit@debbugs.gnu.org; Sun, 18 Oct 2020 16:00:28 -0400 Received: from lists.gnu.org ([209.51.188.17]:35516) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUEqv-00016h-Ok for submit@debbugs.gnu.org; Sun, 18 Oct 2020 16:00:26 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60828) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kUEqv-0007d4-El for bug-gnu-emacs@gnu.org; Sun, 18 Oct 2020 16:00:25 -0400 Received: from mout.gmx.net ([212.227.17.22]:42019) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kUEqs-0005hu-7V for bug-gnu-emacs@gnu.org; Sun, 18 Oct 2020 16:00:25 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1603051219; bh=P7+sK1ABvr0XbmmqZe8LIWRzoEAyUMarXnNJ1p0yAmE=; h=X-UI-Sender-Class:From:To:Subject:Date; b=elnvVYj65PQmJR5HRGFBxTR16XfZ08RoEEDBUK50UQe19v/0th4ewnwFgRr3UWnzu OjzE9NHDQrTIUOpWWz2SGKMExDnjEfQDNv5hDt1mM35TiCHBVP26X1lGsFgJdeovTz rzr//2CboH/JNoZdLmw8h0jdJH2fe2RTfnC4Rjuk= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([178.6.223.210]) by mail.gmx.com (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1M1Hdq-1kSZtQ3Z2Q-002rT7 for ; Sun, 18 Oct 2020 22:00:19 +0200 From: Stephen Berman To: bug-gnu-emacs@gnu.org Subject: 28.0.50; Faulty uses of tabulated-list-format Date: Sun, 18 Oct 2020 22:00:13 +0200 Message-ID: <87imb7e242.fsf@gmx.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Provags-ID: V03:K1:fmosVtfG6cYM6RfldVmzujsKXwViyHKOOxcvrEvhsrPqKsd/S9M 8OWR6cEqrE0s/Zjs2GNb4HKQ9YsJTvVMeFVn55uQZzDRSrF4A57dRFM0wWiN8pGziqzZ+GW ZHYVDsnhONNhy+ylxQsE4iJ6GWFTt2bWuAazMS13JTYhOeIni0G5Mu6i0aExYd7D7FyiPMM /qRFcSAxX0lJZAOE1drzA== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:HE20P2jdNE4=:OehJDVnVI/t0T7jge5s4AF k75ZznKnKROIFow0V9LdoqWhaVPejTDxkJVS1ygynC+RRrN5N0I6DN1pb07S54I5jqmLdIVGW YjDl13kynUPyMUVPAs0XCVqHN/zZ0K8hBB/lPfdJDHt1a4nQJybWDPkTbD5NZoAr+9IdVh5nB fQGNCh3BqopCYZ0YQk5cNr0p5yV7J0jnaN+v3saIQh3KiKai7LYyaEK+fU7/RKTSgQIEPyGBD DYj3QZ9IphjaNZrGSYWpwbX7ZN2P/hDHIvIcXirsmcvosQW8BBAcxX2+H1UZ+WxpZZi+RCTlY u2gP0BKOPwQyr+18cWvI9wTzLONFIg3JGohjZrU1wA+Xedda9Oktj4AxXM4DqHe1Q4mHVabEF Gx6y1cB11MXy2TOOltB/x2YezV5E8Yh2MxQhO96bYoS8l3nInAorx4zkNgGh0SytJuKmHRMiH RqTd2rrftHCfpvOFKKJc9UrykdMDBUSBFFAmJRd0nU1cCCNuyITdSv1htS/WmLTPvV5sMJF47 xz1Pe0TEIHmAFYXhCqMtSPuWZrvurIrqmophPRwt0ryPKw8VLaRNUWq5TMa1/L3F6lU80Jl9o Wqld4ZzmMeDat41zZnIYqOFNmH/6/ADiIb5CVtLhtpxWlBW81lAY9eoAs0y+bkzGIAaBjNmFR OPsatOR4Gi35Wr1cntx1w6op4iZbIE0nMWBOkoyCv+9j+uM1bIN/LkfPyfg3jzHm6dGSB146q WTyDIWjwo7lfnhjVvPIuZhnviDKsGHzulBF6NewsOf+Pbu4DYhWaFw0SVh+0eV2OBObmflzkG K8LYKkq3bmJAtlNCSRlHvyOXKACY0R0vy996W83hbJ38mIvEyx+1eEbp1+CPc2EBkrh7gng7v sSV+22tkMoyR6JDDnN4g== Received-SPF: pass client-ip=212.227.17.22; envelope-from=stephen.berman@gmx.net; helo=mout.gmx.net X-detected-operating-system: by eggs.gnu.org: First seen = 2020/10/18 16:00:19 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.4 (--) --=-=-= Content-Type: text/plain On trying out the new tabulated-list implementation of the bookmarks list I noticed that, when clicking on the File header, the sort indicator is not displayed, unlike with the Bookmark header. Then I noticed that the same thing happens in the tabulated buffer list (C-x C-b). Then I grepped for all uses of tabulated-list-format in the Emacs sources and found the same problem in most of them. The reason is that in these modes the width of at least one of the columns is too narrow, so that tabulated-list-init-header omits the indicator. In most cases the problematic column is the final one, but in a couple of cases there are also non-final too narrow columns. And I think these bugs are due to a misleading description in tabulated-list-format's doc string. The attached patch corrects the doc string and the problematic uses of tabulated-list-format. The patch also fixes a typo and tries to improve column alignment in timer-list-mode: this is one of the few modes derived from tabulated-list-mode whose column widths didn't need to be corrected, but the alignment seemed suboptimal; however, when the header line uses a variable-pitch face, the alignment is still suboptimal even with the patch, and I don't know how to fix that. In GNU Emacs 28.0.50 (build 34, x86_64-pc-linux-gnu, GTK+ Version 3.24.17, cairo version 1.17.3) of 2020-10-18 built on strobe-jhalfs Repository revision: b7dfae3a8168977013e8de1df0916c51e76e7326 Repository branch: master Windowing system distributor 'The X.Org Foundation', version 11.0.12008000 System Description: Linux From Scratch SVN-20200401 2020-10-18 Stephen Berman Fix uses of tabulated-list-format * lisp/emacs-lisp/tabulated-list.el (tabulated-list-format): Correct the documentation of the WIDTH element. * lisp/bookmark.el (bookmark-bmenu-mode): * lisp/buff-menu.el (list-buffers--refresh): * lisp/emacs-lisp/package.el (package-menu-mode) (package-archive-column-width): * lisp/misc.el (list-dynamic-libraries--refresh): * lisp/org/org-lint.el (org-lint--report-mode): * lisp/progmodes/flymake.el (flymake-diagnostics-buffer-mode): * lisp/simple.el (process-menu-mode): Increase column width in order to display sort indicator. * lisp/emacs-lisp/timer-list.el (timer-list-mode): Improve column alignment. (timer-list--function-predicate): Correct typo in doc string. --=-=-= Content-Type: text/x-patch Content-Disposition: attachment Content-Description: Fix uses of tabulated-list-format Content-Transfer-Encoding: quoted-printable diff --git a/lisp/bookmark.el b/lisp/bookmark.el index ab7b04ddfe..f37f0b0ce9 100644 =2D-- a/lisp/bookmark.el +++ b/lisp/bookmark.el @@ -1783,7 +1783,7 @@ bookmark-bmenu-mode `[("" 1) ;; Space to add "*" for bookmark with annotation ("Bookmark" ,bookmark-bmenu-file-column bookmark-bmenu--name-pr= edicate) ,@(if bookmark-bmenu-toggle-filenames - '(("File" 0 bookmark-bmenu--file-predicate)))]) + '(("File" 6 bookmark-bmenu--file-predicate)))]) (setq tabulated-list-padding bookmark-bmenu-marks-width) (setq tabulated-list-sort-key '("Bookmark" . nil)) (add-hook 'tabulated-list-revert-hook #'bookmark-bmenu--revert nil t)' diff --git a/lisp/buff-menu.el b/lisp/buff-menu.el index d06ba28787..5cf13cb50f 100644 =2D-- a/lisp/buff-menu.el +++ b/lisp/buff-menu.el @@ -706,7 +706,7 @@ list-buffers--refresh `("Size" ,size-width tabulated-list-entry-size-> :right-align t) `("Mode" ,Buffer-menu-mode-width t) - '("File" 1 t))) + '("File" 6 t))) (setq tabulated-list-use-header-line Buffer-menu-use-header-line) (setq tabulated-list-entries (nreverse entries))) (tabulated-list-init-header)) diff --git a/lisp/emacs-lisp/package.el b/lisp/emacs-lisp/package.el index 7b192d640b..32b99367c3 100644 =2D-- a/lisp/emacs-lisp/package.el +++ b/lisp/emacs-lisp/package.el @@ -412,7 +412,7 @@ package-status-column-width :type 'number :version "28.1") -(defcustom package-archive-column-width 8 +(defcustom package-archive-column-width 9 "Column width for the Package status in the package menu." :type 'number :version "28.1") @@ -2770,7 +2770,7 @@ package-menu-mode ("Status" ,package-status-column-width package-menu--status-p= redicate) ,@(if (cdr package-archives) `(("Archive" ,package-archive-column-width package-menu--= archive-predicate))) - ("Description" 0 package-menu--description-predicate)]) + ("Description" 13 package-menu--description-predicate)]) (setq tabulated-list-padding 2) (setq tabulated-list-sort-key (cons "Status" nil)) (add-hook 'tabulated-list-revert-hook #'package-menu--refresh nil t) diff --git a/lisp/emacs-lisp/tabulated-list.el b/lisp/emacs-lisp/tabulated= -list.el index b13f609f88..20e43d9c4a 100644 =2D-- a/lisp/emacs-lisp/tabulated-list.el +++ b/lisp/emacs-lisp/tabulated-list.el @@ -91,7 +91,9 @@ tabulated-list-format This is the label for the column in the header line. Different columns must have non-`equal' names. - WIDTH is the width to reserve for the column. - For the final element, its numerical value is ignored. + Its value must be at least 2 more than the length of NAME + in order to display the column's sort indicator. + Not used for computing the width of the final element. - SORT specifies how to sort entries by this column. If nil, this column cannot be used for sorting. If t, sort by comparing the string value printed in the column. diff --git a/lisp/emacs-lisp/timer-list.el b/lisp/emacs-lisp/timer-list.el index 00d09696d2..afcd7d3354 100644 =2D-- a/lisp/emacs-lisp/timer-list.el +++ b/lisp/emacs-lisp/timer-list.el @@ -93,8 +93,8 @@ timer-list-mode (setq-local revert-buffer-function #'list-timers) (setq tabulated-list-format '[("Idle" 6 timer-list--idle-predicate) - (" Next" 12 timer-list--next-predicate) - (" Repeat" 11 timer-list--repeat-predicate) + ("Next" 12 timer-list--next-predicate :right-align t :pad-right= 1) + ("Repeat" 11 timer-list--repeat-predicate :right-align t :pad-r= ight 1) ("Function" 10 timer-list--function-predicate)])) (defun timer-list--idle-predicate (A B) @@ -119,7 +119,7 @@ timer-list--repeat-predicate (string< rA rB))) (defun timer-list--function-predicate (A B) - "Predicate to sort Timer-List by the Next column." + "Predicate to sort Timer-List by the Function column." (let ((fA (aref (cadr A) 3)) (fB (aref (cadr B) 3))) (string< fA fB))) diff --git a/lisp/misc.el b/lisp/misc.el index be191c50d2..b65f56efc3 100644 =2D-- a/lisp/misc.el +++ b/lisp/misc.el @@ -170,9 +170,9 @@ list-dynamic-libraries--refresh (name-len (apply 'max (mapcar 'length (cdr lib))))) (when (> id-len max-id-len) (setq max-id-len id-len)) (when (> name-len max-name-len) (setq max-name-len name-len= )))) - (vector (list "Library" (1+ max-id-len) t) - (list "Loaded from" (1+ max-name-len) t) - (list "Candidate names" 0 t)))) + (vector (list "Library" (+ max-id-len 2) t) + (list "Loaded from" (+ max-name-len 2) t) + (list "Candidate names" 17 t)))) (tabulated-list-init-header) (setq tabulated-list-entries nil) (dolist (lib dynamic-library-alist) diff --git a/lisp/org/org-lint.el b/lisp/org/org-lint.el index 5be1ec7286..0c3eca7998 100644 =2D-- a/lisp/org/org-lint.el +++ b/lisp/org/org-lint.el @@ -1089,8 +1089,8 @@ org-lint--report-mode (< (string-to-number (aref (cadr a) 0)) (string-to-number (aref (cadr b) 0)))) :right-align t) - ("Trust" 5 t) - ("Warning" 0 t)]) + ("Trust" 7 t) + ("Warning" 9 t)]) (tabulated-list-init-header)) (defun org-lint--generate-reports (buffer checkers) diff --git a/lisp/progmodes/flymake.el b/lisp/progmodes/flymake.el index b286208fff..602e8f2609 100644 =2D-- a/lisp/progmodes/flymake.el +++ b/lisp/progmodes/flymake.el @@ -1376,7 +1376,7 @@ flymake-diagnostics-buffer-mode "Flymake diagnostics" "A mode for listing Flymake diagnostics." (setq tabulated-list-format - `[("Line" 5 ,(lambda (l1 l2) + `[("Line" 6 ,(lambda (l1 l2) (< (plist-get (car l1) :line) (plist-get (car l2) :line))) :right-align t) @@ -1384,7 +1384,7 @@ flymake-diagnostics-buffer-mode ("Type" 8 ,(lambda (l1 l2) (< (plist-get (car l1) :severity) (plist-get (car l2) :severity)))) - ("Message" 0 t)]) + ("Message" 9 t)]) (setq tabulated-list-entries 'flymake--diagnostics-buffer-entries) (tabulated-list-init-header)) diff --git a/lisp/simple.el b/lisp/simple.el index d6fce922c4..b34450aeb5 100644 =2D-- a/lisp/simple.el +++ b/lisp/simple.el @@ -4388,13 +4388,13 @@ process-menu-mode "Major mode for listing the processes called by Emacs." (setq tabulated-list-format [("Process" 15 t) ("PID" 7 t) - ("Status" 7 t) + ("Status" 8 t) ;; 25 is the length of the long standard b= uffer ;; name "*Async Shell Command*<10>" (bug#3= 0016) ("Buffer" 25 t) ("TTY" 12 t) ("Thread" 12 t) - ("Command" 0 t)]) + ("Command" 9 t)]) (make-local-variable 'process-menu-query-only) (setq tabulated-list-sort-key (cons "Process" nil)) (add-hook 'tabulated-list-revert-hook 'list-processes--refresh nil t)) --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Sun Oct 18 17:33:29 2020 Received: (at 44068) by debbugs.gnu.org; 18 Oct 2020 21:33:29 +0000 Received: from localhost ([127.0.0.1]:39183 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUGIz-0003QB-3X for submit@debbugs.gnu.org; Sun, 18 Oct 2020 17:33:29 -0400 Received: from aserp2130.oracle.com ([141.146.126.79]:42968) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUGIx-0003Pw-4X for 44068@debbugs.gnu.org; Sun, 18 Oct 2020 17:33:27 -0400 Received: from pps.filterd (aserp2130.oracle.com [127.0.0.1]) by aserp2130.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 09ILTpUE163936; Sun, 18 Oct 2020 21:33:21 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=mime-version : message-id : date : from : sender : to : subject : references : in-reply-to : content-type : content-transfer-encoding; s=corp-2020-01-29; bh=q1lEeSICR4DNZijS8lL2WLqRQtM8XeHebhXh8qWxN3w=; b=j8A88x8qDfnRJ4TdIPfbSaNpgRQlvNjuvH9Qvnbth3r0sGbiA4odV1cvB2ZRTchxIZQG jEnIPryrcr+aTxVZT6yjDPSpZW6hBWyN6itfs5EUJptO1oBNURG3ADIFbYWOX6pLY0dd yR4YU8l8TDmfIRvZKba4T62QSmRphcSaQodb/vvcXbXQ8Q3G4sMP+8vTcwsb2Zp4PX9Z c0YxTftUO5IN4ieNi7Ml/poP+Y35TrO8uKYx5ylVoprjRCdLhV86iHDKfa2g2WkEW8To NZPX8agrsYgz6q9sVHjH11sYED5uPhh00Cg/aPUA1LZb95pmqoCji2oPahxkOpdYzwoT iQ== Received: from userp3020.oracle.com (userp3020.oracle.com [156.151.31.79]) by aserp2130.oracle.com with ESMTP id 347p4ak27p-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Sun, 18 Oct 2020 21:33:21 +0000 Received: from pps.filterd (userp3020.oracle.com [127.0.0.1]) by userp3020.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 09ILTk3e184128; Sun, 18 Oct 2020 21:33:20 GMT Received: from userv0121.oracle.com (userv0121.oracle.com [156.151.31.72]) by userp3020.oracle.com with ESMTP id 348acnt0fy-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sun, 18 Oct 2020 21:33:20 +0000 Received: from abhmp0013.oracle.com (abhmp0013.oracle.com [141.146.116.19]) by userv0121.oracle.com (8.14.4/8.13.8) with ESMTP id 09ILXJh0029075; Sun, 18 Oct 2020 21:33:19 GMT MIME-Version: 1.0 Message-ID: <9d13f9c2-f8dc-4f61-be5f-d60d485719bc@default> Date: Sun, 18 Oct 2020 14:33:18 -0700 (PDT) From: Drew Adams To: Stephen Berman , 44068@debbugs.gnu.org Subject: RE: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> In-Reply-To: <87imb7e242.fsf@gmx.net> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.5056.0 (x86)] Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9778 signatures=668682 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 phishscore=0 bulkscore=0 adultscore=0 mlxscore=0 malwarescore=0 suspectscore=0 spamscore=0 mlxlogscore=999 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2010180170 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9778 signatures=668682 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 priorityscore=1501 clxscore=1011 malwarescore=0 mlxscore=0 bulkscore=0 lowpriorityscore=0 phishscore=0 adultscore=0 mlxlogscore=999 impostorscore=0 spamscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2010180170 X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 44068 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > On trying out the new tabulated-list implementation of the bookmarks > list I noticed that, when clicking on the File header, the sort > indicator is not displayed, unlike with the Bookmark header. Then I > noticed that the same thing happens in the tabulated buffer list (C-x > C-b). Then I grepped for all uses of tabulated-list-format in the Emacs > sources and found the same problem in most of them. The reason is that > in these modes the width of at least one of the columns is too narrow, > so that tabulated-list-init-header omits the indicator. In most cases > the problematic column is the final one, but in a couple of cases there > are also non-final too narrow columns. And I think these bugs are due > to a misleading description in tabulated-list-format's doc string. The > attached patch corrects the doc string and the problematic uses of > tabulated-list-format. The patch also fixes a typo and tries to improve > column alignment in timer-list-mode: this is one of the few modes > derived from tabulated-list-mode whose column widths didn't need to be > corrected, but the alignment seemed suboptimal; however, when the header > line uses a variable-pitch face, the alignment is still suboptimal even > with the patch, and I don't know how to fix that. This rings a bell (maybe). I think the sort-indicator problem might be a duplicate bug report, but I can't find the dup now. There are some inherent problems with the rightmost column, IIRC, that being one of them. (Dunno whether this helps at all. Probably not.) From debbugs-submit-bounces@debbugs.gnu.org Sun Oct 18 18:01:40 2020 Received: (at 44068) by debbugs.gnu.org; 18 Oct 2020 22:01:40 +0000 Received: from localhost ([127.0.0.1]:39238 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUGkF-0006I2-SL for submit@debbugs.gnu.org; Sun, 18 Oct 2020 18:01:40 -0400 Received: from mail-ej1-f51.google.com ([209.85.218.51]:34305) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUGkE-0006Hc-9D for 44068@debbugs.gnu.org; Sun, 18 Oct 2020 18:01:38 -0400 Received: by mail-ej1-f51.google.com with SMTP id u8so11230181ejg.1 for <44068@debbugs.gnu.org>; Sun, 18 Oct 2020 15:01:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:in-reply-to:references:mime-version:date:message-id:subject:to; bh=kjRsHnLrpDeIswi+CeQXjbdTZqWDE5RGVzE1un+zk0I=; b=ObRRWIM9Hni1bd6izrW2ELY/gGcT30wE914uihfRpswGfa8p+4sjXn+dPp2321NG1F QqV38XhAGz8Er+QBeqciYig0CKDP1k54zMTzF++MBD6czGTGyE1iAvVtdQp4fyIMyikP xI9uePBlrbXCl1xu51jR5doQWlEFZJyt0y4c5HjZhSNOTWEgClIAqzSkASn9ovPfCrxr JCIMNZGMvU+UCz0fSfEGWMUIYYDFso0MARTjb/2u02gsfykCUAT5MtGY7OaOPs+sqnEU ELeHZ4glk7+Z+QvkIsxqwlrYUgx9vJ0q6tB7S/QitqH5i56eXH0SZU4+PYa9B9I0Ghw2 A7vw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:in-reply-to:references:mime-version:date :message-id:subject:to; bh=kjRsHnLrpDeIswi+CeQXjbdTZqWDE5RGVzE1un+zk0I=; b=ZhVERrWK/cnBJnYBbqWIF1HD0qiyYaWdUHclE8dB51AQD2FXcH+5OJV8IHnswkvPOa dH2VnCPiXUH0v/qSd+ZEYeq8YNAR6bcDv//OwYQBtYgNf5Fa3xRHF1Za9dzWUFkb/v5v RIgX3tqY+zB3YZeZsfl2yCZJZe2QIdnLDu8A7R1LCV7LaPrFHGIJzip0H7Ydzbj4fbb4 ha+TWDi1ubaadzRfKAdkg4AgzskiQtscDMn4vwhXaXn+K0uEKlqwJ4Zzyj0guEq1aFg/ rbjHWq4duiSw0+RI883izS2WqdFHq6N/SsQyPgTVa+zNQCeAnPSkzih1iCohItJCRo81 NBUA== X-Gm-Message-State: AOAM531v0UpCRbhUsDKIl0QHc5+IkQl0MSwvEbr7/drL84b0W/Vu0Eym RLoyw5+J9EnXqBK+vb73UjMKTvB8cL2J4VPg+eM= X-Google-Smtp-Source: ABdhPJzVarbKo8kONs7CX7xvcPMjtZ6r4bVeO5a5x38CKZ/VKq0XjI0rLRTqR+lB/gjgl0cOMCL6JM+2NXSPCEoxqaw= X-Received: by 2002:a17:906:f90a:: with SMTP id lc10mr14647997ejb.272.1603058492316; Sun, 18 Oct 2020 15:01:32 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Sun, 18 Oct 2020 15:01:31 -0700 From: Stefan Kangas In-Reply-To: <87imb7e242.fsf@gmx.net> References: <87imb7e242.fsf@gmx.net> MIME-Version: 1.0 Date: Sun, 18 Oct 2020 15:01:31 -0700 Message-ID: Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format To: Stephen Berman , 44068@debbugs.gnu.org Content-Type: text/plain; charset="UTF-8" X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 44068 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Stephen Berman writes: > On trying out the new tabulated-list implementation of the bookmarks > list I noticed that, when clicking on the File header, the sort > indicator is not displayed, unlike with the Bookmark header. Then I > noticed that the same thing happens in the tabulated buffer list (C-x > C-b). Then I grepped for all uses of tabulated-list-format in the Emacs > sources and found the same problem in most of them. The reason is that > in these modes the width of at least one of the columns is too narrow, > so that tabulated-list-init-header omits the indicator. In most cases > the problematic column is the final one, but in a couple of cases there > are also non-final too narrow columns. And I think these bugs are due > to a misleading description in tabulated-list-format's doc string. Your analysis sounds correct to me. > The attached patch corrects the doc string and the problematic uses of > tabulated-list-format. The patch also fixes a typo and tries to > improve column alignment in timer-list-mode: this is one of the few > modes derived from tabulated-list-mode whose column widths didn't need > to be corrected, but the alignment seemed suboptimal; however, when > the header line uses a variable-pitch face, the alignment is still > suboptimal even with the patch, and I don't know how to fix that. Thanks for the patch. I've tested it and it indeed fixes several bugs in this area. But it got me thinking: for the final column at least, maybe we should just make tabulated-list-mode work as advertised, and itself figure out that it should use this length? That way, we would solve any bugs also for external packages that have been misled by the doc string. Or would that have any downsides? From debbugs-submit-bounces@debbugs.gnu.org Sun Oct 18 18:01:56 2020 Received: (at 44068) by debbugs.gnu.org; 18 Oct 2020 22:01:56 +0000 Received: from localhost ([127.0.0.1]:39241 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUGkW-0006IW-54 for submit@debbugs.gnu.org; Sun, 18 Oct 2020 18:01:56 -0400 Received: from mail-ed1-f49.google.com ([209.85.208.49]:45716) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUGkV-0006IJ-6X for 44068@debbugs.gnu.org; Sun, 18 Oct 2020 18:01:55 -0400 Received: by mail-ed1-f49.google.com with SMTP id dg9so8229359edb.12 for <44068@debbugs.gnu.org>; Sun, 18 Oct 2020 15:01:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:in-reply-to:references:mime-version:date:message-id:subject:to; bh=Dy6/yStTfjjDoSUEZE4P4JLzMmSMNG8ZPB7Xl4x6kpM=; b=goVw59Qq6ZZZr1yygqASrtYUALIS+PsYkK6I9KVnVUr3uhaB/LGQmz3/gwZ4Z79NLV Jjl0Qx9lTqEV6EBthU30bG2dNC0HtKGe+/KmPqUyPJODeH1LxLBf29Q4Vt3zzrAxOyXP nQU/Pr2BuCMMJd8Nh6USJ3t+JpKseAN9ZYvDJD/OnUmW6Hoy+MUOPJaB1DziXQNtBcan ilGjM4Nzf1T4eRzllSphLTjVDGMoaEntwmmNQwChCxUbJTYWc6He/x4Se9CMod+v8ziN 4hwEyf8WT+lEA0bUUF8OFra/7QJd4tS/lEEx++V8kYNfPnJDs3iNmCQ9l4nJ43LgAhh4 TAjQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:in-reply-to:references:mime-version:date :message-id:subject:to; bh=Dy6/yStTfjjDoSUEZE4P4JLzMmSMNG8ZPB7Xl4x6kpM=; b=mA2R/RGfZNmVF2COV1Y7R+BWJ6z2Hovisc3b7X9MWACTvIQJXTZ4XFNbYBKQjIKCHA 6ioo1eIa5UHuahuHPot5xr7fhfypLVKVd8LWOHVdq8lvFxUNMPEEFX5ixzPuLU6aVYCf T1bh57T2HLpLfhjEF/01ciMcqW4yOnValSUNmgMvfRvra61I/W7ayVBSWQZY32iXePzo KSSuZT7U6NDOTCBo345WRK+oALV9WZb41rZ26uVn9jFlRkpSFsswzxdn/OrnDVXSlpjW 90EisPxfJzrOOaNja/EWYU60TbACsUDuhXlqdueWJncVTIxz9EyxlGsqlRe4Z3I41lPG E5tQ== X-Gm-Message-State: AOAM530fiTQlrAAhvaavuJtu2N9Gs5Vlp4sUH6s69kxeYyEX9VXpW8TK JbpdIdIhjVzpEWVnV42ICIv3o+mfOw4eEvYazJc= X-Google-Smtp-Source: ABdhPJyU+iNJpx+Bhu3PkrVJr7xK5dyFOIp9BJErGzD5e/IrcjwaGEeHauFLv98skatTJqIhg3FF7xqiJQmLoX0ISZ0= X-Received: by 2002:aa7:d783:: with SMTP id s3mr15389099edq.214.1603058509501; Sun, 18 Oct 2020 15:01:49 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Sun, 18 Oct 2020 15:01:47 -0700 From: Stefan Kangas In-Reply-To: <9d13f9c2-f8dc-4f61-be5f-d60d485719bc@default> References: <87imb7e242.fsf@gmx.net> <9d13f9c2-f8dc-4f61-be5f-d60d485719bc@default> MIME-Version: 1.0 Date: Sun, 18 Oct 2020 15:01:47 -0700 Message-ID: Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format To: Drew Adams , Stephen Berman , 44068@debbugs.gnu.org Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 44068 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Drew Adams writes: > This rings a bell (maybe). I think the sort-indicator > problem might be a duplicate bug report, but I can't > find the dup now. There are some inherent problems > with the rightmost column, IIRC, that being one of them. Maybe Bug#41861? From debbugs-submit-bounces@debbugs.gnu.org Sun Oct 18 18:15:40 2020 Received: (at 44068) by debbugs.gnu.org; 18 Oct 2020 22:15:40 +0000 Received: from localhost ([127.0.0.1]:39288 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUGxo-0007Ge-Ai for submit@debbugs.gnu.org; Sun, 18 Oct 2020 18:15:40 -0400 Received: from userp2120.oracle.com ([156.151.31.85]:56886) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUGxl-00079I-RW for 44068@debbugs.gnu.org; Sun, 18 Oct 2020 18:15:38 -0400 Received: from pps.filterd (userp2120.oracle.com [127.0.0.1]) by userp2120.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 09IMEG1Q055487; Sun, 18 Oct 2020 22:15:32 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=mime-version : message-id : date : from : sender : to : subject : references : in-reply-to : content-type : content-transfer-encoding; s=corp-2020-01-29; bh=qbLQpU0ygadDvP+ksUrM49/8p6Tr+nwqxfNdlp+CfQg=; b=JZbJdOhjdKxJdMeTLY6FFz3CHU9y6fRQv6//H8ioN4U/S+TR4rmq6DfY/8FzOAtAYhD+ ODGCWodKmW//CT65HIXm00kXg4Xyn+KLxFrqc4hQezLd7QAabKeHSfGOh0VpnD8NvcMd 3PsKqhsWMSGIVcS8dYIcplcgCFxT4ZVUwk5+YKJf9I/taoGKPuyMFZhfsiv8GNDbBzSD RHs3wjq5RtkOEm9Law7JOUyN7jjhpFAWJs12Dpp+dPNypMgup84nSQGEY0FpzF2+BE6r boxVI4oLbaZmnpjrTUM53foIW2Ty22gPXM6xKjAsvNTJ9c8OddbcdD77Dg6MbXTb/2Hx RA== Received: from userp3030.oracle.com (userp3030.oracle.com [156.151.31.80]) by userp2120.oracle.com with ESMTP id 347s8mjve5-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Sun, 18 Oct 2020 22:15:32 +0000 Received: from pps.filterd (userp3030.oracle.com [127.0.0.1]) by userp3030.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 09IMEoHE060616; Sun, 18 Oct 2020 22:15:31 GMT Received: from aserv0121.oracle.com (aserv0121.oracle.com [141.146.126.235]) by userp3030.oracle.com with ESMTP id 348ahua8t4-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sun, 18 Oct 2020 22:15:31 +0000 Received: from abhmp0013.oracle.com (abhmp0013.oracle.com [141.146.116.19]) by aserv0121.oracle.com (8.14.4/8.13.8) with ESMTP id 09IMFUlv030252; Sun, 18 Oct 2020 22:15:30 GMT MIME-Version: 1.0 Message-ID: <1d9d4d8e-b9f5-469e-810a-918850f16b60@default> Date: Sun, 18 Oct 2020 15:15:28 -0700 (PDT) From: Drew Adams To: Stefan Kangas , Stephen Berman , 44068@debbugs.gnu.org Subject: RE: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <9d13f9c2-f8dc-4f61-be5f-d60d485719bc@default> In-Reply-To: X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.5056.0 (x86)] Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9778 signatures=668682 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 adultscore=0 phishscore=0 bulkscore=0 malwarescore=0 spamscore=0 mlxlogscore=999 mlxscore=0 suspectscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2010180175 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9778 signatures=668682 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxscore=0 suspectscore=0 lowpriorityscore=0 mlxlogscore=999 priorityscore=1501 spamscore=0 phishscore=0 clxscore=1015 bulkscore=0 impostorscore=0 adultscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2010180175 X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 44068 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > > This rings a bell (maybe). I think the sort-indicator > > problem might be a duplicate bug report, but I can't > > find the dup now. There are some inherent problems > > with the rightmost column, IIRC, that being one of them. >=20 > Maybe Bug#41861? Yeah, probably. Thx. From debbugs-submit-bounces@debbugs.gnu.org Sun Oct 18 18:17:25 2020 Received: (at 44068) by debbugs.gnu.org; 18 Oct 2020 22:17:25 +0000 Received: from localhost ([127.0.0.1]:39292 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUGzU-0000FC-Oe for submit@debbugs.gnu.org; Sun, 18 Oct 2020 18:17:25 -0400 Received: from mout.gmx.net ([212.227.15.19]:47277) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUGzT-0000A2-L1 for 44068@debbugs.gnu.org; Sun, 18 Oct 2020 18:17:24 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1603059437; bh=1mY68cnEhRgPTWrAqT2wP9OZ2iTfa6tTlJUw2isOt08=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=Vfb3p9Yht7+zGZ8SWlTFCUangqknm+IdVJqAAIehjOdSnR5v/OYp2p9NIREuS4v6y pKniA3FBTIj7VtkY+Rm41EdgcVy5E6Ps4tr1T3+BS0BM5ToGxJ9e8Nn3iCKiJZeXAv x+ONtKfqZTFOihR84LAG91ZwPRu7HKor+9rIm1wU= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([178.6.223.210]) by mail.gmx.com (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MwwZd-1kFbQE0Bi7-00yPgP; Mon, 19 Oct 2020 00:17:17 +0200 From: Stephen Berman To: Stefan Kangas Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> Date: Mon, 19 Oct 2020 00:17:12 +0200 In-Reply-To: (Stefan Kangas's message of "Sun, 18 Oct 2020 15:01:31 -0700") Message-ID: <87blgzdvrr.fsf@gmx.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:HEaZM46js9DC8puDVtIKaZiczkGmUBzOFC6vRhaAShZoetVHft7 h/DsPJH/0Ya4wovAvc/EHHxfouG0oI6jpq6iNyLy0NTiQCC/O26f34IKzIfcDeN4o2BoXip TFD/QAKC8vhYqv6U29Zc+mp0gULnR7ri/mXmHHRSrYkx785MPpkc6ojbNUrS9ZvaKk7O+cS 5CsTXdr3+MBFOYEHYERew== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:ahyb7QvJ1l0=:vj8V4lkyidYuwtPAdpe+tX syGjdXxt4An85sjbUs1OiwkcPesm9VjdHCBCfUb7nRlPy3JQGSOTk/OaqNTI+J2HGaryrUgua 4LBQZbdU/7G/RU9rHNr4Kx7GYabJYn28wooROHkXwoEeqfoVrO9lfATphNwp57TU3oJqrv166 Ecb3SiZHpcUf2cAKMOlco9573jYbUJ8/Glr/9/F/N5mlmpN8Oq4iZbkaT75j1BlNt9SC9Y2Ud G2aOtiMHJltjGdnuYsDNIOZiiBnGbc/vBSBSLO6IeaFmfo7KnIDbSPBlzBsJ3n25P3NdgleaS S5zSlzOWSiLQGzWioXgEiyMGn0cpxBmKQrjok6Ito7NxBnF24q2n64iHi8FmrGgpvzXm2eqPa V0GV9hqTjxWCK8FUrTqBFJTXshDqGgmhe+naPqNsCffcK9XNi97JEVByt4+m/dUPOLC6vR1Ar Ac9YOQ42uBdeXfWo6fzb0pGGAW3KIJDhwvVkhWJXYXs8nfWisBAqLWWOVeaiIM64fJWv9fJwQ XocMXCo6fLfV0mkz9fzth5m3RXD7icv99JBIG3vqF1Zvry/S2eKqiArz0CnZoQg3OtvsAcOg5 0H3u2tNzqXB9byZL6NDUj1r3p9mHtgGFVI+hqfajge3I+01NhdEuyKBxUBTOq1H2lLYZDIfcs 8FbZ2tob/LKuJrYlke02msgnzQ2LC2R4Xsi9Vyun0GcHeQoKIsbgkusQEkDMK46U8HNLgU3sj WYE27Tnr4aXSgKf/yJjL5L8SAh6f8NDpZISwcLWho7dZludJVyjxq9cJE7v/AgmjgIYdA/PsD tTEfK2Bj5xtA23f89WLWnaHtrauFbZxX9rjRTNMcXsa4xVZzLD2HYqUaeXTzV1asY69QYXLIO 7WarW+E6X4skNFxXIUAQ== X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44068 Cc: 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Sun, 18 Oct 2020 15:01:31 -0700 Stefan Kangas wrote: > Stephen Berman writes: > >> On trying out the new tabulated-list implementation of the bookmarks >> list I noticed that, when clicking on the File header, the sort >> indicator is not displayed, unlike with the Bookmark header. Then I >> noticed that the same thing happens in the tabulated buffer list (C-x >> C-b). Then I grepped for all uses of tabulated-list-format in the Emacs >> sources and found the same problem in most of them. The reason is that >> in these modes the width of at least one of the columns is too narrow, >> so that tabulated-list-init-header omits the indicator. In most cases >> the problematic column is the final one, but in a couple of cases there >> are also non-final too narrow columns. And I think these bugs are due >> to a misleading description in tabulated-list-format's doc string. > > Your analysis sounds correct to me. > >> The attached patch corrects the doc string and the problematic uses of >> tabulated-list-format. The patch also fixes a typo and tries to >> improve column alignment in timer-list-mode: this is one of the few >> modes derived from tabulated-list-mode whose column widths didn't need >> to be corrected, but the alignment seemed suboptimal; however, when >> the header line uses a variable-pitch face, the alignment is still >> suboptimal even with the patch, and I don't know how to fix that. > > Thanks for the patch. I've tested it and it indeed fixes several bugs > in this area. > > But it got me thinking: for the final column at least, maybe we should > just make tabulated-list-mode work as advertised, and itself figure out > that it should use this length? That way, we would solve any bugs also > for external packages that have been misled by the doc string. Or would > that have any downsides? That was my first thought when I noticed the problem, and came up with this patch to fix it: diff --git a/lisp/emacs-lisp/tabulated-list.el b/lisp/emacs-lisp/tabulated-list.el index b13f609f88..d6bec72ade 100644 --- a/lisp/emacs-lisp/tabulated-list.el +++ b/lisp/emacs-lisp/tabulated-list.el @@ -271,11 +271,12 @@ tabulated-list-init-header (button-props `(help-echo "Click to sort by column" mouse-face header-line-highlight keymap ,tabulated-list-sort-button-map)) + (len (length tabulated-list-format)) (cols nil)) (if display-line-numbers (setq x (+ x (tabulated-list-line-number-width)))) (push (propertize " " 'display `(space :align-to ,x)) cols) - (dotimes (n (length tabulated-list-format)) + (dotimes (n len) (let* ((col (aref tabulated-list-format n)) (label (nth 0 col)) (width (nth 1 col)) @@ -293,7 +294,11 @@ tabulated-list-init-header (apply 'propertize (concat label (cond - ((> (+ 2 (length label)) width) "") + ((and (> (+ 2 (length label)) width) + (not (= (tabulated-list--column-number + (car tabulated-list-sort-key)) + (1- len)))) + "") ((cdr tabulated-list-sort-key) (format " %c" tabulated-list-gui-sort-indicator-desc)) But after I saw that final (rightmost) column in the problematic cases was simply given too narrow a width, I thought it better to just change that and clarify the doc. But maybe you're right that the misleading doc has affected third-party packages. Steve Berman From debbugs-submit-bounces@debbugs.gnu.org Sun Oct 18 18:18:39 2020 Received: (at 44068) by debbugs.gnu.org; 18 Oct 2020 22:18:39 +0000 Received: from localhost ([127.0.0.1]:39296 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUH0h-0000Px-6E for submit@debbugs.gnu.org; Sun, 18 Oct 2020 18:18:39 -0400 Received: from mout.gmx.net ([212.227.15.18]:51031) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUH0f-0000Pj-RW for 44068@debbugs.gnu.org; Sun, 18 Oct 2020 18:18:38 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1603059508; bh=z4YHIRpQnKi9KlwjeVVj2QOAWVOoKKUlsfd7GWNebbo=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=aJnlS1V2qTykHGhirI/G+GY15pX5Po/+sAFGJqEw+xDqzlLGi4lD0Uv/r58wnW34g bnk6Yvj6GJXTSkfCb2/H3/E8/r2NNYubWuYhUBqyLhxQZjl//rB4hi+v9GB8jxNYPE rJP6bgrrTdgudlwTmFYYOBolVQ6Aco/g5YOAl7IE= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([178.6.223.210]) by mail.gmx.com (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1N2DxE-1kIbfe1YEA-013iIR; Mon, 19 Oct 2020 00:18:28 +0200 From: Stephen Berman To: Stefan Kangas Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <9d13f9c2-f8dc-4f61-be5f-d60d485719bc@default> Date: Mon, 19 Oct 2020 00:18:23 +0200 In-Reply-To: (Stefan Kangas's message of "Sun, 18 Oct 2020 15:01:47 -0700") Message-ID: <877drndvps.fsf@gmx.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:ljwGgwQUnEsA3PymKeqvZ3T41NAbjZTpUNhzNkReNmDO02tW6pZ r2xca0gsA3k8BK2n7IdQsVkK2ViDFiNtrTHlyYoBi2ODhwi6eldss9eUjMZXPfzc6ip9EwB Sv2LFGnE/lH1CAgGiVE2irznWcA4kWOPKESU7oQUaj5THsu2xGsnRjnT8oyTYUf9cZeVcrv fOEprvuRhNtu6QYAXMECg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:hMmSCh3Ln58=:Np02L49q2Lm6mh/FEVFqtK 3kkEQg4L7I6hsxCKvvaN7uMOiAh9xHFemuusOysCC8H7s43Y2/8EGPPHyk+ILIOXb12oSiRbe VxeSYPTAojVAcA3y+JNTbiUGLGp/goGJqbW7KN6Ra7DuacXSipaWm6ljUJHXjTD5D653evRi3 On7WeNgPHog6YFvpPL76vIFZ5KGTwdsDn0BGtU/a0YkmPUIAf/XXDhQxMHprAbAUS7oCRryuD b6SC4nF9cnaDQoi+e/wCrftBJ2w+awjoHbZ4KwcjQdPn/wGNNkuq66AH7nV5Cp0yU6IOPlpOA UXZ1Ya+n/cRHF8vrDWwakR8XQBqKxlqFJRGJfzxprObjfwPSXAHhQ1t3qlLDLsQIIzCrWxcjY WcTSY3TYtIb5YhwWN6njXwfNEN1aMzOPZWXKcPGpUqGk2NHr5uEqYHoTc0HBQkaze7eb8N2bH HqYRI7l3Ztp1RxYAO4lW+VkrofxAqi5kzps/1iHktl6TUQ4NmKaNvBo5f4xIsWPiWP8rXtaZs eYrje9J7DpFy7gJy8nwFUMbstMJkRurQjyQEsbqEPOOcsUa4DYyjW5sm4MW65PwEQ5LQ1NrgH dKvEnzpWom2qYAO0/lzcE5Sr48nd9l7izIpx+oZWvE5ltxyKR/9EmoxmRcNhVWcsXXaKEEM2o BJh34KELf/48T6TYpgKcu9SAEjf9thj+m85dqD783BycTmSVPgAN5b27eSgWDK5mcGWHU93/c z2Ess7icbx+C4Rvup3dJV6jqpm4npaXpaZpfVn0MSfUelyOEDSYeLFTzn3MF8MzJ2tfRW8F9D +gvdALlBT7rlnlk8fpZxwDhZymZ1DL/6LuidYoUYp+9HZ+jU9ItpKZZkbNHYG+ncz4RHto4RV DDeweF05Ivsc+U2Mguzg== X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44068 Cc: 44068@debbugs.gnu.org, Drew Adams X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Sun, 18 Oct 2020 15:01:47 -0700 Stefan Kangas wrote: > Drew Adams writes: > >> This rings a bell (maybe). I think the sort-indicator >> problem might be a duplicate bug report, but I can't >> find the dup now. There are some inherent problems >> with the rightmost column, IIRC, that being one of them. > > Maybe Bug#41861? Ah, thanks, I didn't see that. Steve Berman From debbugs-submit-bounces@debbugs.gnu.org Sun Oct 18 18:35:52 2020 Received: (at 44068) by debbugs.gnu.org; 18 Oct 2020 22:35:52 +0000 Received: from localhost ([127.0.0.1]:39311 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUHHL-0000qG-S0 for submit@debbugs.gnu.org; Sun, 18 Oct 2020 18:35:52 -0400 Received: from mout.gmx.net ([212.227.15.19]:33301) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUHHK-0000q1-23 for 44068@debbugs.gnu.org; Sun, 18 Oct 2020 18:35:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1603060543; bh=Ctaji6R9afdQU8D31BAWB2QY6p5Vupv8AwP7bHPZw/4=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=GhRAXbnAiXZpWYWjGAZkr7UWi/qr9Eb249sD6MgCDSRDjOP5pgFPg8xdorDFEEHmq glm/NNu06yPhy0Tb+wSVH9oFg69Oc+mtGhOjv0eWehhPTd49E5WnXOWrSAsi3TujNB 591WBPTREZHPKUzEyMekz0HOJLxW0xsEPbf4HaNQ= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([178.6.223.210]) by mail.gmx.com (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MqJqD-1k910G1b8t-00nOsB; Mon, 19 Oct 2020 00:35:43 +0200 From: Stephen Berman To: Stefan Kangas Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <87blgzdvrr.fsf@gmx.net> Date: Mon, 19 Oct 2020 00:35:38 +0200 In-Reply-To: <87blgzdvrr.fsf@gmx.net> (Stephen Berman's message of "Mon, 19 Oct 2020 00:17:12 +0200") Message-ID: <87362bdux1.fsf@gmx.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:1nzyN8DmONa3Z2C+lZSr8LYgpsyz9hPRs2hw3e5gF5Y28nlLb65 u4yKAjKJIADsH4gJgTVbPz89UaJT2XeX2GQaA1mfUPEFz257cP77r1+VhattqSz39WXPgrh R578w+VPR2Op3UjMUSfFWZPZp3pu3CLw/MroDEQMVQZxv8T4cPYzjlQiqW3Hsa00VCyqgJN 9aCxWbHdjylH0wxmIGazw== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:dLTMli+hmAw=:+rYTjJ7cwV5iQcIniw/j5v Ina/ZGkWq3IpIFUb67E4ggwLh6PFd8Kc3nY6UYTQ4OskABlKTif7RZJvO1Kt30cIgHzWiSa7Q 3AutdGy+Tp6Zz5hrhuQxo9bGwB0C1xLNDnfUPdLIcZkDjbC2cLfC5eEstX8V97y9Mcg3TdmdU PbiNPNeedneVkCjOMeTIqofChIH5IFw30FA6oqxjTD2VLfXP4GVoHrY+6dekshON0U+0E2lwb HuTua66ltVXr2Pxj6mwcYS0f157U9XwBJyERER0JBfPsuBTDVfxSPhACFvM+HPLm3U99JgMzl yEOuQBmFtdC1mkH/bGYdzIXyHXF+C1HyfiVGghsIAyl3VsJALF4FdpwWtCo4N5RTY6wpZNCOP pcaEfDVqIJIJ0t9blh9bBIwXIJkua4j/Y96i02qG5hfrQYhrLtYXGA6drCYG0sqb70Fnu4Tr8 n57+NcPIAz2AtrWlupAA6rR0Ae2jH2jHOLhSpdneY7PAiSGqvJ17DMIafOVOMHVEI2h+ZVju6 90KxgS56PzXhunbddZ6/LYqlnnVIm4SCs51Q00cS2vrawQDyLnLOnn5I8/Sb8yC+Ws0tjNfTF mmfoCCdeYwXPo0CtwIKOkNB2/fuBzm1KWUKsFraeu0yt7swH8ZKV9T87H7lXFWMA+AMOOnuLV eElhTMRPgNcOQ9S4EMad3k0yM5ubBUePv0RYqQYQMnyUyzkJYaXbHJ9YhLVoqFjAYyn2Tet7l zPj3x4fl4vSIbYteXThMCckxhFloI7jh0UKnkbcgsbkCVsStpjg8D7OMdPu0d8WoMg1dryhQl xwKk+Z/X1vLKdWXROwXCnjPCp7pS3AtbKlf6nRTT4XEPdSYO/XwTd/welnRMlfJrw0usLB50d 8eu2WDIUBMGCluyD3/Aw== X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44068 Cc: 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Mon, 19 Oct 2020 00:17:12 +0200 Stephen Berman wrote: > On Sun, 18 Oct 2020 15:01:31 -0700 Stefan Kangas wrote: [...] >> Thanks for the patch. I've tested it and it indeed fixes several bugs >> in this area. >> >> But it got me thinking: for the final column at least, maybe we should >> just make tabulated-list-mode work as advertised, and itself figure out >> that it should use this length? That way, we would solve any bugs also >> for external packages that have been misled by the doc string. Or would >> that have any downsides? > > That was my first thought when I noticed the problem, and came up with > this patch to fix it: > > diff --git a/lisp/emacs-lisp/tabulated-list.el b/lisp/emacs-lisp/tabulated-list.el > index b13f609f88..d6bec72ade 100644 > --- a/lisp/emacs-lisp/tabulated-list.el > +++ b/lisp/emacs-lisp/tabulated-list.el > @@ -271,11 +271,12 @@ tabulated-list-init-header > (button-props `(help-echo "Click to sort by column" > mouse-face header-line-highlight > keymap ,tabulated-list-sort-button-map)) > + (len (length tabulated-list-format)) > (cols nil)) > (if display-line-numbers > (setq x (+ x (tabulated-list-line-number-width)))) > (push (propertize " " 'display `(space :align-to ,x)) cols) > - (dotimes (n (length tabulated-list-format)) > + (dotimes (n len) > (let* ((col (aref tabulated-list-format n)) > (label (nth 0 col)) > (width (nth 1 col)) > @@ -293,7 +294,11 @@ tabulated-list-init-header > (apply 'propertize > (concat label > (cond > - ((> (+ 2 (length label)) width) "") > + ((and (> (+ 2 (length label)) width) > + (not (= (tabulated-list--column-number > + (car tabulated-list-sort-key)) > + (1- len)))) > + "") > ((cdr tabulated-list-sort-key) > (format " %c" > tabulated-list-gui-sort-indicator-desc)) > > But after I saw that final (rightmost) column in the problematic cases > was simply given too narrow a width, I thought it better to just change > that and clarify the doc. But maybe you're right that the misleading > doc has affected third-party packages. I note, though, that this patch, won't fix too narrow non-final columns, as the Archive column in package-menu-mode, or the Status column in process-menu-mode, etc. Steve Berman From debbugs-submit-bounces@debbugs.gnu.org Sun Oct 18 19:14:03 2020 Received: (at 44068) by debbugs.gnu.org; 18 Oct 2020 23:14:03 +0000 Received: from localhost ([127.0.0.1]:39355 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUHsJ-0001mE-7i for submit@debbugs.gnu.org; Sun, 18 Oct 2020 19:14:03 -0400 Received: from mail-ej1-f52.google.com ([209.85.218.52]:44042) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUHsH-0001lS-Jr for 44068@debbugs.gnu.org; Sun, 18 Oct 2020 19:14:01 -0400 Received: by mail-ej1-f52.google.com with SMTP id a3so11296447ejy.11 for <44068@debbugs.gnu.org>; Sun, 18 Oct 2020 16:14:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:in-reply-to:references:mime-version:date:message-id:subject:to :cc; bh=c5/Lo83sRP8Xj8ommGJeRa9oI7Dy5XM7IWGx4wew31w=; b=ln1qWwahB83MXMwg6jxXe8xUKrxUvl8kTYcN1Acfb5cRjWLVyRhnink3VNQ9429WaA 1wVjERsVCbS8uJCoPwQKcY39aHZCqvPvfjJh/FnAJHvO1Kd1AJo3uRNv5dbAew4Re6dX Llsl+J/nwRKr/dwP+N7WAR+x1vo+uQXt+Mte/a1y9AqSXIwVhOazTUnGL8a1uFXoFy/g J8kpghUdHqC0qmUx3BvMadHrPZRj7/aa4v2gD2cWH3yxHpn8V/swog/GezB5WI4G73ip EpaIojuNblGKUen+desQRFPffwQ8MmGISWFa+dtXJZv4ev1TP0+7mXjaw7Wsx9k5P1AV YBnw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:in-reply-to:references:mime-version:date :message-id:subject:to:cc; bh=c5/Lo83sRP8Xj8ommGJeRa9oI7Dy5XM7IWGx4wew31w=; b=GLo6xmQ2kvnxbkrJBmwkbCUEmw7yhIqwLO/jEsIvzrjKd18/IG95rPKpahm4A6EZ0z vDsQiO7jIh10cnajTur1TmNFnQW5+LlwYr0lHu4r7pXcaa0CxiJ+fAaHxhY64ns2cbgM Gh7j+68nu3Pkfv6C6jwwEyCY6IHzxSj4K5bDbEbC1RjzhHzN+KE6TZ2HtYd2oIcywtd4 j/OlOiY/4cdVQ0OXaTBOQdk6d4W3Jgqg6ElLnkWzsuu4pb0KZIbdYUUYws+WgBr5wmR0 /AlvVARZB90DsbAxZwCUjei20t/QVeYJiXRx0HUYEijc6a9ACivTo22Ynx9/ocOoBOkr t+qw== X-Gm-Message-State: AOAM532N/RCaIykN67FM9t/vsR6EhSXX4RD90ZvdFSd4IeJyHO0XwjmD qZTVWU7efZRyBoH71+YqK1np6MFpcI96ro4Oxxg= X-Google-Smtp-Source: ABdhPJwXKYftxShKinGdYcQ2WzOyxbznyQHLtJLxOE4/jSeYhLu9z8TF8DU/g2Xc3qqnN7v/QSHqEOgKMakIkCQniHA= X-Received: by 2002:a17:906:3ed0:: with SMTP id d16mr15059699ejj.477.1603062835837; Sun, 18 Oct 2020 16:13:55 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Sun, 18 Oct 2020 16:13:54 -0700 From: Stefan Kangas In-Reply-To: <87362bdux1.fsf@gmx.net> References: <87imb7e242.fsf@gmx.net> <87blgzdvrr.fsf@gmx.net> <87362bdux1.fsf@gmx.net> MIME-Version: 1.0 Date: Sun, 18 Oct 2020 16:13:54 -0700 Message-ID: Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format To: Stephen Berman Content-Type: text/plain; charset="UTF-8" X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 44068 Cc: 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Stephen Berman writes: > I note, though, that this patch, won't fix too narrow non-final columns, > as the Archive column in package-menu-mode, or the Status column in > process-menu-mode, etc. Would it perhaps make sense to apply both these patches? From debbugs-submit-bounces@debbugs.gnu.org Mon Oct 19 05:04:17 2020 Received: (at 44068) by debbugs.gnu.org; 19 Oct 2020 09:04:17 +0000 Received: from localhost ([127.0.0.1]:40028 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUR5U-0000EY-VY for submit@debbugs.gnu.org; Mon, 19 Oct 2020 05:04:17 -0400 Received: from mout.gmx.net ([212.227.15.15]:54275) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUR5T-0000EK-Gd for 44068@debbugs.gnu.org; Mon, 19 Oct 2020 05:04:16 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1603098249; bh=iDFBjLp+HtddLsr3I1hjBaKNR+JErwYZY8r0weUQmLI=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=kD7kx4LGSG+Nm74H3IcY+vJVxcjsiZ0UfE6bEWwePYqnyyicKl8yhDPM2QOAMACw9 36R0jnpYFvgarXK5wBBdO1HcCOTEv+e/5Wu/55mcHAda0xGMw3IETmCZT5xvY5NpTx zdGZwDV0Ag1qpyv2WwLssFJNcZkJcEl6ZXdnXkgo= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([188.101.169.69]) by mail.gmx.com (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1Mlf4S-1k4kzC3pj8-00ilNh; Mon, 19 Oct 2020 11:04:09 +0200 From: Stephen Berman To: Stefan Kangas Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <87blgzdvrr.fsf@gmx.net> <87362bdux1.fsf@gmx.net> Date: Mon, 19 Oct 2020 11:04:02 +0200 In-Reply-To: (Stefan Kangas's message of "Sun, 18 Oct 2020 16:13:54 -0700") Message-ID: <87mu0i1ta5.fsf@gmx.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:swCSuwJOlYXjhRiIFLsU4r+lxiCM33okkNN25tXZM4tDbAtkEMl Ldoj38LJTmii8SCfeqZmxcs3AraPPb6wAd6Ok3ZYCdV1q8Xl0oN+NPr9vACJFTUU2wEqO2g 8w/KTv0TKw1RSxoS2Ql1GzsY/v1kOt+BYPO3FkxMwYeNYp88KGtVpXKPElFpEg36u1kWEjy Am0VxoDhEx6da1VuabHRQ== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:NR5hzDFAlus=:KIW0wSwD7+mu1GuHCR6FuR ILlASHRrVqjwLrZrtjGRQo4e9UBB0A1PgvHP6zMOUH8LqZ0vpHTdrFmOU1TkRXVcBbuAav5J5 AS4sRYvZ3qvBDaBMVOf11qmdc5VJMmBG/k/9RKea8BpfMxIlzjsei3qGhFzt3KBZgbYeOzegD /0dpEO9amAz0U+gJnwW+YpS7NXI4Hfi9oLDI3dndYtu4eCTsKT61CqWpmcgJRKmen6KjqNOAG i8I8SuDd/eygCX0yvgeejrJMLO++LuPzzn96WimLqOyxVFDHMuyKqHyypmjwJcgMI5H+dHrjy StMy8RiEaBu+OdgeRAJHbVQMYuoZa9eg618SSJVwB1BocdXWE8f2ysZF8wvYL0F/Q91VhsTok dRBJ5thiatPhsZwB02OZAIzAC1YN3SJkrfhsa81IkiKCRLaFLTq0EnOe/la6vBTVW2EcWSTsu VRh2oyc5/gASDBHkxreqRxnhZX1tKGmU/9o2wCQEJhdv79XO9l6jobDaP1YcKuw/0rS/Wi2Xb 65MxLqJ3BhAbaFffS1wgeAJfwgOw1+YmiZvxUxoDZZ6or4cLLtAOkfCbpJtLJKRNMmvEO5TNX Z0sg+BF2GTM4TJJO4pEW1fEzZj13URKAzC4gXP4doSIn5dj3JnQV8zUCSOHTZkv2LQrGPNJQu 5aHv+0JgmUFVEDF5DiUYWf6PO8YohLUnLony/aJMQKBz1ToIowFchOYLYMt8GlhoUFmYJFUWR ZMN8ErFn/ge+6tODGyugotSD2wXkD9R+PGm3nvNwAIEvILSPVBHYbyNJPaTR2UKJ3HQvngJIS 0ho+a5JfZIq87zTvS8IVMY74I/28hTiyF+pEDsG3+OwW4J1ECvGrxtd6HEGaw9B8Cbc8yR4As PGjpkkfTl2buWT0cDsEQ== X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44068 Cc: 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Sun, 18 Oct 2020 16:13:54 -0700 Stefan Kangas wrote: > Stephen Berman writes: > >> I note, though, that this patch, won't fix too narrow non-final columns, >> as the Archive column in package-menu-mode, or the Status column in >> process-menu-mode, etc. > > Would it perhaps make sense to apply both these patches? Since third-party packages may need to fix non-final column width in any case (unless someone comes up with a patch that does it automatically), the added complication of the patch for the final column seems less compelling to me. Steve Berman From debbugs-submit-bounces@debbugs.gnu.org Mon Oct 19 09:52:13 2020 Received: (at 44068) by debbugs.gnu.org; 19 Oct 2020 13:52:13 +0000 Received: from localhost ([127.0.0.1]:40314 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUVa9-0006A4-Fh for submit@debbugs.gnu.org; Mon, 19 Oct 2020 09:52:13 -0400 Received: from eggs.gnu.org ([209.51.188.92]:42104) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUVa7-00069p-0i for 44068@debbugs.gnu.org; Mon, 19 Oct 2020 09:52:12 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:34265) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kUVa1-0008Tl-JA; Mon, 19 Oct 2020 09:52:05 -0400 Received: from [176.228.60.248] (port=2144 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kUVa0-0008GJ-Kq; Mon, 19 Oct 2020 09:52:05 -0400 Date: Mon, 19 Oct 2020 16:52:09 +0300 Message-Id: <83zh4ipbli.fsf@gnu.org> From: Eli Zaretskii To: Stephen Berman In-Reply-To: <87imb7e242.fsf@gmx.net> (message from Stephen Berman on Sun, 18 Oct 2020 22:00:13 +0200) Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 44068 Cc: 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Stephen Berman > Date: Sun, 18 Oct 2020 22:00:13 +0200 > > On trying out the new tabulated-list implementation of the bookmarks > list I noticed that, when clicking on the File header, the sort > indicator is not displayed, unlike with the Bookmark header. Then I > noticed that the same thing happens in the tabulated buffer list (C-x > C-b). Then I grepped for all uses of tabulated-list-format in the Emacs > sources and found the same problem in most of them. The reason is that > in these modes the width of at least one of the columns is too narrow, > so that tabulated-list-init-header omits the indicator. In most cases > the problematic column is the final one, but in a couple of cases there > are also non-final too narrow columns. And I think these bugs are due > to a misleading description in tabulated-list-format's doc string. The > attached patch corrects the doc string and the problematic uses of > tabulated-list-format. The patch also fixes a typo and tries to improve > column alignment in timer-list-mode: this is one of the few modes > derived from tabulated-list-mode whose column widths didn't need to be > corrected, but the alignment seemed suboptimal; however, when the header > line uses a variable-pitch face, the alignment is still suboptimal even > with the patch, and I don't know how to fix that. Instead of manually fine-tuning each column's width, wouldn't it be better to use the string-trim capabilities that replace excess characters with an ellipsis? Thanks. From debbugs-submit-bounces@debbugs.gnu.org Mon Oct 19 14:20:31 2020 Received: (at 44068) by debbugs.gnu.org; 19 Oct 2020 18:20:31 +0000 Received: from localhost ([127.0.0.1]:42313 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUZln-0004wz-7k for submit@debbugs.gnu.org; Mon, 19 Oct 2020 14:20:31 -0400 Received: from mout.gmx.net ([212.227.17.22]:43221) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUZlm-0004wm-5H for 44068@debbugs.gnu.org; Mon, 19 Oct 2020 14:20:30 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1603131623; bh=snjJfF6JBdn2EpTbgoxYGNWQ6XWGFpv2RATNFa0SGq4=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=V6F9X+HSDDs+YuBZq/66ctptsOax3rZRJDLqNHJmmaVLfGF1n2bJ5Y33Z2c+a04kN Gfr0F+dsKKCednGRg7ZjCALvwMPla8URQA2qL4vyR2KL4NXy+9LlNJY5b+8xTxueYb TBAD79yOmDcanXNTXzczs2lAFzLJuhMr59u91Jxw= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([188.101.169.69]) by mail.gmx.com (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MCKFu-1kdxga44LS-009PwY; Mon, 19 Oct 2020 20:20:23 +0200 From: Stephen Berman To: Eli Zaretskii Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> Date: Mon, 19 Oct 2020 20:20:16 +0200 In-Reply-To: <83zh4ipbli.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 19 Oct 2020 16:52:09 +0300") Message-ID: <877drm13j3.fsf@gmx.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:Yf8C7QtEviCJIIGAfCXmlB7lrfxiS8IAZQtbQrHJd/+LOBThQHJ voaxtWvS7cQGeCDFqcdJsB+n0dc7fITaL5fUi+DxrSI4P2fpuZZP4rKYd6B68OGtrJWW+oz iqKhUlCoJINnpahboLsIDoSdZNY5X1z2zMJ6XFBo7TAzU3rEP5BuliAQGK801XrUPtdXzIK lZggMn9UQ8Fi9b2m84zhw== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:vXAS+GnMljI=:RT9vR5OtGGpa1pdSuX0Vb2 9DI1TVHUifmFhI5pnxYwDlgv/HW/R1Wa9KxnBi2l6lE5Yfb40qc+kacljFO0cVZ0yJl5kbZYa NGogdC5ISa3Q5O69/ghThq/jEfzEFni2ZwyIZ3E3tn1YzUoqCLbBp1bongCM5sIOiu19W0DYp EJE2wtLuAH8N2BKj8aaeRiPi8sPHhimjur92WntHa/Op3DLNtzphbGHsBC0hbFBEs6LB8kxVQ yOPKFTcUrXQWn2gOy/MOt3oRwLaAye+ng+E6bSPNL7kCaqoFOLw+ywh7+zYnrZR/45HAxqvvJ SuevYGKKdRuT99RvIjJa60SiO3vcCSgG8fEFwRf2b3yGZMUXv5jpwuya7rERDk7Ik+uYOOGCm IF1u819dDMMIjwx+9O2DPuuKsVWvQVd7PLPyNovLu2HO5v6cLmzTOHCWE/Be4pWEadskaXD4H AGNSmL0w1Q/QudXTMicIEimdJjvCa/ZkOWjhJccrPCY/Itx5fDqiNpJKdk3q2CUEuVtBZJR0x SOWPlP5+ebzea6ATj6bSmOUkNlxFlCFne7ylnQ449/RdmtJwS1Dr3LYmkuMIMk0/QqrgWZyHY tnO8ZJx58D/pKBVa7vMdFD2dtO/a7Nqw+0dVSw2JWm4/xgX6fPT6/7lVkbKi/HYB0wzMbim98 aJtC189dlM6mpybq7bi6i4eBWHWQT0SlUaYb3EbggkniXda64HBFwwc59NebfgEWbDdJQl/8F 5JCpyfoie2kyHYCSTezvc25PH9RQJium4M/3i8G9QcAHbPEu6Dg8nVDP4AZqs6rwZyekvjrP7 PM71+kvFN2p89JTQr8+lskTIPN1JbOmeSsfJ9wvJ3FDZPe6ZOSlWef+b2hcs167gMZJ8r7ZPq IkbRpUoE/GickMH916XQ== X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44068 Cc: 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Mon, 19 Oct 2020 16:52:09 +0300 Eli Zaretskii wrote: >> From: Stephen Berman >> Date: Sun, 18 Oct 2020 22:00:13 +0200 >>=20 >> On trying out the new tabulated-list implementation of the bookmarks >> list I noticed that, when clicking on the File header, the sort >> indicator is not displayed, unlike with the Bookmark header. Then I >> noticed that the same thing happens in the tabulated buffer list (C-x >> C-b). Then I grepped for all uses of tabulated-list-format in the Emacs >> sources and found the same problem in most of them. The reason is that >> in these modes the width of at least one of the columns is too narrow, >> so that tabulated-list-init-header omits the indicator. In most cases >> the problematic column is the final one, but in a couple of cases there >> are also non-final too narrow columns. And I think these bugs are due >> to a misleading description in tabulated-list-format's doc string. The >> attached patch corrects the doc string and the problematic uses of >> tabulated-list-format. The patch also fixes a typo and tries to improve >> column alignment in timer-list-mode: this is one of the few modes >> derived from tabulated-list-mode whose column widths didn't need to be >> corrected, but the alignment seemed suboptimal; however, when the header >> line uses a variable-pitch face, the alignment is still suboptimal even >> with the patch, and I don't know how to fix that. > > Instead of manually fine-tuning each column's width, wouldn't it be > better to use the string-trim capabilities that replace excess > characters with an ellipsis? I'm not sure I understand your suggestion. If you mean to truncate the column label in the header line when displaying the sort indicator, e.g. change "Status" to "Sta=E2=80=A6 =E2=96=BC", I'm dubious it's worth th= e effort, since most of the problematic cases in the Emacs sources are with the final column, where there's always enough space, but due to the misleading description in tabulated-list-format's doc string, many modes have made it unnecessarily narrow, preventing the display of the sort indicator. So to avoid the final column being labelled e.g. either "File" or "Fi=E2=80=A6 =E2=96=BC" instead of "File =E2=96=BC", it is necess= ary to change the width manually anyway. In other words, the truncation proposal would be an addition to manual fine-tuning (for non-final columns), not a substitute for it. Or did you mean something else? Steve Berman From debbugs-submit-bounces@debbugs.gnu.org Mon Oct 19 14:43:58 2020 Received: (at 44068) by debbugs.gnu.org; 19 Oct 2020 18:43:58 +0000 Received: from localhost ([127.0.0.1]:42363 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUa8U-0005Yp-A2 for submit@debbugs.gnu.org; Mon, 19 Oct 2020 14:43:58 -0400 Received: from eggs.gnu.org ([209.51.188.92]:58362) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUa8S-0005Yc-Ba for 44068@debbugs.gnu.org; Mon, 19 Oct 2020 14:43:56 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:39821) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kUa8M-0006VA-SB; Mon, 19 Oct 2020 14:43:50 -0400 Received: from [176.228.60.248] (port=4412 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kUa8M-0007Ky-B7; Mon, 19 Oct 2020 14:43:50 -0400 Date: Mon, 19 Oct 2020 21:43:57 +0300 Message-Id: <831rhuoy36.fsf@gnu.org> From: Eli Zaretskii To: Stephen Berman In-Reply-To: <877drm13j3.fsf@gmx.net> (message from Stephen Berman on Mon, 19 Oct 2020 20:20:16 +0200) Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 44068 Cc: 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Stephen Berman > Cc: 44068@debbugs.gnu.org > Date: Mon, 19 Oct 2020 20:20:16 +0200 > > > Instead of manually fine-tuning each column's width, wouldn't it be > > better to use the string-trim capabilities that replace excess > > characters with an ellipsis? > > I'm not sure I understand your suggestion. If you mean to truncate the > column label in the header line when displaying the sort indicator, > e.g. change "Status" to "Sta… ▼", I'm dubious it's worth the effort, > since most of the problematic cases in the Emacs sources are with the > final column, where there's always enough space, but due to the > misleading description in tabulated-list-format's doc string, many modes > have made it unnecessarily narrow, preventing the display of the sort > indicator. So to avoid the final column being labelled e.g. either > "File" or "Fi… ▼" instead of "File ▼", it is necessary to change the > width manually anyway. In other words, the truncation proposal would be > an addition to manual fine-tuning (for non-final columns), not a > substitute for it. Or did you mean something else? Yes, I meant it as an addition, which will make this issue much more future proof. Documentation update is definitely fine (and should probably go to emacs-27, not to master, right?), and adjusting the column widths to eliminate the ellipsis is also okay. I just don't want us to end with these two and nothing else. From debbugs-submit-bounces@debbugs.gnu.org Mon Oct 19 15:12:58 2020 Received: (at 44068) by debbugs.gnu.org; 19 Oct 2020 19:12:58 +0000 Received: from localhost ([127.0.0.1]:42482 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUaaX-0008UM-MY for submit@debbugs.gnu.org; Mon, 19 Oct 2020 15:12:57 -0400 Received: from mout.gmx.net ([212.227.17.20]:60717) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUaaW-0008U2-EJ for 44068@debbugs.gnu.org; Mon, 19 Oct 2020 15:12:57 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1603134770; bh=MQTbd+6iotPRRJTolCLHzAIcJIFN3932cOfXd8mgBKk=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=hc7hsmND4YOZ3q4pVULRAsyP1ioSL9oeC9hhlnB9AAiQBYV0zwt9jc/XIpAF17M8X l5JjZwCg9vhn2hygE5qSk6qem3K10wYIjDrhLiqeq4568kNvCQi87ZrUnIIlI3lKrw y+RqB6MN7XJVRGtMUIhuuLi6IpyhGTS1hFP3+JSo= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([188.101.169.69]) by mail.gmx.com (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MuUjC-1kDKwy0JEI-00rV4k; Mon, 19 Oct 2020 21:12:50 +0200 From: Stephen Berman To: Eli Zaretskii Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> Date: Mon, 19 Oct 2020 21:12:44 +0200 In-Reply-To: <831rhuoy36.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 19 Oct 2020 21:43:57 +0300") Message-ID: <87y2k2yqqb.fsf@gmx.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:57FCpFFy0IwqUZsPldGT31K3wVv3KqaNbX0xwbzdAx87PwuX7gy o5lnDyybXzmtd9BDOx9QDBxy6uFioe9AiAi4FAhRpYeC1LmQ+MDipfrlljk8e3UCTFNGKyh 6QSmzMBnGPFunz1BJajB+0Osn//+cATD9jA0G96mfG616Szf57P3Z87IRxycMepixya5ooT CjAiS+neXUMI3S8eIn0rQ== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:Dt1AE4f4psA=:rnBUcB7OtSVhwJSv0q4Y10 QwmUlAQDluQtB4FiLIGF/PY1qhfRTFvnf+6Jb7RphRRNWGGSLd94S0wJNY9BzoktbEK4NUL7t K7GhWy49kR0YuZvtTfrJo9yDMaVwuHilpvaqYk7tZz23fgSmDlVp5JLXXfUHoZacMFZyWK2YI i473ak2Wp/QIQqdICrVHn81cMEs6e8W3tVpiFfOJw7NtvGZUSc6z1YvcJK3oQK8/MJW7Vg47w qe4RVHkwAlT+X1RuTU3Yk+K7nUZGsTn+ZZP/b77Y69G9NW7sy6hhuYc2eJgbO/ucszmfzsE5u 4ztd44XQyrHvHlWCJdEVafVg/M4tRrLaEidn6sVCrBmJhumGBlJ/jadoJVDFAdTWlsCLgzZEd eFkgUvzFH9vwrXn3F0wY84fdTRRzp5ISV5yG9ylPWJyV0dc1prg3R6HILANK+JoJ8gN4MBzGt Uhgzxa2wjCOIB0qAiDmTsEAGACgN4gkcotPOTCrz0hx1OM7PWuvzY+akL+wor1REGqj+xao1p jek/pvdXpqoLktwVWNRlu02DQEu5v+ZksbHYVD/ph8mqMjV9c5ZzPzpIBx0W8tuVyLU3fpGI/ S9OJ+S59/WwnY1R6uA8GtJ73lkPiBto47K548XGnGSwtvrMdpWbpUg5ZVzNmUx1bBIT6Q7s4i Hww3OJw030HoZE4tvjBosXx6OKmzXaRlpgZQ3prNqfAcU8AwQ+JAN5Cf67c1dipSFIERUH+Xw 9/cYd8pIt9Pt56BKn56pkGe9PgjacnJMU2Q4DbH0jJwk3cFUL0dpJsemvSqc/0O2yvX+a/kgg ihLNdJJQNjHXKv7vrCnnuznSeBT/uR6BjRXLdlo+RjN7WZJSvTkF2DmHCxbjEQ611+2jE2e1u tvfg5+3nDT3iqgr/MObA== X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44068 Cc: 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Mon, 19 Oct 2020 21:43:57 +0300 Eli Zaretskii wrote: >> From: Stephen Berman >> Cc: 44068@debbugs.gnu.org >> Date: Mon, 19 Oct 2020 20:20:16 +0200 >>=20 >> > Instead of manually fine-tuning each column's width, wouldn't it be >> > better to use the string-trim capabilities that replace excess >> > characters with an ellipsis? >>=20 >> I'm not sure I understand your suggestion. If you mean to truncate the >> column label in the header line when displaying the sort indicator, >> e.g. change "Status" to "Sta=E2=80=A6 =E2=96=BC", I'm dubious it's worth= the effort, >> since most of the problematic cases in the Emacs sources are with the >> final column, where there's always enough space, but due to the >> misleading description in tabulated-list-format's doc string, many modes >> have made it unnecessarily narrow, preventing the display of the sort >> indicator. So to avoid the final column being labelled e.g. either >> "File" or "Fi=E2=80=A6 =E2=96=BC" instead of "File =E2=96=BC", it is nec= essary to change the >> width manually anyway. In other words, the truncation proposal would be >> an addition to manual fine-tuning (for non-final columns), not a >> substitute for it. Or did you mean something else? > > Yes, I meant it as an addition, which will make this issue much more > future proof. Documentation update is definitely fine (and should > probably go to emacs-27, not to master, right?), and adjusting the > column widths to eliminate the ellipsis is also okay. I just don't > want us to end with these two and nothing else. Ok. I can try, but anyone should feel free to beat me to it. Steve Berman From debbugs-submit-bounces@debbugs.gnu.org Tue Oct 20 12:10:09 2020 Received: (at 44068) by debbugs.gnu.org; 20 Oct 2020 16:10:09 +0000 Received: from localhost ([127.0.0.1]:46481 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUuDA-0003n4-Sx for submit@debbugs.gnu.org; Tue, 20 Oct 2020 12:10:09 -0400 Received: from mout.gmx.net ([212.227.15.18]:34145) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUuD8-0003mA-9N for 44068@debbugs.gnu.org; Tue, 20 Oct 2020 12:10:07 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1603210198; bh=0BS+p/M15zHK9sza1SvOksjRqLY5U+T0WyFmeqTdLOU=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=CYzVxbl1U5G4YItsF+db4jsAbrrw3vv/h4S1vGLeKZ9Bm7jnwRuI8GXuF6B1KvN9r kkBCcX1555BNqPkuA41aSls6K7dQ5q4MmDNUi41dRBaPayq1KycifRGNM25JWMAq9W Q9N3j10jLXXwJtt+gqg9FMcQ+IuXPLEwlZn9t8uc= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([92.73.70.92]) by mail.gmx.com (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MtOKi-1k9ejQ0rb4-00upL0; Tue, 20 Oct 2020 18:09:58 +0200 From: Stephen Berman To: Eli Zaretskii Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> Date: Tue, 20 Oct 2020 18:09:56 +0200 In-Reply-To: <87y2k2yqqb.fsf@gmx.net> (Stephen Berman's message of "Mon, 19 Oct 2020 21:12:44 +0200") Message-ID: <87h7qori97.fsf@gmx.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Provags-ID: V03:K1:mY76N99rCeWhwigUI6y1wesr5It8hH6YayS/FOqVJ60F0RujObC TrVnSgCUvHt7Aj58Bmv4zFpbdkccFm/69rCZL2rwQznORrbJ4q72v6H5uwUa9UQMgsFyKc2 z34FFX9DgugXs84IjijERpeNc+H53i8WIXg8GrDFrW6Eg04fiYkoSuYPMSDFFGqOJhSYPQ+ kpdBsMuibPa3kCER6lehQ== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:0VggqEpZtb0=:zW1ST7oTuVlhqMb9U0NV6V dgOqPnoFQfYKumg8yEEHxt/osuDBMmREbpSCPTkGl8U2rVxwxU0gTEVu1EM7WC6B5tYvjRHr4 gp0vj9cvD6fP+nZSeFwcwc+OPnjosngE90bl89Rt75bf3gvpNfjzSxj4/1NzK78OT95hTyiTV n97uQnR5jY4FdnNj4pD6muC1SVedeGpPTPMnt66pUIITaoH97luGLRwc/o9nTHytAkZC3N40Y JkOR2Jaak7nQDWyanGKVZMtHOmUxdzbBH11cK6vyM5wM1vtjA5vbVR8WTRi46XytO+4Cbpm21 LYnnfluYTr1Toz2bdJXrhoNzczDXbuyZhc+R+qwl+MHJAWJ3BpUJHOa9unxoXl3w4+G9FdgOV tezit1H4tEZv5H0wcQ0dY8TJ1WHArEZHVD6hH931l34/CxX1kLmhPdKzzsbflJhTYESBObXXb xngQz5wCW/8EkBE3e+0jmloPN19jwAUcE9xBH7L4xcJDRzil41zGt17oYwDlsW0nMHJy760Br f8xV+BsezMu9Y2n4tQXq3tI+VSa3hue01tL+nZAhr6vpU/1U2L5PQeEzl4dymo2WbuirNYtsW vOfJjdgm/guqLnDi8Yv+j5UT1F/Tqwh0Nb13uuGw3KhVuKDMFUHnvxc3udtyLMClLspeX1WzU o9DaXDI2GzkD5/sMJxK4yf3yB0BpFGbFqDkXcSh0sscu6KSW2Pq1tCwEYwQxz8c6wqpc8ggQ3 nMwynlBdknOjER9oCGprgITuyRpaIZtavlhVLZCzsSen0ftz/faIXgZM2Fsc+sCEHeLlRDvgE ymKJF9YRn1vwRdUm5Qjq1feD4Z1v9kO+mPu5wCZ/KfRntmQXuu7AmcvE44PZemKcbQCGhYHbK AW/EHc8o556GE40VCUYw== X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44068 Cc: 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On Mon, 19 Oct 2020 21:12:44 +0200 Stephen Berman = wrote: > On Mon, 19 Oct 2020 21:43:57 +0300 Eli Zaretskii wrote: > >>> From: Stephen Berman >>> Cc: 44068@debbugs.gnu.org >>> Date: Mon, 19 Oct 2020 20:20:16 +0200 >>>=20 >>> > Instead of manually fine-tuning each column's width, wouldn't it be >>> > better to use the string-trim capabilities that replace excess >>> > characters with an ellipsis? >>>=20 >>> I'm not sure I understand your suggestion. If you mean to truncate the >>> column label in the header line when displaying the sort indicator, >>> e.g. change "Status" to "Sta=E2=80=A6 =E2=96=BC", I'm dubious it's wort= h the effort, >>> since most of the problematic cases in the Emacs sources are with the >>> final column, where there's always enough space, but due to the >>> misleading description in tabulated-list-format's doc string, many modes >>> have made it unnecessarily narrow, preventing the display of the sort >>> indicator. So to avoid the final column being labelled e.g. either >>> "File" or "Fi=E2=80=A6 =E2=96=BC" instead of "File =E2=96=BC", it is ne= cessary to change the >>> width manually anyway. In other words, the truncation proposal would be >>> an addition to manual fine-tuning (for non-final columns), not a >>> substitute for it. Or did you mean something else? >> >> Yes, I meant it as an addition, which will make this issue much more >> future proof. Documentation update is definitely fine (and should >> probably go to emacs-27, not to master, right?), and adjusting the >> column widths to eliminate the ellipsis is also okay. I just don't >> want us to end with these two and nothing else. > > Ok. I can try, but anyone should feel free to beat me to it. I was wrong that adjusting column widths in tabulated-list-format is necessary: with the attached patch, when a non-final column whose label is at least 3 characters long is selected, the label will get truncated and a sort indicator added; but the final column label will never get truncated and always get a sort indicator when selected. The question remains whether the truncated display in current (non-adjusted) uses of tabulated-list-mode is acceptable: if so, the patch below is all that's needed, if not, then the adjustments in my first patch can be made as well. Those interested should try the patch with list-buffers, list-bookmarks, list-packages, list-processes, list-dynamic-libraries, org-lint and flymake-diagnostics-buffer-mode to see how the display looks. Depending on the decision about that, the doc string of tabulated-list-format should be reworked accordingly. Steve Berman --=-=-= Content-Type: text/x-patch Content-Disposition: attachment Content-Description: tabulated-list-init-header patch diff --git a/lisp/emacs-lisp/tabulated-list.el b/lisp/emacs-lisp/tabulated-list.el index b13f609f88..aff7f985b9 100644 --- a/lisp/emacs-lisp/tabulated-list.el +++ b/lisp/emacs-lisp/tabulated-list.el @@ -269,15 +269,18 @@ tabulated-list-init-header ;; FIXME: Should share code with tabulated-list-print-col! (let ((x (max tabulated-list-padding 0)) (button-props `(help-echo "Click to sort by column" - mouse-face header-line-highlight - keymap ,tabulated-list-sort-button-map)) + mouse-face header-line-highlight + keymap ,tabulated-list-sort-button-map)) + (len (length tabulated-list-format)) (cols nil)) (if display-line-numbers (setq x (+ x (tabulated-list-line-number-width)))) (push (propertize " " 'display `(space :align-to ,x)) cols) - (dotimes (n (length tabulated-list-format)) + (dotimes (n len) (let* ((col (aref tabulated-list-format n)) + (not-last-col (< n (1- len))) (label (nth 0 col)) + (pname label) (width (nth 1 col)) (props (nthcdr 3 col)) (pad-right (or (plist-get props :pad-right) 1)) @@ -287,24 +290,27 @@ tabulated-list-init-header (cond ;; An unsortable column ((not (nth 2 col)) - (propertize label 'tabulated-list-column-name label)) + (propertize label 'tabulated-list-column-name pname)) ;; The selected sort column ((equal (car col) (car tabulated-list-sort-key)) - (apply 'propertize - (concat label - (cond - ((> (+ 2 (length label)) width) "") - ((cdr tabulated-list-sort-key) - (format " %c" - tabulated-list-gui-sort-indicator-desc)) - (t (format " %c" - tabulated-list-gui-sort-indicator-asc)))) - 'face 'bold - 'tabulated-list-column-name label - button-props)) + (let* ((l (length label))) + (when (and (>= l 3) (> (+ 2 l) width) not-last-col) + (setq label (truncate-string-to-width label (- l 2) nil nil t))) + (apply 'propertize + (concat label + (cond + ((and (< l 3) not-last-col) "") + ((cdr tabulated-list-sort-key) + (format " %c" + tabulated-list-gui-sort-indicator-desc)) + (t (format " %c" + tabulated-list-gui-sort-indicator-asc)))) + 'face 'bold + 'tabulated-list-column-name pname + button-props))) ;; Unselected sortable column. (t (apply 'propertize label - 'tabulated-list-column-name label + 'tabulated-list-column-name pname button-props))) cols) (when right-align --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Thu Oct 29 12:59:02 2020 Received: (at 44068) by debbugs.gnu.org; 29 Oct 2020 16:59:02 +0000 Received: from localhost ([127.0.0.1]:54804 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYBGQ-0001Xr-1m for submit@debbugs.gnu.org; Thu, 29 Oct 2020 12:59:02 -0400 Received: from mail-ej1-f45.google.com ([209.85.218.45]:35033) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYBGO-0001XM-Jg for 44068@debbugs.gnu.org; Thu, 29 Oct 2020 12:59:00 -0400 Received: by mail-ej1-f45.google.com with SMTP id p5so4823164ejj.2 for <44068@debbugs.gnu.org>; Thu, 29 Oct 2020 09:59:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:in-reply-to:references:mime-version:date:message-id:subject:to :cc; bh=c3qpUBB3yYCwyg92T7vvScGVlRKG5egOtFr/9meFal8=; b=nQl5kRfXFehrGkYQLQ4m8H1W+z4l/c30vh/aLvrBX8bQ4TSJHf6HECaJti3/4pyj3n PMvkrb521Z7MLqadsQdhlf8f7v9ure8t9a5wcCl2W/1rxMi1ZQif9a3EUK8d5ZJhJETv c87qy9DLGClACm1gfMx1mvsMGrgomKil+2fZF8F+xAGTts/KlRITScEtv65S7MEjVeJa anMlrNY9fAoe6MxHelEzlbF2tNSmu1lfYOYcQKKJxclvuLCODpPx+c9HTx9gFDspyBC4 fZ9fZU6V9iyiH1aFINtWWTliaFQWOkh8DUCscUB26eeqQTgOX0Xrvjo0JEEhModo4yYc 6mWw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:in-reply-to:references:mime-version:date :message-id:subject:to:cc; bh=c3qpUBB3yYCwyg92T7vvScGVlRKG5egOtFr/9meFal8=; b=s0tCyQBfKL6Q5/wsgoSKbNtlJB00cbBs3EuUuLMjwt7+Ytok0Hz9b3d59jh1+3GIms juueaqt5ISziXJx9MGgllwosKUpbXc+jlsG6egW6P3sgQSC/DtCmP3hOcZHX1OG4UjZU rdsFfGYoUykpQ+9Wul1qQBiMtnP0oZLvAVA3zgisiodPfWpjDSHnLOf/UMhB64fg7S22 0jtDs1ikYA8I6/zEkhzbUrQ8pH7kWK8JIjZJbQL5/5OXVsnBxrRNNPnLROcc20KL3bwG YNo9ZUAPUcVYGdytJZteeGf/3ppgBGhfm5IueCrn7cwEaRtuhVdIMAJIOeVgBT2gxcw1 8qrg== X-Gm-Message-State: AOAM530QmcI4aiUgs0TwYhi0RyIVojONDEK7yUQEXXTIf6RHushaYPAL oFXD9wAaaSekHjLwKYSqJGc4yYDjIpnpdzn+i6Q= X-Google-Smtp-Source: ABdhPJxcmAsFTe0NbjX27IumZx5CQo+opC1V8esid6sFLSaCoHUVqck64AYk4JCHddtkSY7ZPFu+JBlKjlxtJLeZP3Q= X-Received: by 2002:a17:906:a40b:: with SMTP id l11mr4852488ejz.25.1603990734703; Thu, 29 Oct 2020 09:58:54 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Thu, 29 Oct 2020 16:58:52 +0000 From: Stefan Kangas In-Reply-To: <87h7qori97.fsf@gmx.net> References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> MIME-Version: 1.0 Date: Thu, 29 Oct 2020 16:58:52 +0000 Message-ID: Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format To: Stephen Berman , Eli Zaretskii Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 44068 Cc: 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Stephen Berman writes: > I was wrong that adjusting column widths in tabulated-list-format is > necessary: with the attached patch, when a non-final column whose label > is at least 3 characters long is selected, the label will get truncated > and a sort indicator added; but the final column label will never get > truncated and always get a sort indicator when selected. The behavior with your patch looks like an improvement to me. How about the case when we narrow the column but there is no sort indicator, should we use the ellipsis then? See for example `list-buffers' when using the narrowing commands without sorting on any of the headers. > The question remains whether the truncated display in current > (non-adjusted) uses of tabulated-list-mode is acceptable: if so, the > patch below is all that's needed, if not, then the adjustments in my > first patch can be made as well. I'm not sure I understand what you mean here, could you elaborate? From debbugs-submit-bounces@debbugs.gnu.org Thu Oct 29 18:48:51 2020 Received: (at 44068) by debbugs.gnu.org; 29 Oct 2020 22:48:51 +0000 Received: from localhost ([127.0.0.1]:55258 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYGix-0008G3-D3 for submit@debbugs.gnu.org; Thu, 29 Oct 2020 18:48:51 -0400 Received: from mout.gmx.net ([212.227.15.19]:46233) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYGiu-0008Fp-Qo for 44068@debbugs.gnu.org; Thu, 29 Oct 2020 18:48:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1604011722; bh=wEDuKTIEwYMN82a6totF43zyw6roVPq6PLWXU3yqXpY=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=Udwcx0rh//S3Vo0JqfdYlDVpVjpCoip+5rn0/HoyYVp9DiQMMfdcauq8cL+sA5xzM //7eqEnUdehio20T9YZ1LUjZqFXHMlLHjwLbf+RDoAZi+grvNdyxb9bg3kwe+oL6xo MIBbmg8u0dQYRIEK8lBDhWGe8M7caMkQUt/kCS1I= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([178.6.218.181]) by mail.gmx.com (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1M2O2W-1kWcYp3uU2-003rXs; Thu, 29 Oct 2020 23:48:42 +0100 From: Stephen Berman To: Stefan Kangas Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> Date: Thu, 29 Oct 2020 23:48:38 +0100 In-Reply-To: (Stefan Kangas's message of "Thu, 29 Oct 2020 16:58:52 +0000") Message-ID: <874kmcfy2h.fsf@rub.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Provags-ID: V03:K1:85G5A47iI1hv8W6gaZ48lfkpvY1aVkPTLyCnUIPz86pCwVVPK5Y q31m91iOB9ZFu7qGcLAprqcrRE143c7/uNSMcvEFAr/rpxStIu/pynI2wxn/w3u3SIevMBJ F4dyD9VfrKrUJTMi1HE2cjeDCvXtWeUC4DQ21ezzcHcZEfPYXB/BOsaBgUM4Ffw69X2kjEQ C01weujn+T4NVt32fJGsQ== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:9KJcpBsVOJQ=:0yrAKRPxHNt3J/SppE1JV2 wKUkLVusadfwDuDQnyuyB62MF/J6AzNvoIU38fvp7djFaA8BlfLURoYtPG73yV94ulC5zme7e oOPk1K+VRdWU54WVrD9GkE+Kl7munQVFwHvLSd2jMxoUoDYcrk6vG9CBQiNUGV09B6k3XPQAz z7dAv/4VEf4jstLtblvsijByMRXXs/cAoiOJETTuatgQfFq8ELdN8DsbsrS8onQ4p4yLYU7R0 cXNCpGlwcaWeCHfP/x3HzdTDzqjHE+ELrskecaoVwy85Ygky0GpDqK0NX7YRL5iZbT1jnTgpF eV+ftSo6voEd7t/ispfcK+U3sWQTQ/bLEHQi3p3iS20dkVn+U3yqm5VQ+YE2cZbBYUbk9bTR9 ptZUfyuG0lVRprNlxSxQ+hiaNTqxv8JsMhcrdiiaQ1P3JBaaXulXaAi3DAaN0jgFHPFtUYRdm r0GtNSN3TdCLMk3D3+jm+EcFkQHriQT/DIIWQ1FDJrVbAmYLtFR1X2NdTCUUql/vAd2douuUz mIcRRzv9GSPrznfL1hNZ9qsjWku4xI9w6MhwczzAl2XHYB5zvuihSSspSSSPLnKcAcLajvFDG R6udQfFLqPBm9s9rC05L23b/+mL6HtAMoM+83efMaHme2w6GuqzqtTQZouLqLxZ8R6UJhOH5z gHhwQUxSpGlPjL9mA3XXXaKVElwNjBCyY9apf0gPkLSEMPWSLxAEfPv2owC9+vQI0Yqp7jHXR tzCfBZELL4fexPyP6UTxIRq2h3E6OpLhK6mb+9VWcX2etpz60dtOofUCMh9ODJ0cxLlZTLaTA 5VvyRJs4D4I4LhFSXnyBcZ2fe+uhbU9zHpQf45P7Ex1X797UH8MHQNyaR7F1FbgKjuPMfJzIz nuxLDfsbW0OPywzwcBaA== X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44068 Cc: Eli Zaretskii , 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) --=-=-= Content-Type: text/plain On Thu, 29 Oct 2020 16:58:52 +0000 Stefan Kangas wrote: > Stephen Berman writes: > >> I was wrong that adjusting column widths in tabulated-list-format is >> necessary: with the attached patch, when a non-final column whose label >> is at least 3 characters long is selected, the label will get truncated >> and a sort indicator added; but the final column label will never get >> truncated and always get a sort indicator when selected. > > The behavior with your patch looks like an improvement to me. How about > the case when we narrow the column but there is no sort indicator, > should we use the ellipsis then? See for example `list-buffers' when > using the narrowing commands without sorting on any of the headers. Try the attached patch; does it do what you're suggesting well enough? --=-=-= Content-Type: text/x-patch Content-Disposition: attachment Content-Description: tabulated-list-init-header patch diff --git a/lisp/emacs-lisp/tabulated-list.el b/lisp/emacs-lisp/tabulated-list.el index b13f609f88..4341ad4f92 100644 --- a/lisp/emacs-lisp/tabulated-list.el +++ b/lisp/emacs-lisp/tabulated-list.el @@ -269,42 +269,50 @@ tabulated-list-init-header ;; FIXME: Should share code with tabulated-list-print-col! (let ((x (max tabulated-list-padding 0)) (button-props `(help-echo "Click to sort by column" - mouse-face header-line-highlight - keymap ,tabulated-list-sort-button-map)) + mouse-face header-line-highlight + keymap ,tabulated-list-sort-button-map)) + (len (length tabulated-list-format)) (cols nil)) (if display-line-numbers (setq x (+ x (tabulated-list-line-number-width)))) (push (propertize " " 'display `(space :align-to ,x)) cols) - (dotimes (n (length tabulated-list-format)) + (dotimes (n len) (let* ((col (aref tabulated-list-format n)) + (not-last-col (< n (1- len))) (label (nth 0 col)) + (lablen (length label)) + (pname label) (width (nth 1 col)) (props (nthcdr 3 col)) (pad-right (or (plist-get props :pad-right) 1)) (right-align (plist-get props :right-align)) (next-x (+ x pad-right width))) + (when (and (>= lablen 3) + (> (+ 2 lablen) width) not-last-col) + (setq label (truncate-string-to-width label (- lablen 2) + nil nil t))) (push (cond ;; An unsortable column ((not (nth 2 col)) - (propertize label 'tabulated-list-column-name label)) + (propertize label 'tabulated-list-column-name pname)) ;; The selected sort column ((equal (car col) (car tabulated-list-sort-key)) (apply 'propertize - (concat label - (cond - ((> (+ 2 (length label)) width) "") - ((cdr tabulated-list-sort-key) + (concat label + (cond + ((and (< lablen 3) not-last-col) "") + ((cdr tabulated-list-sort-key) (format " %c" tabulated-list-gui-sort-indicator-desc)) - (t (format " %c" + (t (format " %c" tabulated-list-gui-sort-indicator-asc)))) - 'face 'bold - 'tabulated-list-column-name label - button-props)) + 'face 'bold + 'tabulated-list-column-name pname + button-props)) ;; Unselected sortable column. (t (apply 'propertize label - 'tabulated-list-column-name label + 'tabulated-list-column-name pname button-props))) cols) (when right-align --=-=-= Content-Type: text/plain >> The question remains whether the truncated display in current >> (non-adjusted) uses of tabulated-list-mode is acceptable: if so, the >> patch below is all that's needed, if not, then the adjustments in my >> first patch can be made as well. > > I'm not sure I understand what you mean here, could you elaborate? I meant that in some uses of tabulated-list-mode there are columns whose default width is so narrow that, when selected for sorting, they are immediately truncated (using the patch in my previous post), e.g. the "Status" column in list-processes. And the issue is exacerbated with the current patch implementing your new suggestion: with its default width "Status" is now truncated whether selected or not. In such cases it may be better to make the default width of such columns wider, which is what my first patch did. Then with the current patch, it will still be truncated when the column is sufficiently narrowed with `{'. Steve Berman --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Thu Oct 29 21:06:25 2020 Received: (at 44068) by debbugs.gnu.org; 30 Oct 2020 01:06:25 +0000 Received: from localhost ([127.0.0.1]:55548 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYIs4-0005U2-NJ for submit@debbugs.gnu.org; Thu, 29 Oct 2020 21:06:24 -0400 Received: from mail-ej1-f51.google.com ([209.85.218.51]:45958) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYIs2-0005Tq-TP for 44068@debbugs.gnu.org; Thu, 29 Oct 2020 21:06:23 -0400 Received: by mail-ej1-f51.google.com with SMTP id dk16so5765883ejb.12 for <44068@debbugs.gnu.org>; Thu, 29 Oct 2020 18:06:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:in-reply-to:references:mime-version:date:message-id:subject:to :cc; bh=EaHiDs5ZYNSXf6a0AQm3fe6I/ASghz4iOLuy91cb2ro=; b=cI25ZznIGK7NH3S6yJMoTaezowZeMY+Rl/TJZp1vRARaUT60w9i19pJLJH2s/B6/1M 1/U3SkvZMMEn5nfkk2JBuoaBFrcXgZm5SjyRw22TfbYsfdre6aVLi3UI4TfRZloo2Q1x IiKnrN+CAcvxMIoFJGws0dev0fCLAJ/LeySL32wntEKCK8BcEw6GnXD2jkHGukodkJDs 466OKldtwt1HnrXLQf73AE67nvGDqmqItsP4qq7ncqkicrRHUTMxSysNSh2V/zHM5OLB jZ8UoBuu44nIwAISHf9x9cZWE1tvPMHFpB02Uz0PTCpyQguEJn+1pXlDKIvdjQGiFTNc Nqog== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:in-reply-to:references:mime-version:date :message-id:subject:to:cc; bh=EaHiDs5ZYNSXf6a0AQm3fe6I/ASghz4iOLuy91cb2ro=; b=Uyqrmn2aJgMvwy1B5y36RwoPHsyrHC5YrULDo7hki22iTzOh2DPkIxFwHEP+OR/K1q S5JT5hi6PsjcstBCK3PtsprBs7+l6/lyWIzPjdX+N+nrHDn6o7X4fNK3H6r0+2dSqqfV /GLib5YSsygkqJ7ufpnq436uIIPjfErusRgCe8c0aAIVJAvHmRcn4RN8JnJizJ/ZNoDN K4Qo+ZdA4IilE2XZLAaXXnQhj6/Kx41wjwlo571wRaOq7OhEVGkWd9FdwSe/hvFrMcQr Wk8KyoKqf+I4d9/yNhXH8CsyM83opKZIVowoOXDGPk0B7SbdiFqkApr6ESvrK94PjdOg T3cA== X-Gm-Message-State: AOAM532K0GYxXbkEoHjBolTricZKuO9ftjQENKyT4CScze/5JCs1D3+Z 3V9fNFxc7XKKsH10pXNGhC8kkWhiAGmvLx52rDA= X-Google-Smtp-Source: ABdhPJzufsExh1/u7bhzRRQnM3oIr7uOS2eFs96mvihsTCLAwYwU0/PsquMej1wJp9vW08a7Ylzbzizcw+RWIycdJ54= X-Received: by 2002:a17:906:a40b:: with SMTP id l11mr55815ejz.25.1604019977137; Thu, 29 Oct 2020 18:06:17 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Thu, 29 Oct 2020 18:06:16 -0700 From: Stefan Kangas In-Reply-To: <874kmcfy2h.fsf@rub.de> References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> <874kmcfy2h.fsf@rub.de> MIME-Version: 1.0 Date: Thu, 29 Oct 2020 18:06:16 -0700 Message-ID: Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format To: Stephen Berman Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 44068 Cc: Eli Zaretskii , 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Stephen Berman writes: > Try the attached patch; does it do what you're suggesting well enough? Yes, it looks better. > I meant that in some uses of tabulated-list-mode there are columns whose > default width is so narrow that, when selected for sorting, they are > immediately truncated (using the patch in my previous post), e.g. the > "Status" column in list-processes. And the issue is exacerbated with > the current patch implementing your new suggestion: with its default > width "Status" is now truncated whether selected or not. But the "Status" field in process-menu-mode is 7, so why is it truncated when there is room? "Status" is only 6 characters. I would expect that "Status" was not truncated in this case, IOW that: - Without a sorting indicator - label width <= column width => display it all - label width > column width => truncate - With a sorting indicator - label width <= column width => display it all - label width > column width => truncate For the last column, we should probably just show it all regardless of its width, and never truncate. Does the above make sense? BTW, perhaps we should add unit tests for all this, since it seems like we have a fair amount of use-cases to think about. Maybe that could be a good excuse to make tabulated-list-init-header a bit more functional... > In such cases it may be better to make the default width of such > columns wider, which is what my first patch did. Then with the > current patch, it will still be truncated when the column is > sufficiently narrowed with `{'. Yes, the default width of such columns should also be made wider, I think. But first we should probably make sure that the underlying logic here is sound. Thanks again for working on this. From debbugs-submit-bounces@debbugs.gnu.org Fri Oct 30 17:45:01 2020 Received: (at 44068) by debbugs.gnu.org; 30 Oct 2020 21:45:02 +0000 Received: from localhost ([127.0.0.1]:60030 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYcCj-0002T6-Fi for submit@debbugs.gnu.org; Fri, 30 Oct 2020 17:45:01 -0400 Received: from mout.gmx.net ([212.227.15.19]:54017) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYcCh-0002Sl-W7 for 44068@debbugs.gnu.org; Fri, 30 Oct 2020 17:45:00 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1604094293; bh=TaqU9qWarLfvrjurZa1qu+uHbIMjVcDZl13/5Nqcq0s=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=AN0O2gNmRuz8KzocjoUN1awnj0xNkHQKR96Rn1KzYWJiiC6+cMjGcBIr9PCgpWYI7 r+UPClnr93jOE7EoVjxuSJJLEV/26T6E2zMKQsZx/f2SkqfjYWh0Aw1xbY/Hr8YeGi 24eJVYDGpIFDuwbbHgNIatxHpt2atSV6Ia+I2jA4= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([92.73.67.224]) by mail.gmx.com (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MzyuS-1kC1PH1foU-00x1fQ; Fri, 30 Oct 2020 22:44:53 +0100 From: Stephen Berman To: Stefan Kangas Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> <874kmcfy2h.fsf@rub.de> Date: Fri, 30 Oct 2020 22:44:48 +0100 In-Reply-To: (Stefan Kangas's message of "Thu, 29 Oct 2020 18:06:16 -0700") Message-ID: <875z6rmlrj.fsf@rub.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Provags-ID: V03:K1:mYrWMTM/dX5TGnNhreghaegGB2t53xXvEf6aBUSvroj4GAdDbZB 8TgSMBND2qnBd+0vfz7l/i9g/lMIogv17+YtHykaPmGqIJ7tgkmTckU6k9FscRSiZqoA4DS zF8fu1hWk3vQrW0w3USaoTEaf44yiP8j2IjgMucMa7J8kCenumsBtk4jpE5gZ10B542T9uO Nq6slzNPrWNPM/zD/IBZQ== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:f/1FsUJL7D4=:55L1/zl80n4A3US+8NmF5m BW2DnrBWgBa/My324nBDKhVmnatBKGr8a2plOwRaWY3kxRhnh+cNkt+FC56YPDeRS52syL2os KO6p3his7+9OVW+u4RHQn4Z6zXb/Kwscm+rNPpthkLBYEvAqyNkoDUlRQkQCWo4y/pzkZhE9r IE2vKcYMXPXQEGJ4Ldl5QNh1hRmbbk8KYD+1CSxwfUKdGlZLMhWdThHcxaQlWkRyPFPS/38+6 ol2VBIgNKLAHnKoHSXRBlR7gJ+FrZQaCmfp5NLJbXKE+zQaaPnn7mSBKDb+VLnBOhgerE5M0E V7N0Nd/gYf0ZUSySXOqERrg7v7ZGAT10msuh1c3G5UzbmXxNFnIopKCJmQbC8X4/1BUuarAQn STl9k6TFERwJGbjh1GukjgnA010J52iJvzEpxeDMtZiWmWxNPz2gej6lXC6/40Ga4YVSPHn9T YCnlGRdJmdMQUwU1d7khPd6qhalrUhwVDUjA5t+AENpcRMmHPOltwKqs3G2FaKdIS19TJtLZ4 RNhGvoz2+Oa6C7JQ1D9jgFNS68j5eWDYNh2vq/Av8P/uPKms9s2KU1s7sp0vV1c57Jdqq/qDg cvma/yJpHCLEI47DQASHDP/uiE/EDf+BFvJ4zvd5qHb4T2DR0DlDx6H/gn/kxpgvn7wcivFbB WR3ipqdxNSm9ZMQhAzUohhXwqXdWujoagp2gyjVuCRs//dhVCLd/qv7UciBirOamA+0M3SHpb MVz+5oM/UNzN9GTnRZijCf55DjBUvAFlFMfED5ySigf7htIjNsl2QIgx/h4soltIyZ5VCwqO7 KU0R+yYePxYukvqcPwJMXCiNtVGL6Hjy95FY/g+BIEgNw3u2SdAf8ZXpasu9sm5RX62jje+14 FKHvVYGYdx0g0z14Il2Q== X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44068 Cc: Eli Zaretskii , Stephen Berman , 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) --=-=-= Content-Type: text/plain On Thu, 29 Oct 2020 18:06:16 -0700 Stefan Kangas wrote: > Stephen Berman writes: > >> Try the attached patch; does it do what you're suggesting well enough? > > Yes, it looks better. > >> I meant that in some uses of tabulated-list-mode there are columns whose >> default width is so narrow that, when selected for sorting, they are >> immediately truncated (using the patch in my previous post), e.g. the >> "Status" column in list-processes. And the issue is exacerbated with >> the current patch implementing your new suggestion: with its default >> width "Status" is now truncated whether selected or not. > > But the "Status" field in process-menu-mode is 7, so why is it > truncated when there is room? "Status" is only 6 characters. > > I would expect that "Status" was not truncated in this case, IOW that: > > - Without a sorting indicator > - label width <= column width => display it all > - label width > column width => truncate > > - With a sorting indicator > - label width <= column width => display it all > - label width > column width => truncate > > For the last column, we should probably just show it all regardless of > its width, and never truncate. > > Does the above make sense? It seems to. I did experiment a bit with the width when I made the patch just for the selected column and thought the length I used there gave the best results, but maybe that was too cautious. Does this patch give better results (it differs from the previous one only in the lengths checked and used for truncating): --=-=-= Content-Type: text/x-patch Content-Disposition: attachment Content-Description: tabulated-list-init-header patch diff --git a/lisp/emacs-lisp/tabulated-list.el b/lisp/emacs-lisp/tabulated-list.el index b13f609f88..30577679f2 100644 --- a/lisp/emacs-lisp/tabulated-list.el +++ b/lisp/emacs-lisp/tabulated-list.el @@ -269,42 +269,48 @@ tabulated-list-init-header ;; FIXME: Should share code with tabulated-list-print-col! (let ((x (max tabulated-list-padding 0)) (button-props `(help-echo "Click to sort by column" - mouse-face header-line-highlight - keymap ,tabulated-list-sort-button-map)) + mouse-face header-line-highlight + keymap ,tabulated-list-sort-button-map)) + (len (length tabulated-list-format)) (cols nil)) (if display-line-numbers (setq x (+ x (tabulated-list-line-number-width)))) (push (propertize " " 'display `(space :align-to ,x)) cols) - (dotimes (n (length tabulated-list-format)) + (dotimes (n len) (let* ((col (aref tabulated-list-format n)) + (not-last-col (< n (1- len))) (label (nth 0 col)) + (lablen (length label)) + (pname label) (width (nth 1 col)) (props (nthcdr 3 col)) (pad-right (or (plist-get props :pad-right) 1)) (right-align (plist-get props :right-align)) (next-x (+ x pad-right width))) + (when (and (>= lablen 3) (> lablen width) not-last-col) + (setq label (truncate-string-to-width label (- lablen 1) nil nil t))) (push (cond ;; An unsortable column ((not (nth 2 col)) - (propertize label 'tabulated-list-column-name label)) + (propertize label 'tabulated-list-column-name pname)) ;; The selected sort column ((equal (car col) (car tabulated-list-sort-key)) (apply 'propertize - (concat label - (cond - ((> (+ 2 (length label)) width) "") - ((cdr tabulated-list-sort-key) + (concat label + (cond + ((and (< lablen 3) not-last-col) "") + ((cdr tabulated-list-sort-key) (format " %c" tabulated-list-gui-sort-indicator-desc)) - (t (format " %c" + (t (format " %c" tabulated-list-gui-sort-indicator-asc)))) - 'face 'bold - 'tabulated-list-column-name label - button-props)) + 'face 'bold + 'tabulated-list-column-name pname + button-props)) ;; Unselected sortable column. (t (apply 'propertize label - 'tabulated-list-column-name label + 'tabulated-list-column-name pname button-props))) cols) (when right-align --=-=-= Content-Type: text/plain It might be better to take more width parameters into account, as tabulated-list-print-col does, but that seems rather more complicated and I currently don't have time to pursue it. > BTW, perhaps we should add unit tests for all this, since it seems like > we have a fair amount of use-cases to think about. Maybe that could be > a good excuse to make tabulated-list-init-header a bit more functional... For sure (but again, I currently don't have time for that). >> In such cases it may be better to make the default width of such >> columns wider, which is what my first patch did. Then with the >> current patch, it will still be truncated when the column is >> sufficiently narrowed with `{'. > > Yes, the default width of such columns should also be made wider, I > think. But first we should probably make sure that the underlying logic > here is sound. I agree > Thanks again for working on this. I wish I had more time for it but at the moment I don't. Steve Berman --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Fri Oct 30 19:51:30 2020 Received: (at 44068) by debbugs.gnu.org; 30 Oct 2020 23:51:30 +0000 Received: from localhost ([127.0.0.1]:60155 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYeB8-0005bN-Cy for submit@debbugs.gnu.org; Fri, 30 Oct 2020 19:51:30 -0400 Received: from mail-ed1-f54.google.com ([209.85.208.54]:46914) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYeB6-0005b9-Bw for 44068@debbugs.gnu.org; Fri, 30 Oct 2020 19:51:28 -0400 Received: by mail-ed1-f54.google.com with SMTP id t11so8314933edj.13 for <44068@debbugs.gnu.org>; Fri, 30 Oct 2020 16:51:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:in-reply-to:references:mime-version:date:message-id:subject:to :cc; bh=LLRQiTEKbb+pRS5VSXw3X/xQgusIQrOTAr1LY41jci0=; b=unBTWOsBP1XJJrhPdBpairccT+PJFa1aXRfFR8aD6jLWTW2BsYeQt/ORcKTjNY6nEt Da9DkogHf23LWolL0XBwbbszSjBFF8zL3/8heJ1dTPCAXEXbKQBTMPVLOvjXOmZk4Axg BXUp6UVc8M7MNmr3Uhk8/rCAtXa4V1BrT3ROw0sjYI58TFBJ8bgGmxE1tsop8hK5Q6LU nCimXwzS3r8Gi8rH0ib/bS3meg107hSiYUvmGua8U1yMBH5/KR8MTpQR56J1P+KsJqzy aAPEpGcNpCJ48DM2ayk8OoQ+DHEZ0p5+DLlshLXCia//iKgYmsQSeAJ4W0PJX7fIuY4B 5uIw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:in-reply-to:references:mime-version:date :message-id:subject:to:cc; bh=LLRQiTEKbb+pRS5VSXw3X/xQgusIQrOTAr1LY41jci0=; b=Zfh8ox8F8ZKL57gY7HEmC8mvGxQML3FzgV9D+j5upEtYALXxEZi5DUuvG993w+pmOC pb1bfEhBJ/mfKtliZtc0Cpti7BQLlxMfnrT6Hv2mafsHruLx8Uy4qI2wY7IJK1rwA2O6 toDiiJ9r4IDgVyiMU7sxwRbmxLf+np1AeQ753Ri72cWnERQrHHilagpkBtHQhIprNjDI JCf/Mn9rxVbuKGAiUM4OMfOT+11jZv6NmCUr3cbsbhcFwWMAMyUXqukRzhyaF/VfbUd0 K9Lp4smDKPOhr0vofcsU3nY4AVfC+kCb0NH44kodg3Y2Huxkp25BAm9OrWmKqil/CsHy jzbw== X-Gm-Message-State: AOAM530IR+xSqW+DRl9B56j4hNZWOeE+N0+mBz++UYhyxzociuMq2xKn e4IpJl9UF/rEvJ3mtUzBwhT/Fr+VQoVB0S1oh7k= X-Google-Smtp-Source: ABdhPJz77T18YH282+X5oAoyed1hPPCOkxJiHhz+8X+EusNTgAJzfBOghzong/p6BNZ0Q4Jakizd4JsXQWp2NSdFyf8= X-Received: by 2002:aa7:d28c:: with SMTP id w12mr5341620edq.282.1604101882233; Fri, 30 Oct 2020 16:51:22 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Fri, 30 Oct 2020 23:51:21 +0000 From: Stefan Kangas In-Reply-To: <875z6rmlrj.fsf@rub.de> References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> <874kmcfy2h.fsf@rub.de> <875z6rmlrj.fsf@rub.de> MIME-Version: 1.0 Date: Fri, 30 Oct 2020 23:51:21 +0000 Message-ID: Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format To: Stephen Berman Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 44068 Cc: Eli Zaretskii , 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Stephen Berman writes: > It seems to. I did experiment a bit with the width when I made the > patch just for the selected column and thought the length I used there > gave the best results, but maybe that was too cautious. Does this patch > give better results (it differs from the previous one only in the > lengths checked and used for truncating): I think this looks very good, yes. It works fully as I would expect, at least: it seems to always correctly show the sorting indicator and the ellipsis. (I tested using list-buffers, list-bookmarks, list-packages, list-processes, list-dynamic-libraries, org-lint and flymake-diagnostics-buffer-mode.) Perhaps we could just go over the list above as you did in your first patch and make sure that there is enough space for all of these to show a sorting indicator without it touching the next column label. > It might be better to take more width parameters into account, as > tabulated-list-print-col does, but that seems rather more complicated > and I currently don't have time to pursue it. I imagine we can come back to and improve on this later. > I wish I had more time for it but at the moment I don't. What you have here is already a big improvement, thank you. I would recommend to push this to master. From debbugs-submit-bounces@debbugs.gnu.org Sun Nov 01 18:07:49 2020 Received: (at 44068) by debbugs.gnu.org; 1 Nov 2020 23:07:49 +0000 Received: from localhost ([127.0.0.1]:38937 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kZMRx-0000nO-46 for submit@debbugs.gnu.org; Sun, 01 Nov 2020 18:07:49 -0500 Received: from mout.gmx.net ([212.227.17.21]:58087) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kZMRv-0000nB-Ff for 44068@debbugs.gnu.org; Sun, 01 Nov 2020 18:07:48 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1604272060; bh=XypZLqxfHuX57uLDVsQwPrcG015QOahDjQAh6tIkQMM=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=KPpGV+CKSMNKEMqeNaW0hbGu0y/E8UrBKVi2qTszsGu/EmDzMqfYv52IQ1GZVClhS O+6y8pFw9yIQSdfDKoODn7Toz9ytxuJedJV7Jd2RVgiz2WgZJ9/N+pBTKrhdomvoz3 GYGSB9Q6R0l5DB0NoZZwHH6hhqN7OuwVcQuF5wEc= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([188.109.202.128]) by mail.gmx.com (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MTiTt-1kwCmH1K8r-00U5Wk; Mon, 02 Nov 2020 00:07:40 +0100 From: Stephen Berman To: Stefan Kangas Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> <874kmcfy2h.fsf@rub.de> <875z6rmlrj.fsf@rub.de> Date: Mon, 02 Nov 2020 00:07:34 +0100 In-Reply-To: (Stefan Kangas's message of "Fri, 30 Oct 2020 23:51:21 +0000") Message-ID: <87r1pcu155.fsf@rub.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:+QEqC09aS73uRKGworyRvvELEIB0681oucWXlyPU6qe0OqyFDqr knTE0snBkqBEJAqKqk8gciUissSaZk7ANut64EwmMQ7JoSGYdfC/m67E49KX2VcBE4gNhQl HhOugbJroxso30aPTcYi8LlbfcVM54khh/oXsWGzqxllYFsXxI9y4aovkZDgZNKOPdQ7JJ8 MDa0rh335IWY8AShBOvRg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:nXGlxAlXsro=:qXp6qUSQYrHefM3BiZbRHq NLTaQwvXR4FT/q2it/sARfzj4v8VL7pw5K9PC7C01gLSvCT5aufAp0NM7pf9fDwGOSMOJ1fJ5 KBrCOEK12D85n6SmgintTZD4mP9QW9FP2vXhGOYSSqxVzrFFa3xyTXYNWKsGviFNbFNgv1QDG ua+nNcbrRqOjsQ2T5ZIURoB1dlNxCFjunbO+CCHVc9yIA1vF+13LF44MEiDJYip5b6w/uIkeY R09Sy1U16Cq68dJLUQp8IltV/h2QEUCt79bPjrW7DOca6Z94qXC3xiG8AYQaWX6ht+MmFKecL Cvip1/7aocJPdUdgVmgsY3PD+0mcmI3sSwr3ZlUhzesO8qRynt0Z+oeVCC7Si9xNpCaejLvKg PV835MT5JsfRuNnn/TAGXZg2aGfXZUdMqh9k9U6p48ko/I7DrH9BzolmSOHOyYLt8w5UYv8XO HIDWSljshVTEItFZXJ3iPsiFvuW6vns+aOvOpTNV3YKQE5SHREPOwAZFBMMFOyl+C5D0/T/go x2umgFPqlyGXnKXLCJtfh5LUf3s1t9yIkNRnA7WlDovK7w7/m4VdBwpDc0UQIsMbcH6RNgs8S L1AyDlzfo//zng4HcdRknI0y/QAdzQICZz5J6gsWez63fGf3qH3dbro/nXS6HTA33Vp6HL/DX bXeFalUXdfazGjFR/QkjtFIOTSTb0tMpS25B35wvgxFYCxgo6gGShwt69ubs4oZrSYPwFkwvm 7hcoG/Mq86//cP6PHilJN1RAEogp1hQq3gCkHCHNN9yJhb0Ztvqqp28Y9U7UEsvERGXB84jA9 zwEi2x3+s5/nNLMLBpOrajkjhN22NoYrM1JWeH2RCBnxiSBIyEUo6Bugd3WjFk9aEGtsyO9Ww CPJWIJsnyc7hnOXdw3+w== X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44068 Cc: Eli Zaretskii , 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Fri, 30 Oct 2020 23:51:21 +0000 Stefan Kangas wrote: > Stephen Berman writes: > >> It seems to. I did experiment a bit with the width when I made the >> patch just for the selected column and thought the length I used there >> gave the best results, but maybe that was too cautious. Does this patch >> give better results (it differs from the previous one only in the >> lengths checked and used for truncating): > > I think this looks very good, yes. It works fully as I would expect, at > least: it seems to always correctly show the sorting indicator and the > ellipsis. > > (I tested using list-buffers, list-bookmarks, list-packages, > list-processes, list-dynamic-libraries, org-lint and > flymake-diagnostics-buffer-mode.) Thanks for testing. > Perhaps we could just go over the list above as you did in your first > patch and make sure that there is enough space for all of these to show > a sorting indicator without it touching the next column label. I'll try to do that soon, but feel free to beat me to it ;-) As an aside, do you think that use of the :right-align :pad-right properties in timer-list-mode in my first patch is a good change? >> It might be better to take more width parameters into account, as >> tabulated-list-print-col does, but that seems rather more complicated >> and I currently don't have time to pursue it. > > I imagine we can come back to and improve on this later. Sure. >> I wish I had more time for it but at the moment I don't. > > What you have here is already a big improvement, thank you. > > I would recommend to push this to master. Thanks. Eli, is that ok with you? Steve Berman From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 02 12:12:39 2020 Received: (at 44068) by debbugs.gnu.org; 2 Nov 2020 17:12:39 +0000 Received: from localhost ([127.0.0.1]:42453 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kZdNn-0001Z6-9J for submit@debbugs.gnu.org; Mon, 02 Nov 2020 12:12:39 -0500 Received: from eggs.gnu.org ([209.51.188.92]:54322) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kZdNl-0001Ys-6c for 44068@debbugs.gnu.org; Mon, 02 Nov 2020 12:12:37 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:50495) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kZdNf-0006m5-Nm; Mon, 02 Nov 2020 12:12:31 -0500 Received: from [176.228.60.248] (port=3164 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kZdNZ-0008WQ-IW; Mon, 02 Nov 2020 12:12:27 -0500 Date: Mon, 02 Nov 2020 19:12:16 +0200 Message-Id: <83tuu7d6of.fsf@gnu.org> From: Eli Zaretskii To: Stephen Berman In-Reply-To: <87r1pcu155.fsf@rub.de> (message from Stephen Berman on Mon, 02 Nov 2020 00:07:34 +0100) Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> <874kmcfy2h.fsf@rub.de> <875z6rmlrj.fsf@rub.de> <87r1pcu155.fsf@rub.de> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 44068 Cc: stefankangas@gmail.com, 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Stephen Berman > Cc: Eli Zaretskii , 44068@debbugs.gnu.org > Date: Mon, 02 Nov 2020 00:07:34 +0100 > > > What you have here is already a big improvement, thank you. > > > > I would recommend to push this to master. > > Thanks. Eli, is that ok with you? Any reason I might not be okay with it? (I cannot say I've read every message in this thread to the last word.) From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 02 17:38:12 2020 Received: (at 44068) by debbugs.gnu.org; 2 Nov 2020 22:38:12 +0000 Received: from localhost ([127.0.0.1]:42873 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kZiSq-0007Uz-7D for submit@debbugs.gnu.org; Mon, 02 Nov 2020 17:38:12 -0500 Received: from mout.gmx.net ([212.227.15.19]:47831) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kZiSn-0007Ue-ER for 44068@debbugs.gnu.org; Mon, 02 Nov 2020 17:38:10 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1604356683; bh=YxgEV8fLtpKrcB3V8qOmkmG+xYRCBJAU4X/ud4gb3nc=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=kgub8nPzrKD3iOTa89GkO0GqlbyMgXO7I4PmSB4EygXQM1jJ9bUFc4Ggv6iNwUoU1 0InVcbLSvzFAQ24Ft9A44S2M/us4umAMEEbunJjBewFoQO+rKIJF2kP7ULZ9W7AUzx +SINfVBxWh9qjHv6FbKJrLuq6m3ESOgX5cfRcNNI= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([178.9.101.127]) by mail.gmx.com (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MEFvj-1kSKcB3DXB-00AI1j; Mon, 02 Nov 2020 23:38:02 +0100 From: Stephen Berman To: Eli Zaretskii Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> <874kmcfy2h.fsf@rub.de> <875z6rmlrj.fsf@rub.de> <87r1pcu155.fsf@rub.de> <83tuu7d6of.fsf@gnu.org> Date: Mon, 02 Nov 2020 23:37:57 +0100 In-Reply-To: <83tuu7d6of.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 02 Nov 2020 19:12:16 +0200") Message-ID: <87mtzz4c6y.fsf@rub.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:PndaJYfkSAYnzOc19L+qjBwr0vUISF+BuHn4PG/EEJTsu5xAm27 zr8FjSFDqM7dKtv14M3cloUa8miuvR98lQZKa2mUjeKWkTLcoQM3hvNXs4ln1JIboq1KsXB Bii0RwiWv3YWDLyZJe5BVbBq8fBlJOMCUXssgWEYmDHPfzAV6ngM/lC9QTZB2BGU9CvS1Vn VNS0QiujnXUQ7XfHa1OYQ== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:LeQaxIiiAYE=:mI1VERGYDeLX+xjEiXwasx DTL/X0/CkP0Sfpztehb1qPyfKvm5juKlyRkb0U4GqVu3Fph09p7auOczNf71hviJRzO4FGAFG 1yjDrJNyPd+3+69smDYcJFGAYW2eNQWH+YVLSuXFfS2UbteuNiaG/LaU7DqhZ+g+nMBKuCKdI USW/s/EWslT9JhDUETPyQjHRqRQO61Hpuj6ftD4zvr33Nog5bymxO47T7B3/OViu/n0TLzwrl gaG4ghDPcjHKYKk7X9zR4mw5hawygNKXLq//dN26Xrlpe/bQZiCISqU02KzEQdCXxE95ULrlN juAXOVipyoO1KdHus3Lr/kjEVgqX3KlrutFZhidPAqpnwEojsaLDnw40Ir9ByjmzcEfD66WWe IV8qrRHf/1a+qQj+OP0XcYGk5nl++P3/eDPRBlbnOsCmN14NVszd48luM2WeKUIn4AxgFgaPf WesOCS7eJ+6zoBZ3fmHVCa+Ffh5JdN67EDuNr7WGpFq7sRGucaV+kzmVhx6bGsirwdL4dyoa+ JRYOe0qIEx+i3pYlMNCyre98ypUQSURrZsvrR+SFppwQ1YOz35gBq5k6z8PmMoeYMMQbpzZtk 7E1y268rO0h8j20/G1IyPuWr1ShsejAckcY34KLDOWaeYei7B7Qkhvr12vvcOEsvzhnMRLXpW SxW7xdywn4Dr48bFQszaACE304Ak6TR99qBvKmUXHXNHUhFcndHyPcfXRseHcQYwS/lgOZ5Uz wkJKVSbtbq8Njkk8oTqXbTXhUCfEHJ/6ST9fv1+/AuFigCoeViNfXGML5rhCayvQ5uj5u/L66 MI+cTBFRlEiv5ghDyRiMvf9/sjyr66LuuCAd5IrDN6pV1XeygKr03Jg4MbhRTu+Vok9qWDTBN nKnbprWEz6zDuKUpy+rg== Content-Transfer-Encoding: quoted-printable X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44068 Cc: stefankangas@gmail.com, 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Mon, 02 Nov 2020 19:12:16 +0200 Eli Zaretskii wrote: >> From: Stephen Berman >> Cc: Eli Zaretskii , 44068@debbugs.gnu.org >> Date: Mon, 02 Nov 2020 00:07:34 +0100 >> >> > What you have here is already a big improvement, thank you. >> > >> > I would recommend to push this to master. >> >> Thanks. Eli, is that ok with you? > > Any reason I might not be okay with it? I hope not ;-). > (I cannot say I've read every > message in this thread to the last word.) Assuming the patch doesn't introduce a bug, it's essentially a question of aesthetics, and since Stefan K said it looks good to him, that's good enough for me, but since you asked for such a change upthread <83zh4ipbli.fsf@gnu.org>, I wanted to make sure you also accept the result. Steve Berman From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 02 22:27:49 2020 Received: (at 44068) by debbugs.gnu.org; 3 Nov 2020 03:27:49 +0000 Received: from localhost ([127.0.0.1]:43097 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kZmz6-0007xI-PB for submit@debbugs.gnu.org; Mon, 02 Nov 2020 22:27:49 -0500 Received: from eggs.gnu.org ([209.51.188.92]:54926) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kZmz4-0007x6-ET for 44068@debbugs.gnu.org; Mon, 02 Nov 2020 22:27:47 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:35674) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kZmyy-0004CM-RP; Mon, 02 Nov 2020 22:27:40 -0500 Received: from [176.228.60.248] (port=1578 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kZmyw-0002Vf-Sl; Mon, 02 Nov 2020 22:27:39 -0500 Date: Tue, 03 Nov 2020 05:27:30 +0200 Message-Id: <83imance71.fsf@gnu.org> From: Eli Zaretskii To: Stephen Berman In-Reply-To: <87mtzz4c6y.fsf@rub.de> (message from Stephen Berman on Mon, 02 Nov 2020 23:37:57 +0100) Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> <874kmcfy2h.fsf@rub.de> <875z6rmlrj.fsf@rub.de> <87r1pcu155.fsf@rub.de> <83tuu7d6of.fsf@gnu.org> <87mtzz4c6y.fsf@rub.de> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 44068 Cc: stefankangas@gmail.com, 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Stephen Berman > Cc: stefankangas@gmail.com, 44068@debbugs.gnu.org > Date: Mon, 02 Nov 2020 23:37:57 +0100 > > >> Thanks. Eli, is that ok with you? > > > > Any reason I might not be okay with it? > > I hope not ;-). > > > (I cannot say I've read every > > message in this thread to the last word.) > > Assuming the patch doesn't introduce a bug, it's essentially a question > of aesthetics, and since Stefan K said it looks good to him, that's good > enough for me, but since you asked for such a change upthread > <83zh4ipbli.fsf@gnu.org>, I wanted to make sure you also accept the > result. Can you describe the result? I don't think I have a clear idea what it will be. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Tue Nov 03 18:12:48 2020 Received: (at 44068) by debbugs.gnu.org; 3 Nov 2020 23:12:48 +0000 Received: from localhost ([127.0.0.1]:46767 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ka5Tr-0004rF-Pl for submit@debbugs.gnu.org; Tue, 03 Nov 2020 18:12:48 -0500 Received: from mout.gmx.net ([212.227.17.20]:36607) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ka5Tp-0004qy-Sa for 44068@debbugs.gnu.org; Tue, 03 Nov 2020 18:12:46 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1604445159; bh=9hpm+JZtqFs4sG/rlnJ/LwulaYV/Q0VK7/nhUFlh8Ig=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=IYYIIrSBUkrLMgD7kxwdFl4yzaJVX0URKl/Hm3KiCdj60ycYyMF93i85Zm8bY1v5+ zLfb2uk+LOjzfWXwb7Hc0+ZdVgaAon2Z/mQqBoQkvCHsxDvaI+tsE8mZwXqVTJIht3 I0YMRYT2LjhkhUCPgmV0zlhXeXRu1hzt2J2uLGzU= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([178.9.102.254]) by mail.gmx.com (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MCsQ4-1kRFm23bRQ-008q3x; Wed, 04 Nov 2020 00:12:38 +0100 From: Stephen Berman To: Eli Zaretskii Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> <874kmcfy2h.fsf@rub.de> <875z6rmlrj.fsf@rub.de> <87r1pcu155.fsf@rub.de> <83tuu7d6of.fsf@gnu.org> <87mtzz4c6y.fsf@rub.de> <83imance71.fsf@gnu.org> Date: Wed, 04 Nov 2020 00:12:31 +0100 In-Reply-To: <83imance71.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 03 Nov 2020 05:27:30 +0200") Message-ID: <87blge11cw.fsf@rub.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:1T7gNj5UBxwtHM+XBIqlU2qyzUl4jFiF/qbsW8iq+R3mCuFUN4x zzc1F9Dbc+Pejf8GXiJD9Bn+GlliAAJzxXwzazJzk7K3AZ6eS2bgE1cBLiv4v+G3cpuOKKC 4OfgQ3prT2+QjhdbQHTxpWW9LMpTGQ698TZ1RXJ42eRqUw1kNskWfx9z2sEE2zhhhBoIV7w +RCtEeD9lSaswTnu+SCbQ== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:ot0811rfaT8=:L9Me5Q5HNA2FBAvwGJHvf3 dPfX1gdhrexrBv+1XqYuhV2vl7FiIM+jaxm0TyciFJ2hGdcWaHO0/tK9dMkomzvaWpQYBja9l 7SfIhodolVOdMp8YGUrcGuECtENyVVdRxqz2BQdorBmtr3h8qbpEOSt5Pf3MdVcfPRMNnVr5+ +t+rI8Vdm9QQ+3xYoisL/vEr4EZ+g7n+kSpdI768NrmmF6a24ni0QHAM94KxLnR56mMccqD1n DfigkitRbWlh/EJg4Vj7UtJOjUxn0SUeTraJ9Fxq9jAWNwlLIEYGqVrBI765fTQdz9hW56SUL kLQeyYWKCwWOpXbECowWnzpNjleqJLD5UFUt3PeP3ZwOaMIkWm+KVFiArDl472hSJnjctxQSE s7NUOOpciO7mf8G5CxUxTax3EZysSpK1R3QCnBEE+tItL9SdqST/PR08REVLpf8ih6mtiOphH V4qAGBB4paC7zFXK6o6dD4TYMDZuF0RWYD/C5knCiKUldtRbkV5W8at4jTCybkcLi9BOzVPZG NCd8n92CmTgPZXkqTbdWcK1FzZAI+BtxeSjxDChUA7Mk8G8Y1d/yjh9jzZ1laUqEfAbZxXv70 Qz3hicihCks7K99oWO/LGmyEIm1cxizSOgxq6+xDer7CItN8LhjjB6+xszXMZTHZ5qRHkHshx WaW+Dn6kCbctoB5oyc/g+0J3P3phiUwgdD+ZCb2Y8ACdu0rT4A5zfKN17pQAFCq7aQD+lnmpE BKFzKDot+E/u/dwxd4hNCjuvwT2NbDLKS4G9kqhyZuNVMgLnA5iE/jhAd1tExxKnrnYA45XMR ZcbFnHaBEAqhb/PzHmMwJHNenY52rXDqlTOUeH2BzV9R3gtR+wtxWi3khDDGdo0S0KX2JW/Rt i1uO/PhWf681mgQ2PSaQ== X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: 44068 Cc: stefankangas@gmail.com, 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Tue, 03 Nov 2020 05:27:30 +0200 Eli Zaretskii wrote: >> From: Stephen Berman >> Cc: stefankangas@gmail.com, 44068@debbugs.gnu.org >> Date: Mon, 02 Nov 2020 23:37:57 +0100 [...] >> Assuming the patch doesn't introduce a bug, it's essentially a question >> of aesthetics, and since Stefan K said it looks good to him, that's good >> enough for me, but since you asked for such a change upthread >> <83zh4ipbli.fsf@gnu.org>, I wanted to make sure you also accept the >> result. > > Can you describe the result? I don't think I have a clear idea what > it will be. There are two features the patch provides: - All sortable columns in tabulated-list-mode derivatives that are wide enough to display a sort indicator when selected do so (sortable columns that are not wide enough include e.g. the first three in the Buffer-menu-mode table). In contrast, currently, i.e. without the patch, all final sortable columns and some non-final ones that are wide enough do not display the sort indicator when selected. - When a column (whether selected or not) is made narrower (by repeatedly typing `{') than the length of the column label in the header line, the label is truncated and displays a trailing ellipis, just like the data lines of such columns in the table (if such a narrowed column is sortable and selected, the the sort indicator is still displayed after the ellipis). In contrast, currently, the column labels are not truncated, which can lead to misalignment between the header line and the data lines. (However, even with the patch, misalignment can happen, because the data lines can be truncated to display nothing but the ellipis, while the header line labels always show at least the first letter of the label. I think the display of the data lines here is questionable, but dealing with that is another issue.) Steve Berman From debbugs-submit-bounces@debbugs.gnu.org Wed Nov 04 07:02:13 2020 Received: (at 44068) by debbugs.gnu.org; 4 Nov 2020 12:02:13 +0000 Received: from localhost ([127.0.0.1]:47750 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaHUS-0003dP-RN for submit@debbugs.gnu.org; Wed, 04 Nov 2020 07:02:12 -0500 Received: from mail-ed1-f51.google.com ([209.85.208.51]:36616) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaHUR-0003dD-3w for 44068@debbugs.gnu.org; Wed, 04 Nov 2020 07:02:11 -0500 Received: by mail-ed1-f51.google.com with SMTP id o20so4063196eds.3 for <44068@debbugs.gnu.org>; Wed, 04 Nov 2020 04:02:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:in-reply-to:references:mime-version:date:message-id:subject:to :cc; bh=G6lwyUlXfPiPqOc4DibN6cXgjDZvTx+mkUmKm/3Lelk=; b=nZ+roDc8m8AD7iqUkCNP0eH2LAq0n0h3egCETrKqm6HYzNLRdyxbrqqukWyRni1jDf kiXn9B0WFuWsS3AwpvQN7eykU6VoLpXayw5S/a9fNdHZyxImATnYajojIqpJmELquzLn FkMQ/Xwt+fnqtfCdyTOQXRdEZzBozdb7sXQ6KrIXD/dcv+qpIveETjYufiAePdI3e4xs cJv9PLMJYro6t5JZn9b5jwprV6caSRcCMAyQ4sp4E38R6YUxKZHa61hjawX4wejAHgfq C1iz//fBi/Nr/4pMAtfrZ83WxistLg/yjeI9aKxunD7os19++hQiPDzIaMTuKlnvjq4x ttvg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:in-reply-to:references:mime-version:date :message-id:subject:to:cc; bh=G6lwyUlXfPiPqOc4DibN6cXgjDZvTx+mkUmKm/3Lelk=; b=MflShUQCx7l4Iq0w/BzGhr8K1+TgWqhl2Dv1xqUdinY7E3wWnzAyLurIFwQHs9Xog6 q33m0kcmV7lWyts5tWS08fkn5KxjvZ6dhClNQLBTX0a2kJyV/48kctYNfeb7LH2HkBze E0hmQMAGIRYbEKp+FCVe6nub64msX++CVhNEQxGXKexZtJYWwngdvjJ8JLYV1pye8rlE t5lPz5Z//i/lacb8PnRvny5VlqakVuwgSYEDQ5UD7mZ96Euf/fxCrIv49N0hLA7M2kV3 jh28zACNg387YkjE8ygnTyrzzz9MddRKyYar8E3y4e/RTW+hiBkdSF57sPJaZdpedgG6 +U/A== X-Gm-Message-State: AOAM530nJAhzOMMDzPnkPzIcjTdiLu3JfRXj+dqM07mXkwoqtlvJpHiv taV4QLmHUzYHigaLwQecxfc/G8KwrQslGPmDZwQ= X-Google-Smtp-Source: ABdhPJzi5RDDzP+f5nQywc1WJAQW/adlhkX6+d7s0jNBYgY9d0k6bfGfIZ7O0Wjzo1/oFjLbSG/CtjwuAYMGopPmzE8= X-Received: by 2002:a50:e443:: with SMTP id e3mr2733608edm.160.1604491325179; Wed, 04 Nov 2020 04:02:05 -0800 (PST) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Wed, 4 Nov 2020 04:02:04 -0800 From: Stefan Kangas In-Reply-To: <87r1pcu155.fsf@rub.de> References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> <874kmcfy2h.fsf@rub.de> <875z6rmlrj.fsf@rub.de> <87r1pcu155.fsf@rub.de> MIME-Version: 1.0 Date: Wed, 4 Nov 2020 04:02:04 -0800 Message-ID: Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format To: Stephen Berman Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 44068 Cc: Eli Zaretskii , 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Stephen Berman writes: > As an aside, do you think that use of the :right-align :pad-right > properties in timer-list-mode in my first patch is a good change? Do you mean this part? - (" Next" 12 timer-list--next-predicate) - (" Repeat" 11 timer-list--repeat-predicate) + ("Next" 12 timer-list--next-predicate :right-align t :pad-right 1) + ("Repeat" 11 timer-list--repeat-predicate :right-align t :pad-right 1) If so, it definitely looks like an improvement to me. Do you see any problems with it? BTW, does it work better with narrowing the column, too? We seem to have some issues with that currently. From debbugs-submit-bounces@debbugs.gnu.org Wed Nov 04 07:29:48 2020 Received: (at control) by debbugs.gnu.org; 4 Nov 2020 12:29:49 +0000 Received: from localhost ([127.0.0.1]:47774 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaHvA-0004KP-OX for submit@debbugs.gnu.org; Wed, 04 Nov 2020 07:29:48 -0500 Received: from mail-ed1-f48.google.com ([209.85.208.48]:42160) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaHv9-0004K5-BB for control@debbugs.gnu.org; Wed, 04 Nov 2020 07:29:47 -0500 Received: by mail-ed1-f48.google.com with SMTP id a71so16875112edf.9 for ; Wed, 04 Nov 2020 04:29:47 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:mime-version:date:message-id:subject:to; bh=2RU3Hhl4Gwc7ZX+/hWl4kGUOxM5GV6Mm1nT6c5JNF3w=; b=moMfCdWVxdRgO9dDAjwNP5UxUcdjzuaBD3aTEF28BaW5AiyFGQd/0Re4Bp9MGvT8bc Sh7aoaDEsc2vk54Wu7i4xB+hl67QxtqSg5eLwyDD3SK11QVTkDR46XIRqWfkg3sgBSUC 9D/GL8Guiw2ijn6BioHtUwYlR65Sqd7HAl807f37z5bPqhPIwpO8Olpd7oGnQ65bi0xH VE7vhi4iYulqqbIV/NiS3cT5P40baa9xer1Lzin8fu/fpPGMsWWg8pVMi3bZv+bsG/9d /p86BSv4wM8Ot76qzf9SqB8jDatpqzQHLEI0IwiXFqFCl1lRyjsh3vAcnlk5cp5+QWHN 1DSw== X-Gm-Message-State: AOAM531Mgd9UqkZ5GNpQ03/Wnrv7Qxc7JldzwOjPjSDKbWmj3xVyLCXD vs93zm8DCqUzfS4oGtXplkMXIHjxyo/LX8OTy4X1OlVR X-Google-Smtp-Source: ABdhPJyuTFKRDnfURa+3tX8D4HV4o4zlkYWB81FYh4zFg0Om9Bh/1EOiNw+ZTe/5tExDGepBwpItz6fu7wXqPUM13kI= X-Received: by 2002:aa7:d888:: with SMTP id u8mr26011490edq.210.1604492981112; Wed, 04 Nov 2020 04:29:41 -0800 (PST) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Wed, 4 Nov 2020 04:29:40 -0800 From: Stefan Kangas MIME-Version: 1.0 Date: Wed, 4 Nov 2020 04:29:40 -0800 Message-ID: Subject: merge 41861 44068 To: control@debbugs.gnu.org Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.5 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.5 (/) severity 44068 minor merge 41861 44068 thanks From debbugs-submit-bounces@debbugs.gnu.org Wed Nov 04 10:09:42 2020 Received: (at 44068) by debbugs.gnu.org; 4 Nov 2020 15:09:43 +0000 Received: from localhost ([127.0.0.1]:50249 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaKPu-0000ae-J6 for submit@debbugs.gnu.org; Wed, 04 Nov 2020 10:09:42 -0500 Received: from eggs.gnu.org ([209.51.188.92]:57042) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaKPs-0000aS-Ng for 44068@debbugs.gnu.org; Wed, 04 Nov 2020 10:09:41 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:41126) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kaKPn-0006om-FL; Wed, 04 Nov 2020 10:09:35 -0500 Received: from [176.228.60.248] (port=2210 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kaKPm-0006Of-VW; Wed, 04 Nov 2020 10:09:35 -0500 Date: Wed, 04 Nov 2020 17:09:30 +0200 Message-Id: <83sg9pb1lh.fsf@gnu.org> From: Eli Zaretskii To: Stephen Berman In-Reply-To: <87blge11cw.fsf@rub.de> (message from Stephen Berman on Wed, 04 Nov 2020 00:12:31 +0100) Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> <874kmcfy2h.fsf@rub.de> <875z6rmlrj.fsf@rub.de> <87r1pcu155.fsf@rub.de> <83tuu7d6of.fsf@gnu.org> <87mtzz4c6y.fsf@rub.de> <83imance71.fsf@gnu.org> <87blge11cw.fsf@rub.de> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 44068 Cc: stefankangas@gmail.com, 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Stephen Berman > Cc: stefankangas@gmail.com, 44068@debbugs.gnu.org > Date: Wed, 04 Nov 2020 00:12:31 +0100 > > > Can you describe the result? I don't think I have a clear idea what > > it will be. > > There are two features the patch provides: > > - All sortable columns in tabulated-list-mode derivatives that are wide > enough to display a sort indicator when selected do so (sortable > columns that are not wide enough include e.g. the first three in the > Buffer-menu-mode table). In contrast, currently, i.e. without the > patch, all final sortable columns and some non-final ones that are > wide enough do not display the sort indicator when selected. > > - When a column (whether selected or not) is made narrower (by > repeatedly typing `{') than the length of the column label in the > header line, the label is truncated and displays a trailing ellipis, > just like the data lines of such columns in the table (if such a > narrowed column is sortable and selected, the the sort indicator is > still displayed after the ellipis). In contrast, currently, the > column labels are not truncated, which can lead to misalignment > between the header line and the data lines. (However, even with the > patch, misalignment can happen, because the data lines can be > truncated to display nothing but the ellipis, while the header line > labels always show at least the first letter of the label. I think > the display of the data lines here is questionable, but dealing with > that is another issue.) Sound like good improvements, thanks. From debbugs-submit-bounces@debbugs.gnu.org Wed Nov 04 17:54:12 2020 Received: (at 44068) by debbugs.gnu.org; 4 Nov 2020 22:54:12 +0000 Received: from localhost ([127.0.0.1]:50937 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaRfQ-0001mM-Em for submit@debbugs.gnu.org; Wed, 04 Nov 2020 17:54:12 -0500 Received: from mout.gmx.net ([212.227.17.22]:43753) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaRfP-0001mA-1l for 44068@debbugs.gnu.org; Wed, 04 Nov 2020 17:54:11 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1604530444; bh=+YyC70a87Q7sv9RIzEwZzIkiSNLoClHm+jIyDkk4eT4=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=DXgkFY639xDMDaAEqDdXz7iHX7RR6bRAXetuUtlTljZVOSESE5maQWDpKI1DbZnpv OL/JrQT0+5kYehKn5+41gYd8LtMP+Yzlg58IMFcOfJnFJhI1Fo1BUrKWo8osCcYLRZ OHi12ZB19cluTk6Eh70wvcb9CVMpZs3i6eKcMKDw= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([178.1.124.54]) by mail.gmx.com (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MmlTC-1jt6lu002g-00jp3X; Wed, 04 Nov 2020 23:54:04 +0100 From: Stephen Berman To: Stefan Kangas Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> <874kmcfy2h.fsf@rub.de> <875z6rmlrj.fsf@rub.de> <87r1pcu155.fsf@rub.de> Date: Wed, 04 Nov 2020 23:53:56 +0100 In-Reply-To: (Stefan Kangas's message of "Wed, 4 Nov 2020 04:02:04 -0800") Message-ID: <871rh8vim3.fsf@gmx.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:wUzCUujWjgr2hZzOH7JQRq6W+ujJJOqUKBc81op4dMOOc4Blh11 jVeYYasbdoR+U5eVkAkwpHdllQYIVfNPv0nidxVzuSmQAxPDvDtnfuwyqYKsDf449e3ThNQ gPTDpHy5vd9F0v/mVDBFPDWE3HZIx3KacLu2xTmeKvnH5kmR80jSDm6Yti2Re9gR0fdV4SN Z/J9C8NL1fUMnIsB+3Itg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:1njK0l6of08=:kPZfOytXX6AeB7Gp5P4uLo EbDjb6mjzbuvNwt5uQqSPVvibmVtCW9EMFOWXY8fwwKIS/DmGfGAfFAH2FcSclfiezuF9SD4e 2z43rUAMfaIN5xaV83DQtsmHTnypW3ObLB7VL0LPBNzoNWLGfyu1yb52VaQlxPK21mQUrjP3d VS/+ZoaiupugECnSIOTidPoWlsDa9NzuL0qeKMEOJ/VpBkje7E1uG/kYBK6OdEThjI8E9wNXJ zMXH2RXkgjO4CnKkjOgI4sKG8NZeVYSTKURf/DFDmHXz7CA29ISyZ9yD0eJDVsMdzqwEP+Z5F KbggtGoUdefcjE+xHOqCSPCIcwdZlBVgVsBCutyof/RGgbmdzOyyJgGOkz1W85gJy9SxTMJtF 0g6UlyyqVeMgI6kByybAq5SKESv9C7fJ3IBcQmdRyhGIOoG8Y2ulLlgwcuoTpnylzA+1TJ5dT QXFEWbqpEbGCOJQiYxq81cBDI+mF9UJOgj2JPzCMXWYR87COzAE/ABhb8jYHnEgOWhxm/2Vim aY8AGGUDaF/VgXVmPx7qRAicXMlbD1XDEtuRRj2JLgOyYZgEPo+Z7ZbO6k7WGsZFTIsgbDe5S vapx8pu6JMmzTQAbQAsOp5P1LWHpWTfB3/AHq4TJpCYlBJCdoNzKb2cOimZzc2uQ3IPLFxkUP w3ZQdNdjidu1JsZu1P7s4iFMalLq+ZZrvjmzMnM45iAc4uOK8KjpaIVq2ASQHqJs2ELcyfYYI kHHwuKmbLEz3aCAWQpvErLi/mHxzUczHIX8VmCUW7iLfGSxEvfI8aQYgQMlbp7jJIg78vjTAF fmp+Ban/MZlZTTFkAi18WaWiM1zs7ZHyp0YY6/wntlHrPyuAzi+zVVeaN5h1w6rYwjqQi8m1V btaoJ1xMRQBpdkkbI89Q== X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44068 Cc: Eli Zaretskii , 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Wed, 4 Nov 2020 04:02:04 -0800 Stefan Kangas wrote: > Stephen Berman writes: > >> As an aside, do you think that use of the :right-align :pad-right >> properties in timer-list-mode in my first patch is a good change? > > Do you mean this part? > > - (" Next" 12 timer-list--next-predicate) > - (" Repeat" 11 timer-list--repeat-predicate) > + ("Next" 12 timer-list--next-predicate :right-align t :pad-right 1) > + ("Repeat" 11 timer-list--repeat-predicate :right-align t > :pad-right 1) > > If so, it definitely looks like an improvement to me. Do you see any > problems with it? No, and in fact without it the tabulated-list-init-header patch makes selecting "Repeat" column (and hence displaying the sort indicator there) push the "Function" column label to the right, causing misalignment with the data lines; with the properties this does not happen. (However, the width of 11 makes the data lines of the "Repeat" column appear truncated, but this width was changed to 12 in commit 0cb44eed6, fixing that problem.) > BTW, does it work better with narrowing the column, too? We seem to > have some issues with that currently. Do you mean that truncation happens even though there is still enough space to display the data or header? I see that both with hard spaces and with the :right-align property. I haven't tried to figure out why that's happening, but seems to be separate from above change. Given that, and also Eli's approval of the tabulated-list-init-header patch, I've gone ahead and committed these changes. I didn't make any of the column width changes I proposed in my first patch, since with the tabulated-list-init-header patch they don't seem to be needed. Nevertheless, there's clearly still room for improvement, in particular concerning truncation (I also hinted at another problem with this in my last reply to Eli). Steve Berman From debbugs-submit-bounces@debbugs.gnu.org Wed Nov 04 17:55:28 2020 Received: (at 44068) by debbugs.gnu.org; 4 Nov 2020 22:55:28 +0000 Received: from localhost ([127.0.0.1]:50941 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaRgd-0001oO-Qo for submit@debbugs.gnu.org; Wed, 04 Nov 2020 17:55:28 -0500 Received: from mout.gmx.net ([212.227.17.21]:54127) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kaRgb-0001oA-Ls for 44068@debbugs.gnu.org; Wed, 04 Nov 2020 17:55:26 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1604530519; bh=3ge3n+9rfI54qgicCYb3V5stXD7WIVtQLa/pxsbRzow=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=bJ3SDYXLisIVw/1mytXqViPypCBkkYArNkwyeBwRojpOQVy0StCXx1vcJW2YwGLHE Ve4T/OGJve7Sdf4FAEfRQBRqLcn93P66WTyYhyFZaNt2A6lkYPqR3BOmjhOjC42SU9 bS4iZ0bK4ccKBG+d4jnj0G1bmEQCb7VButP7xCNo= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([178.1.124.54]) by mail.gmx.com (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MgNct-1k8G081eKl-00hvFf; Wed, 04 Nov 2020 23:55:19 +0100 From: Stephen Berman To: Eli Zaretskii Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> <874kmcfy2h.fsf@rub.de> <875z6rmlrj.fsf@rub.de> <87r1pcu155.fsf@rub.de> <83tuu7d6of.fsf@gnu.org> <87mtzz4c6y.fsf@rub.de> <83imance71.fsf@gnu.org> <87blge11cw.fsf@rub.de> <83sg9pb1lh.fsf@gnu.org> Date: Wed, 04 Nov 2020 23:55:12 +0100 In-Reply-To: <83sg9pb1lh.fsf@gnu.org> (Eli Zaretskii's message of "Wed, 04 Nov 2020 17:09:30 +0200") Message-ID: <87wnz0u3zj.fsf@gmx.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:OCFgafOIdZZRchuPI1Ehsmg9T7G5J68no4E6Snx/LA448bQXEuF km7gch8ws6OuXZ6nKLebab7TfEZQf4O0h5TXHp637inBylN4EEY1b1m7mjKNlBe19PlF3Aa akjGLP4Xu+DWzcCueA8y8geMcft8k2L++yrdmurhBlOqvTB5se5rRlX+Qdp/rfpuYTx2cUn cEcY0H/ULOUNC5VPschMg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:PuvAmzQZWLo=:abgCxZGdfUFAT+EkZSn6Ii mKCGU6J6kPi+OOuSceojnYX1ECIMG38vkL6AmJaYNyHJB5GCSylYyxLFkYt2QAOWP/i8chZ5h YQoguBNP+Edk70WddsKX5fu+ygcGOjPa2aEl7hTLKiC7wTHGcVbu6Kw/UrkXfJuD7/iGyAGAZ c5EjnA8pZ5qm3wQolnSlAfxCURa98fcnfyU6tbiyCgJ3/4I1bD3d9yVfMOjgl2WgASN9G/USa 6ieHlo5dA1gAYT1KaY1wXqH0iuEKYsT07J7i3PluUT4Gk5HFeKHLD6pkTQ9uouRc3lYO6LbqK LOXoLcXsZKVycsc4JHW1XTZp9VpDaytB8LjqLrX7crYSWMFDgs4b3pmAj2CP0bMJfwdZdRsxA vdKT4hfLoKYXjmt5MeDBY384++WbxyJFjRuow8849xGXdT6bKuLXXkVLhAe/PikVsfPcSIkMN /Fxubgpi762MmQDkb0PPpvEan5q8eF8hA7VO+PhETuJTdC64KawUqdtrQPKi0zlC2H6TQECN6 LbsRxOhvZVFQwCFOfumuJYC4ztBg800x0AokYMIX7zXAvcfmlo7O54TkJxaiJfeWvFJG+d/w/ DwKvC7iyk65a0rD6SNTRpz9LkpfOueVXMc2QU2Xqs4hKXDV2lTam0NByye32C7qOmch88ba6P T17L6bKuZfI8302pilgoRjbZTz2Zcgayg3L2Ahxnstdqey57tRDxRLng0AhHanA8fPWESa+zs Wdk25f93t/CooaLGF1Al4ClyZcgeoUI0FDtugee+4csSmOqn3f99wol7U7zJfNtds65zBOgO9 dCx0d71f7mBK+32voaN2Yz2EJ+SI2miBRRUdVW2rqf8HHQPwVASIogoIt/FHLl0fF3iWcKCZY u4WNXcfbARg4UVQoldzQ== Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: 44068 Cc: stefankangas@gmail.com, 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Wed, 04 Nov 2020 17:09:30 +0200 Eli Zaretskii wrote: >> From: Stephen Berman >> Cc: stefankangas@gmail.com, 44068@debbugs.gnu.org >> Date: Wed, 04 Nov 2020 00:12:31 +0100 >> >> > Can you describe the result? I don't think I have a clear idea what >> > it will be. >> >> There are two features the patch provides: >> >> - All sortable columns in tabulated-list-mode derivatives that are wide >> enough to display a sort indicator when selected do so (sortable >> columns that are not wide enough include e.g. the first three in the >> Buffer-menu-mode table). In contrast, currently, i.e. without the >> patch, all final sortable columns and some non-final ones that are >> wide enough do not display the sort indicator when selected. >> >> - When a column (whether selected or not) is made narrower (by >> repeatedly typing `{') than the length of the column label in the >> header line, the label is truncated and displays a trailing ellipis, >> just like the data lines of such columns in the table (if such a >> narrowed column is sortable and selected, the the sort indicator is >> still displayed after the ellipis). In contrast, currently, the >> column labels are not truncated, which can lead to misalignment >> between the header line and the data lines. (However, even with the >> patch, misalignment can happen, because the data lines can be >> truncated to display nothing but the ellipis, while the header line >> labels always show at least the first letter of the label. I think >> the display of the data lines here is questionable, but dealing with >> that is another issue.) > > Sound like good improvements, thanks. Thanks, I've pushed it to master in commit 233d350d19. Steve Berman From debbugs-submit-bounces@debbugs.gnu.org Thu Nov 12 11:38:15 2020 Received: (at 44068) by debbugs.gnu.org; 12 Nov 2020 16:38:16 +0000 Received: from localhost ([127.0.0.1]:45451 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kdFbz-0007uP-NI for submit@debbugs.gnu.org; Thu, 12 Nov 2020 11:38:15 -0500 Received: from mail-ed1-f44.google.com ([209.85.208.44]:34662) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kdFbv-0007u9-CT for 44068@debbugs.gnu.org; Thu, 12 Nov 2020 11:38:13 -0500 Received: by mail-ed1-f44.google.com with SMTP id a15so7052926edy.1 for <44068@debbugs.gnu.org>; Thu, 12 Nov 2020 08:38:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:in-reply-to:references:mime-version:date:message-id:subject:to :cc; bh=Lign8PRXjpNz/EVek7qdyh5kQGnAsU5iAm6LV4T8k04=; b=IhqC+M09IPAhL9vn6R7bB3NTU8OlnC8i/YSTn5nbG51A0cC3wOsg4KYLO+fhDhvM2K K5QajPiofb+JDnhVLE4HXguLtelbOqazoY4rFtzsbESNHyH/UoryXmTLrJH3dQ1hCFvd FEhQzU/6xPIZA0V7xpioejf0Ke65VfxS6tVlf8P+4Sbd+1Gb7amVcuMLTs5dfA1kJK7c 4QOnnYS4zLgqDhfi3tUq1H0j8codjeqORDhGaBHDvNuKMPbJ3fJf/CJghY4tZaYEZ4KJ 9BpYs81fYV+Xn1XsjXeKBMnRxJ5T1Pd2ZAAGIHT2Udu/S82Y//r0q8vSg0xWYmDpYoFb zsnA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:in-reply-to:references:mime-version:date :message-id:subject:to:cc; bh=Lign8PRXjpNz/EVek7qdyh5kQGnAsU5iAm6LV4T8k04=; b=gRbna+5sPeVsEXqv19GdkiLhijXLLio12rBsYWHEHCg7rcqAo+WzbfRgLjwTPTqwoW SIecVukFLZGIN7EsUBoM6iKyDZ2HWVtxV8vPoH8yQa/xPwE61DaonGvcMy2/WjMIRq5Z 4kRv4fF+zLSd6pRMzOVVBYduTaV5bZJl6IGAUa4lwNkdKWIVvJ50VTCFQiyMCik+lRKJ G1eIIIDzDgDmaSFia3PWm+46u0bR6BPZv3LmmVkiux6pNNXsve9vuhAGSsJYzrear34P bpDSylkZxIM8mCb3DaFN6huABdgQfrrmZNtL6xk3u7aA9Jk12u7snQP67pHCyxkx2v6u biCw== X-Gm-Message-State: AOAM530jhgRqC8LeaSe7EaDsE5sRq+La0hrZ+jWe19QqMvTXSConaTR2 GqmAwhJJf/YGpGNfrRWLK8llEE2LAeOr55P/Lfw= X-Google-Smtp-Source: ABdhPJz4d72jSIwe0f+NIy02OpnSgUAZomb8bDP7ka9AUVlhrdza3alxz32x908Nda9kDtsCEkjngo7CCn1VgSilWBU= X-Received: by 2002:a05:6402:716:: with SMTP id w22mr678425edx.214.1605199085357; Thu, 12 Nov 2020 08:38:05 -0800 (PST) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Thu, 12 Nov 2020 11:38:04 -0500 From: Stefan Kangas In-Reply-To: <871rh8vim3.fsf@gmx.net> References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> <874kmcfy2h.fsf@rub.de> <875z6rmlrj.fsf@rub.de> <87r1pcu155.fsf@rub.de> <871rh8vim3.fsf@gmx.net> MIME-Version: 1.0 Date: Thu, 12 Nov 2020 11:38:04 -0500 Message-ID: Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format To: Stephen Berman Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 44068 Cc: Eli Zaretskii , 44068@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Stephen Berman writes: >> BTW, does it work better with narrowing the column, too? We seem to >> have some issues with that currently. > > Do you mean that truncation happens even though there is still enough > space to display the data or header? I see that both with hard spaces > and with the :right-align property. I haven't tried to figure out why > that's happening, but seems to be separate from above change. Indeed, it is a separate issue. I have opened Bug#44594 to track it. > Given that, and also Eli's approval of the tabulated-list-init-header > patch, I've gone ahead and committed these changes. I didn't make any > of the column width changes I proposed in my first patch, since with the > tabulated-list-init-header patch they don't seem to be needed. Thank you! I guess this bug should therefore be closed as fixed? From debbugs-submit-bounces@debbugs.gnu.org Thu Nov 12 17:52:03 2020 Received: (at 44068-done) by debbugs.gnu.org; 12 Nov 2020 22:52:03 +0000 Received: from localhost ([127.0.0.1]:45939 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kdLRj-0002BX-LC for submit@debbugs.gnu.org; Thu, 12 Nov 2020 17:52:03 -0500 Received: from mout.gmx.net ([212.227.17.22]:49127) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kdLRg-0002B0-6P for 44068-done@debbugs.gnu.org; Thu, 12 Nov 2020 17:52:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1605221513; bh=vtLtYlighRSmXOzUUY/cSOw8Sf85ru0p9LmjOUVPHvg=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=Z+nHeWfqZdUQKJfKiebkALcrAFWe6fTLERUf/m8ZJV68TClHlDvVVFOlr7U+R80/q DhjIDOIHWT7ezmNqxsnLmqFQwgxUA8hj8DHPbutR+KEqKbruTNV7Sg81buwE0ai63J U0cx4gpkta/OKLLcFTjn+EuGaFgFU2De9U3fasTU= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from strobe-jhalfs ([188.101.169.177]) by mail.gmx.com (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1McH9Y-1k0hEq3wFQ-00cgQk; Thu, 12 Nov 2020 23:51:53 +0100 From: Stephen Berman To: Stefan Kangas Subject: Re: bug#44068: 28.0.50; Faulty uses of tabulated-list-format References: <87imb7e242.fsf@gmx.net> <83zh4ipbli.fsf@gnu.org> <877drm13j3.fsf@gmx.net> <831rhuoy36.fsf@gnu.org> <87y2k2yqqb.fsf@gmx.net> <87h7qori97.fsf@gmx.net> <874kmcfy2h.fsf@rub.de> <875z6rmlrj.fsf@rub.de> <87r1pcu155.fsf@rub.de> <871rh8vim3.fsf@gmx.net> Date: Thu, 12 Nov 2020 23:51:40 +0100 In-Reply-To: (Stefan Kangas's message of "Thu, 12 Nov 2020 11:38:04 -0500") Message-ID: <87mtzmjiir.fsf@rub.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:MykZ7SAoMyXR18yjakTt23FKFq+v/kJbbwlqoxuxCGitpGvYCAy NGikISMUz8yaZinpbIjK6rL7IQF9WkTFhWcod73UxxnwlDEJNjT7hXP+dCzcTwDOJOj216v 5XtIYBn5Sv5lWFjVUoS7u5C5OLqAgDKzWMcs32n0N4toR/h1lYVUZs4WEyb8cKrHuLu9bHD FC9CccMxW2c6WYSjEQ/zA== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:DzXFBkqkYmY=:h/l7OcXUf8WDYpHJjSR6MX 2K+d6MkLVek5rq5awrFVg/7cs/Z5BZorVtNFV2SI97k5jGss0l/d6oxiX30g2QhhDso9osWyO X+YT6yILwtrJpGrHZDTLrsN2IAt7bSHKoYKxt6QhjLDObR+hR3asgMb8J9XFBWHMWUHh9azl4 +G3GnGHFkDbcGrcpq8JhwbTSVfl3tiG66Vy5yupjeZYOTimj6lf335e9dsZzFYQvJuA2sjSXS twoU/P8cpXKj+p8QsEsHkTwWgZpzY0v64damzDh66l3DcDyJ+fOfjXNJ4Gxc1pYUi7VMNOdCn aHcTd0QbiS0iBQce1jbAi/MFbCPGtvzEVFkDGH6YEyqkB2HN6zxLbvfbh0DabVQLj/sjTETLe 2A6kuM4JgZRoe1oPXeqwM18CoIS8uKfe1vbO5L0cSqz0sO+E1A+ywbO8USeZffYrA7w6t0odc Tnf90A8sm5Eqld5R7O1MHB6PvMDf+qkFniDnxxo0d29BY4EJsmbumfFIgh6ArUTG7A3mBIH3o q9yMSjHlclZD9ozc20cEHLlWe6DEy58O1xnB0pVb7ikbSYteDg8P5hw4PnFd6EGfmLVsvpBlb d0lV5UxYDRjSbkqfGsUYJ89dLEzRUCaw/iMtGUuD7PpfZwGU8XOfLyNaQF4EtfBBYkTSmSUQD 9k80pDwXoQUaX0oQKwCsWvTu/hWPv0mZmBNwrqYpvy77/btX77mzzQsYNCPBERoActfNa62FY xzHXu2arKg+k9AVL5ln6QyNEPdWX66aIhxNFtWoPAmWoQhd6e6wcGiEbpC5QsVHyuSYyUTICF na6Vf5XOVcUZUym69Z/S5BoUAL28uRfABgM1DYgSavGopogDt5UavqRt12dSwUDCCVmX3ht3d CE4cpUTzPst8ZG5MEGMA== X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 44068-done Cc: Eli Zaretskii , 44068-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Thu, 12 Nov 2020 11:38:04 -0500 Stefan Kangas wrote: > Stephen Berman writes: > >>> BTW, does it work better with narrowing the column, too? We seem to >>> have some issues with that currently. >> >> Do you mean that truncation happens even though there is still enough >> space to display the data or header? I see that both with hard spaces >> and with the :right-align property. I haven't tried to figure out why >> that's happening, but seems to be separate from above change. > > Indeed, it is a separate issue. I have opened Bug#44594 to track it. Thanks. >> Given that, and also Eli's approval of the tabulated-list-init-header >> patch, I've gone ahead and committed these changes. I didn't make any >> of the column width changes I proposed in my first patch, since with the >> tabulated-list-init-header patch they don't seem to be needed. > > Thank you! I guess this bug should therefore be closed as fixed? Yeah, I forgot to do that after committing the patch, done now. Steve Berman From unknown Sat Sep 06 02:32:44 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Fri, 11 Dec 2020 12:24:05 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator