emacs-devel
[Top][All Lists]
Advanced

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

Re: Identifying the face between STRETCH and right fringe.


From: Eli Zaretskii
Subject: Re: Identifying the face between STRETCH and right fringe.
Date: Tue, 27 Nov 2018 20:55:01 +0200

> From: Robert Pluim <address@hidden>
> Cc: address@hidden
> Date: Tue, 27 Nov 2018 14:55:23 +0100
> 
> >> When we get here, face->background == 1, and FRAME_BACKGROUND_PIXEL ==
> >> 0xfffeffff
> >> 
> >> Looking through nsfns.m, the problem becomes obvious: the NS port uses
> >> indices into a color table to specify the background colour of faces,
> >> and FRAME_BACKGROUND_PIXEL is an RGBA value.
> >
> > Why does NS use indices here, and not RGBA values?
> 
> Probably because NS doesnʼt really use the RGBA values directly at
> all, but uses the indices all the time.

So where does the RGBA value in FRAME_BACKGROUND_PIXEL come from?

> > If no better/cleaner idea emerges, how about having an NS-specific
> > code here that computed the it->face's background RGBA by indexing
> > into the color table, before comparing that with
> > FRAME_BACKGROUND_PIXEL?
> 
> Thatʼs doable.

Thanks.

Note that there are a couple more of such comparisons, so perhaps a
macro is in order, with different implementations for NS and the rest.



reply via email to

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