Subject: Re: bug#18195: 24.3.92; window-screen-lines is not accurate

From: Eli Zaretskii <[email-masked]>
Date: Fri, 08 Aug 2014 13:25:16 +0300

> Date: Fri, 08 Aug 2014 12:10:44 +0200
> From: martin rudalics <[email-masked]>
> CC: [email-masked], [email-masked]
> 
>  > IOW, your suggested solution is incomplete, unless you intend the
>  > application to do some iterative process, each time changing the
>  > position where it puts the overlay and adjusting it in the next
>  > iteration based on the results of window-text-pixel-size.
> 
> This precisley formulates what the application should do and cannot be
> avoided IMHO.

We should provide an API that allows applications to avoid that.

> After all, tooltips and menus seem to face exactly the same problem
> when the frame is at the bottom of the display.

No, we never do any iterations or multiple trials when displaying
menus and tooltips.  We compute the required space and then compare it
with what is available to make the decision.