Subject: bug#67533: SVG images confound position pixel measurements

From: Eli Zaretskii <[email-masked]>
Date: Fri, 01 Dec 2023 18:30:27 +0200

> From: JD Smith <[email-masked]>
> Date: Fri, 1 Dec 2023 11:17:49 -0500
> Cc: Manuel Giraud <[email-masked]>,
>  [email-masked]
> 
> >>> 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.
> > 
> > A non-existent line can have any height, including an infinite one.
> > Since that line doesn't exist, any assertion about it cannot be
> > disproved.
> 
> As a general statement, of course.  But since the docs say:
> 
> > The optional argument FROM, if non-nil, specifies the first text
> > position to consider, and defaults to the minimum accessible position
> > of the buffer.
> 
> 
> would it not be reasonable that (FROM . (- too-many-pixels)) would also “default to the minimum accessible position”, should the offset prove to be too-many-pixels?

No, "defaults to" according to our conventions means "if it's nil or
omitted".  Nonsense values don't activate the default and are not
replaced by the default.  Unless we say something like "any other
value is taken as...".