GNU bug report logs - #30796
27.0.50; window-text-pixel-size returns wrong values

Previous Next

Package: emacs;

Reported by: Sebastien Chapuis <seb93250 <at> gmail.com>

Date: Tue, 13 Mar 2018 15:27:02 UTC

Severity: normal

Found in version 27.0.50

Done: Eli Zaretskii <eliz <at> gnu.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 30796 in the body.
You can then email your comments to 30796 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#30796; Package emacs. (Tue, 13 Mar 2018 15:27:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Sebastien Chapuis <seb93250 <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Tue, 13 Mar 2018 15:27:02 GMT) Full text and rfc822 format available.

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

From: Sebastien Chapuis <seb93250 <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 27.0.50; window-text-pixel-size returns wrong values
Date: Tue, 13 Mar 2018 15:26:54 +0100
Hi,

I'm using the function to size correctly a child frame in lsp-ui [1]
The commit 50e2c0fb5180a757d8d533518f68837ffe5909be introduced the bug.
I have tested with and without text properties in the buffer and the bug
still occurs. In my case the TO parameter is nil.

[1] https://github.com/emacs-lsp/lsp-ui


In GNU Emacs 27.0.50 (build 6, x86_64-pc-linux-gnu, GTK+ Version 3.22.26)
 of 2018-03-13 built on XPS13
Repository revision: 50e2c0fb5180a757d8d533518f68837ffe5909be
Windowing system distributor 'Fedora Project', version 11.0.11906000
System Description: Fedora 27 (Twenty Seven)

Configured using:
 'configure --prefix=/opt/emacs-git --with-modules --with-xwidgets
 --with-imagemagick CC=clang'

--
Sebastien Chapuis




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#30796; Package emacs. (Tue, 13 Mar 2018 17:02:02 GMT) Full text and rfc822 format available.

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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Sebastien Chapuis <seb93250 <at> gmail.com>
Cc: 30796 <at> debbugs.gnu.org
Subject: Re: bug#30796: 27.0.50; window-text-pixel-size returns wrong values
Date: Tue, 13 Mar 2018 19:01:34 +0200
> From: Sebastien Chapuis <seb93250 <at> gmail.com>
> Date: Tue, 13 Mar 2018 15:26:54 +0100
> 
> I'm using the function to size correctly a child frame in lsp-ui [1]
> The commit 50e2c0fb5180a757d8d533518f68837ffe5909be introduced the bug.
> I have tested with and without text properties in the buffer and the bug
> still occurs. In my case the TO parameter is nil.

Sorry about the bug.

Can you please provide a recipe to reproduce the problem in
"emacs -Q"?  Otherwise I'm afraid it's hard for me to know where to
look for the problem.

Thanks.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#30796; Package emacs. (Wed, 14 Mar 2018 17:47:02 GMT) Full text and rfc822 format available.

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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Sebastien Chapuis <seb93250 <at> gmail.com>
Cc: 30796 <at> debbugs.gnu.org
Subject: Re: bug#30796: 27.0.50; window-text-pixel-size returns wrong values
Date: Wed, 14 Mar 2018 19:46:26 +0200
> From: Sebastien Chapuis <seb93250 <at> gmail.com>
> Date: Tue, 13 Mar 2018 23:36:59 +0000
> 
> This code reproduces the issue:
> 
> (let* ((buffer (with-current-buffer (get-buffer-create "*test-window*")
>                  (erase-buffer)
>                  (insert "hellooooooooo\na\nb\n")
>                  (goto-char 1)
>                  (setq mode-line-format nil)
>                  (current-buffer)))
>        (window (display-buffer-in-child-frame
>                 buffer
>                 `((child-frame-parameters . ((left . 10)
>                                              (no-accept-focus . t)
>                                              (no-focus-on-map . t)
>                                              (min-width  . 0)
>                                              (width  . 0)
>                                              (min-height  . 0)
>                                              (height  . 0)
>                                              (internal-border-width . 1)
>                                              (vertical-scroll-bars . nil)
>                                              (horizontal-scroll-bars . nil)
>                                              (left-fringe . 0)
>                                              (right-fringe . 0)
>                                              (menu-bar-lines . 0)
>                                              (tool-bar-lines . 0)
>                                              (line-spacing . 0)
>                                              (unsplittable . t)
>                                              (undecorated . t)
>                                              (top . 10)
>                                              (visibility . nil)
>                                              (mouse-wheel-frame . nil)
>                                              (no-other-frame . t)
>                                              (cursor-type . nil)
>                                              (inhibit-double-buffering . t)
>                                              (drag-internal-border . t)
>                                              (no-special-glyphs . t)
>                                              (default-minibuffer-frame . ,(selected-frame))
>                                              (minibuffer . ,(minibuffer-window))
>                                              (background-color . "red")
>                                              )))))
>        (frame (window-frame window))
>        (size (window-text-pixel-size window nil nil 10000 10000)))
>   (set-frame-size frame (car size) (cdr size) t)
>   size)

Thanks, this should be already fixed on master.  I found yesterday a
stupid omission in my original commit and fixed it.




Reply sent to Eli Zaretskii <eliz <at> gnu.org>:
You have taken responsibility. (Thu, 15 Mar 2018 11:48:01 GMT) Full text and rfc822 format available.

Notification sent to Sebastien Chapuis <seb93250 <at> gmail.com>:
bug acknowledged by developer. (Thu, 15 Mar 2018 11:48:01 GMT) Full text and rfc822 format available.

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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Sebastien Chapuis <seb93250 <at> gmail.com>
Cc: 30796-done <at> debbugs.gnu.org
Subject: Re: bug#30796: 27.0.50; window-text-pixel-size returns wrong values
Date: Thu, 15 Mar 2018 13:47:26 +0200
> From: Sebastien Chapuis <seb93250 <at> gmail.com>
> Date: Thu, 15 Mar 2018 11:09:46 +0000
> 
> Alright thank you !

So I'm closing the bug report.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Fri, 13 Apr 2018 11:24:05 GMT) Full text and rfc822 format available.

This bug report was last modified 7 years and 129 days ago.

Previous Next


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