emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: :max-width/:max-height


From: Eli Zaretskii
Subject: Re: :max-width/:max-height
Date: Fri, 21 Jun 2013 13:47:07 +0300

> From: Lars Magne Ingebrigtsen <address@hidden>
> Cc: address@hidden
> Date: Fri, 21 Jun 2013 12:29:05 +0200
> 
> Eli Zaretskii <address@hidden> writes:
> 
> > Can you show a pseudo-code that would illustrate the idea?
> 
> (put-image (create-image "/tmp/foo.png" nil nil
>             :max-width (frame-width)
>             :max-height (frame-height)))
> 
> The tedious bit about the computation is finding out whether to use the
> max-width or the max-height when computing the width and height to use.
> (We want to keep the aspect ratio.)

So it's about hiding these computations behind an API, rather than
doing them on the application level, is that right?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]