GNU bug report logs - #51995
29.0.50; `string-pixel-width' depends on the current window width

Previous Next

Package: emacs;

Reported by: Brahimi Saifullah <brahimi.saifullah <at> gmail.com>

Date: Sat, 20 Nov 2021 05:05:02 UTC

Severity: normal

Found in version 29.0.50

Fixed in version 29.1

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

Bug is archived. No further changes may be made.

Full log


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

From: Brahimi Saifullah <brahimi.saifullah <at> gmail.com>
To: martin rudalics <rudalics <at> gmx.at>
Cc: 51995 <at> debbugs.gnu.org
Subject: Re: bug#51995: 29.0.50;
 `string-pixel-width' depends on the current window width
Date: Sun, 21 Nov 2021 21:53:27 -0300
>Can you explain how you are supposed to apply it?
>
>I tried:
>
>  git apply buffer-text-pixel-size.diff
>
>But all it says is:
>
>  error: corrupt patch at line 12

My bad, it seems the file got corrupted on my end.  I downloaded it from
debbugs.gnu.org and the patch is recognized as valid, yet it does not apply:

  Checking patch lisp/emacs-lisp/subr-x.el...
  error: while searching for:
    "Return the width of STRING in pixels."
    (with-temp-buffer
      (insert string)
      (car (window-text-pixel-size
            (current-buffer) (point-min) (point)))))

  (provide 'subr-x)


  error: patch failed: lisp/emacs-lisp/subr-x.el:446
  error: lisp/emacs-lisp/subr-x.el: patch does not apply


(The only problem is that a new function was added at
 the end of subr-x,  the xdisp.c part does apply fine.)

I've also tested the patch further, using `buffer-text-size' on my
package's implementation of `string-pixel-width', and everything is
is working, including my tests.  Thanks.




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

Previous Next


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