GNU bug report logs - #53375
[PATCH] Account for padding and content length in, tabulated-list-widen-current-column

Previous Next

Package: emacs;

Reported by: Thuna <thuna.cing <at> gmail.com>

Date: Wed, 19 Jan 2022 22:04:01 UTC

Severity: normal

Tags: moreinfo, patch

Fixed in version 29.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 53375 in the body.
You can then email your comments to 53375 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#53375; Package emacs. (Wed, 19 Jan 2022 22:04:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Thuna <thuna.cing <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Wed, 19 Jan 2022 22:04:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Thuna <thuna.cing <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: [PATCH] Account for padding and content length in,
 tabulated-list-widen-current-column
Date: Thu, 20 Jan 2022 00:40:41 +0300
[Message part 1 (text/plain, inline)]
`tabulated-list-widen-current-column' previously looked only at the
width of the column as given in `tabulated-list-format' however this
fails to account for both the padding and content length and as a
result widens the wrong column.

The issue with content length is reproducible as follows:
0. emacs -Q
1. M-x shell
2. M-x list-processes
3. C-x o
4. C-: (tabulated-list-set-col 0 (make-string 50 ?.) t)
5. M-f
6. }


This patch should solve the issue however it relies on
`tabulated-list-get-entry' which means it fails to work if the
`tabulated-list-entry' property is not set properly.  I am unsure if
this should be considered a bug on the tabulated-list end or not.

[0001-Fix-tabulated-list-widen-current-column-widening-wro.patch (text/x-patch, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#53375; Package emacs. (Thu, 20 Jan 2022 14:24:02 GMT) Full text and rfc822 format available.

Message #8 received at 53375 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Thuna <thuna.cing <at> gmail.com>
Cc: 53375 <at> debbugs.gnu.org
Subject: Re: bug#53375: [PATCH] Account for padding and content length in,
 tabulated-list-widen-current-column
Date: Thu, 20 Jan 2022 15:23:28 +0100
Thuna <thuna.cing <at> gmail.com> writes:

> This patch should solve the issue however it relies on
> `tabulated-list-get-entry' which means it fails to work if the
> `tabulated-list-entry' property is not set properly.  I am unsure if
> this should be considered a bug on the tabulated-list end or not.

That function is supposed to give reliable results, so if there are
modes it doesn't work in, that sounds like a bug.

Anyway, the patch looks good to me, so I've pushed it to Emacs 29.

This change was small enough to apply without assigning copyright to the
FSF, but for future patches you want to submit, it might make sense to
get the paperwork started now, so that subsequent patches can be applied
speedily. Would you be willing to sign such paperwork?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Added tag(s) moreinfo. Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Thu, 20 Jan 2022 14:24:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#53375; Package emacs. (Thu, 20 Jan 2022 18:43:02 GMT) Full text and rfc822 format available.

Message #13 received at 53375 <at> debbugs.gnu.org (full text, mbox):

From: Thuna <thuna.cing <at> gmail.com>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: 53375 <at> debbugs.gnu.org
Subject: Re: bug#53375: [PATCH] Account for padding and content length in,
 tabulated-list-widen-current-column
Date: Thu, 20 Jan 2022 21:42:20 +0300
[Message part 1 (text/plain, inline)]
  >> This patch should solve the issue however it relies on
 >> `tabulated-list-get-entry' which means it fails to work if the
 >> `tabulated-list-entry' property is not set properly.  I am unsure if
 >> this should be considered a bug on the tabulated-list end or not.
 >
 > That function is supposed to give reliable results, so if there are
 > modes it doesn't work in, that sounds like a bug.

In that case debbugs itself needs a fix.  It is possible that other
tabulated-list derived modes will fail in a similar way so maybe a
checkup is needed?

 > This change was small enough to apply without assigning copyright to the
 > FSF, but for future patches you want to submit, it might make sense to
 > get the paperwork started now, so that subsequent patches can be applied
 > speedily. Would you be willing to sign such paperwork?

I am willing to sign the paperwork although I know neither how nor what
it entails so some help would be appreciated.

On Thu, Jan 20, 2022 at 5:23 PM Lars Ingebrigtsen <larsi <at> gnus.org> wrote:

> Thuna <thuna.cing <at> gmail.com> writes:
>
> > This patch should solve the issue however it relies on
> > `tabulated-list-get-entry' which means it fails to work if the
> > `tabulated-list-entry' property is not set properly.  I am unsure if
> > this should be considered a bug on the tabulated-list end or not.
>
> That function is supposed to give reliable results, so if there are
> modes it doesn't work in, that sounds like a bug.
>
> Anyway, the patch looks good to me, so I've pushed it to Emacs 29.
>
> This change was small enough to apply without assigning copyright to the
> FSF, but for future patches you want to submit, it might make sense to
> get the paperwork started now, so that subsequent patches can be applied
> speedily. Would you be willing to sign such paperwork?
>
> --
> (domestic pets only, the antidote for overdose, milk.)
>    bloggy blog: http://lars.ingebrigtsen.no
>
[Message part 2 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#53375; Package emacs. (Fri, 21 Jan 2022 09:28:01 GMT) Full text and rfc822 format available.

Message #16 received at 53375 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Thuna <thuna.cing <at> gmail.com>
Cc: 53375 <at> debbugs.gnu.org
Subject: Re: bug#53375: [PATCH] Account for padding and content length in,
 tabulated-list-widen-current-column
Date: Fri, 21 Jan 2022 10:27:38 +0100
Thuna <thuna.cing <at> gmail.com> writes:

>  > That function is supposed to give reliable results, so if there are
>  > modes it doesn't work in, that sounds like a bug.
>
> In that case debbugs itself needs a fix.  It is possible that other
> tabulated-list derived modes will fail in a similar way so maybe a
> checkup is needed?

Sounds like it.  

>  > This change was small enough to apply without assigning copyright to the
>  > FSF, but for future patches you want to submit, it might make sense to
>  > get the paperwork started now, so that subsequent patches can be applied
>  > speedily. Would you be willing to sign such paperwork?
>
> I am willing to sign the paperwork although I know neither how nor what
> it entails so some help would be appreciated.

Here's the form to get started, and here's the rationale behind it:

  https://www.gnu.org/licenses/why-assign.en.html
  

Please email the following information to assign <at> gnu.org, and we
will send you the assignment form for your past and future changes.

Please use your full legal name (in ASCII characters) as the subject
line of the message.
----------------------------------------------------------------------
REQUEST: SEND FORM FOR PAST AND FUTURE CHANGES

[What is the name of the program or package you're contributing to?]
Emacs

[Did you copy any files or text written by someone else in these changes?
Even if that material is free software, we need to know about it.]

[Do you have an employer who might have a basis to claim to own
your changes?  Do you attend a school which might make such a claim?]

[For the copyright registration, what country are you a citizen of?]

[What year were you born?]

[Please write your email address here.]

[Please write your postal address here.]

[Which files have you changed so far, and which new files have you written
so far?]




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#53375; Package emacs. (Sun, 23 Jan 2022 14:43:02 GMT) Full text and rfc822 format available.

Message #19 received at 53375 <at> debbugs.gnu.org (full text, mbox):

From: Thuna <thuna.cing <at> gmail.com>
To: 53375 <at> debbugs.gnu.org
Subject: [PATCH] Correct wrong comparison operation in previous patch
Date: Sun, 23 Jan 2022 17:42:32 +0300
It appears the previous patch I sent used the wrong comparison
operation (">" instead of ">=") and as a result widened the wrong
column when point was at the first character.  The following patch
resolves the issue.

<#part type="text/x-diff" filename="/home/thuna/emacs/0001-Fix-tabulated-list-widen-current-column-widening-wro.patch" disposition=inline>
<#/part>




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#53375; Package emacs. (Sun, 23 Jan 2022 14:48:02 GMT) Full text and rfc822 format available.

Message #22 received at 53375 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Thuna <thuna.cing <at> gmail.com>
Cc: 53375 <at> debbugs.gnu.org
Subject: Re: bug#53375: [PATCH] Correct wrong comparison operation in
 previous patch
Date: Sun, 23 Jan 2022 15:47:06 +0100
Thuna <thuna.cing <at> gmail.com> writes:

> It appears the previous patch I sent used the wrong comparison
> operation (">" instead of ">=") and as a result widened the wrong
> column when point was at the first character.  The following patch
> resolves the issue.
>
> <#part type="text/x-diff"
> filename="/home/thuna/emacs/0001-Fix-tabulated-list-widen-current-column-widening-wro.patch"
> disposition=inline>
> <#/part>

Apparently the patch didn't make it here.  Can you resend it?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#53375; Package emacs. (Sun, 23 Jan 2022 14:53:02 GMT) Full text and rfc822 format available.

Message #25 received at 53375 <at> debbugs.gnu.org (full text, mbox):

From: Thuna <thuna.cing <at> gmail.com>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: 53375 <at> debbugs.gnu.org
Subject: Re: bug#53375: [PATCH] Correct wrong comparison operation in previous
 patch
Date: Sun, 23 Jan 2022 17:52:45 +0300
[Message part 1 (text/plain, inline)]
My bad, hopefully this goes through.
[0001-Fix-tabulated-list-widen-current-column-widening-wro.patch (text/x-patch, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#53375; Package emacs. (Sun, 23 Jan 2022 14:57:01 GMT) Full text and rfc822 format available.

Message #28 received at 53375 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Thuna <thuna.cing <at> gmail.com>
Cc: 53375 <at> debbugs.gnu.org
Subject: Re: bug#53375: [PATCH] Correct wrong comparison operation in
 previous patch
Date: Sun, 23 Jan 2022 15:56:02 +0100
Thuna <thuna.cing <at> gmail.com> writes:

> My bad, hopefully this goes through.

Yup; pushed to Emacs 29 now.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




bug marked as fixed in version 29.1, send any further explanations to 53375 <at> debbugs.gnu.org and Thuna <thuna.cing <at> gmail.com> Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Sun, 20 Feb 2022 19:30:02 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 21 Mar 2022 11:24:08 GMT) Full text and rfc822 format available.

This bug report was last modified 3 years and 87 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.