emacs-devel
[Top][All Lists]
Advanced

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

Re: Pixel-based display functions


From: Lars Ingebrigtsen
Subject: Re: Pixel-based display functions
Date: Sun, 01 Feb 2015 23:31:04 +1100
User-agent: Gnus/5.130012 (Ma Gnus v0.12) Emacs/25.0.50 (gnu/linux)

martin rudalics <address@hidden> writes:

>> The main problem with it is that it has to
>> work in a window, and much of the computation in shr takes place in
>> temporary buffers.  But perhaps that can be worked around somehow.
>
> No.  Display can be affected by the window the text is displayed in, for
> example, if you use something like an overlay with a window property.
> In addition, you have to account for the default face of the window's
> frame.  So you have to, at least temporarily, associate the text with
> the window where you eventually want to show it to get these applied.

Yes, that's what I meant by "worked around somehow".  :-)  If the eww
buffer is visible in a window (and it usually should be), I can insert
text I want to know the width of there, call the function, and then
delete it again.

However, if the eww buffer isn't visible, that approach won't be
possible...

But the other things you mention here (default window faces and overlays
and stuff) doesn't apply to eww at all, so it kinda sounds like I could
just do all this in a buffer that's even more likely to be associated
with a window, like the echo area.

Or is that too hacky to contemplate?  I think it might be...

-- 
(domestic pets only, the antidote for overdose, milk.)
  bloggy blog http://lars.ingebrigtsen.no/



reply via email to

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