D20263: [WIP] Keep perceived contrast in random background color
Mariusz Glebocki
noreply at phabricator.kde.org
Fri Apr 5 13:33:51 BST 2019
mglb created this revision.
mglb added projects: Konsole, VDG.
mglb requested review of this revision.
REVISION SUMMARY
Randomize colors using HSLuv color space instead of HSL. It has
perceptually uniform lightness, which means every color with the same
lightness value is perceived as equally bright by humans. Displays
quality and lack of calibration in most monitors lowers this uniformity,
but even on worst color display it should be better than standard HSL.
More information about HSLuv: http://www.hsluv.org/
Minor changes:
- Random seed takes PID into account to prevent repeated colors in separate Konsole processes
- Key names in a config were changed
- Adapted "Black on random light" color scheme
Breeze with random ranges on default bg and fg: hue=360° saturation=100:
F6754773: Screenshot_2019-04-05-14-17-38.png <https://phabricator.kde.org/F6754773>
Todo:
- Automatically convert old values to new values when color scheme is loaded
- Adjust defaults
- Put https://github.com/hsluv/hsluv-c files (without tests) in `src/3rdparty/hsluv-c`. For now, hsluv.[c,h] are in src.
- (?) Change "randomize background color" checkbox function to "randomize background and foreground color" (maybe in separate review)
REPOSITORY
R319 Konsole
BRANCH
wip/Keep-perceived-contrast-in-random-background-color (branched from master)
REVISION DETAIL
https://phabricator.kde.org/D20263
AFFECTED FILES
data/color-schemes/BlackOnRandomLight.colorscheme
src/CMakeLists.txt
src/ColorScheme.cpp
src/ColorScheme.h
src/ViewManager.cpp
src/hsluv.c
src/hsluv.h
To: mglb
Cc: konsole-devel, cblack, arvidhansson, ian, hannahk, Pixel_Lime, jraleigh, gennad, squeakypancakes, alexde, IohannesPetros, GB_2, trickyricky26, thsurrel, mglb, crozbo, ndavis, firef, ngraham, skadinna, maximilianocuria, aaronhoneycutt, hindenburg, mbohlender
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/konsole-devel/attachments/20190405/895e384c/attachment.html>
More information about the konsole-devel
mailing list