GNU bug report logs - #67533
SVG images confound position pixel measurements

Previous Next

Package: emacs;

Reported by: JD Smith <jdtsmith <at> gmail.com>

Date: Wed, 29 Nov 2023 20:33:01 UTC

Severity: normal

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: JD Smith <jdtsmith <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 67533 <at> debbugs.gnu.org, Manuel Giraud <manuel <at> ledu-giraud.fr>
Subject: bug#67533: SVG images confound position pixel measurements
Date: Fri, 1 Dec 2023 10:45:00 -0500

> On Dec 1, 2023, at 10:36 AM, Eli Zaretskii <eliz <at> gnu.org> wrote:
> 
>> From: JD Smith <jdtsmith <at> gmail.com>
>> Date: Fri, 1 Dec 2023 10:21:19 -0500
>> Cc: Manuel Giraud <manuel <at> ledu-giraud.fr>,
>> 67533 <at> debbugs.gnu.org
>> 
>> 
>>> Btw, I wonder what you and JD expect from the (cons (point) -1)
>>> argument.  The doc string says:
>>> 
>>> If FROM is a cons, its car specifies a buffer position, and its cdr
>>> specifies the vertical offset in pixels from that position to the
>>> first screen line to be measured.
>>> 
>>> What is the meaning of negative offset from the first line of the
>>> buffer? there's no screen line at that offset, so what do you expect
>>> that to do?  Or what am I missing?
>> 
>> In that case I would expect zero pixel height is returned.
> 
> Why zero?  Why not consider that undefined behavior?

Depends on what the natural height on a non-existent line is.  Zero makes sense to me.  But I suppose returning height=nil or something else to indicate “I gave up” would also be reasonable. 





This bug report was last modified 1 year and 156 days ago.

Previous Next


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