emacs-devel
[Top][All Lists]
Advanced

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

Re: Removing assumption of unsigned long pixel values for colours


From: Eli Zaretskii
Subject: Re: Removing assumption of unsigned long pixel values for colours
Date: Mon, 06 May 2019 18:06:15 +0300

> Date: Mon, 6 May 2019 09:12:55 +0100
> From: Alan Third <address@hidden>
> Cc: Eli Zaretskii <address@hidden>, address@hidden
> 
> On Sat, May 04, 2019 at 05:04:43PM -0600, Alex Gramiak wrote:
> > 
> > It might also help simplify the NS side to use NSColor objects directly
> > rather than using the unsigned long values as indices to an
> > ns_color_table (CC'd Alan to confirm/deny).
> 
> Unfortunately I don’t know too much about this area, but it certainly
> looks like it might simplify things. It seems like there’s a lot of
> conversion from NSColor, to unsigned long, which must then be
> converted back to NSColor for drawing.

AFAICS, it just indexes into a table of color descriptors.  Which is
something similar to what we do on TTY frames as well, only more
efficient.

Once again, I'm okay, in principle, with changing our
platform-independent abstraction of a color to a different
representation, if that would benefit some of the platforms, but such
a change will have to be across the board, and I imagine it would be
tricky, since the current abstraction is exposed to users (e.g., see
how many of the themes customize their colors).

It's the idea of having 2 representations at once on the
platform-independent level that I don't like.



reply via email to

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