Subject: bug#16974: 24.3.50; [Wishlist] Feature to automatically adjust foreground/background colours when contrast below some threshold

From: [email-masked] (N. Jackson)
Date: Sun, 09 Mar 2014 12:36:42 -0300

Wishlist: It would be very useful to have a feature that automatically
adjusts the foreground and background colours when the contrast between
them is below some threshold value (in some reasonably meaningful units
-- perhaps a percentage), while keeping the colours as close as possible
to their unadjusted values.

Such a feature was proposed (and, IIUC, prototyped) in the discussion of
the bizarrely named :distant-foreground face attribute on the
emacs-devel list around the 7th of January (2014). There it met with the
objection that nothing should ever override any of a user's
settings. However, if the user wants their settings overridden in certain
circumcstances, then it seems unreasonable to deny them that.

Presumably there would be two variables: a Boolean `auto-adjust-contrast' and
a numeric `auto-adjust-contrast-threshold' (or names to that effect). The first
variable could be eliminated with the convention that the feature be
disabled when the threshold variable is set to zero.