GNU bug report logs - #6000
describe-text-sexp does not know window-width

Previous Next

Package: emacs;

Reported by: Lennart Borgman <lennart.borgman <at> gmail.com>

Date: Thu, 22 Apr 2010 12:16:01 UTC

Severity: minor

Full log


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

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Juri Linkov <juri <at> jurta.org>
Cc: martin rudalics <rudalics <at> gmx.at>, 6000 <at> debbugs.gnu.org,
 Lennart Borgman <lennart.borgman <at> gmail.com>
Subject: Re: bug#6000: describe-text-sexp does not know window-width
Date: Thu, 03 Jun 2021 11:07:39 +0200
Juri Linkov <juri <at> jurta.org> writes:

>>    (with-selected-window (or (get-buffer-window "*Help*") (selected-window))
>>      (window-width))
>
> Martin referred to this bug report from bug#17831, and I noticed
> that instead of hard-coding the "*Help*" buffer name, better would be
> to use (current-buffer) because the formatted buffer is current:
>
>   (- (if (window-live-p (get-buffer-window (current-buffer) t))
>          (with-selected-window (get-buffer-window (current-buffer) t)
>            (window-width))
>        (window-width))
>      (current-column))

This sounds like a good idea to me, but there wasn't a recipe to
reproduce whatever error this bug report was talking about, so I can't
test.

Does anybody have a test case that displays the problem (in case it's
still in place after all these years)?

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




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

Previous Next


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