emacs-devel
[Top][All Lists]
Advanced

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

RE: Emacs Survey: Toolbars


From: Tomas Hlavaty
Subject: RE: Emacs Survey: Toolbars
Date: Fri, 25 Dec 2020 22:59:00 +0100

On Fri 25 Dec 2020 at 12:25, Drew Adams <drew.adams@oracle.com> wrote:
>> > > Do you have suggestion for automatically computing "it's not too hard"
>> > > color mapping for "inverse video" "pure" text?
>> >
>> > Convert the color's YUV and invert the Y.
>> 
>> Possibly better: keep the hue and saturation and recalculate luminance
>> to preserve the relative contrast to background color.
>
> There are lots of ways to "invert" or complement a color.
>
> I just use RGB complementing - good enough for most
> purposes for Emacs foregrounds and backgrounds.  Function
> `color-complement' in color.el does that.  So does
> `hexrgb-complement' in hexrgb.el.
>
> Or I use `hexrgb-hue-complement',
> `hexrgb-saturation-complement', or `hexrgb-value-complement'
> If I just want to complement one of those components.

Brilliant, it's already in Emacs, thank you!



reply via email to

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