aboutsummaryrefslogtreecommitdiff
path: root/html/range.html
diff options
context:
space:
mode:
authorBen Harris <bjh21@bjh21.me.uk>2022-12-13 23:28:35 +0000
committerBen Harris <bjh21@bjh21.me.uk>2022-12-14 00:34:41 +0000
commit8acb84ea7f21a581349458a39ec3f889fd525cc5 (patch)
tree883ad910e878ca49c8b726de99bc1e665279306a /html/range.html
parent562b29e102cdfa019b0f9d79e105f3f7d7e7bb0e (diff)
downloadpuzzles-8acb84ea7f21a581349458a39ec3f889fd525cc5.zip
puzzles-8acb84ea7f21a581349458a39ec3f889fd525cc5.tar.gz
puzzles-8acb84ea7f21a581349458a39ec3f889fd525cc5.tar.bz2
puzzles-8acb84ea7f21a581349458a39ec3f889fd525cc5.tar.xz
Rewrite mkhighlight to handle a wider range of colours
Before, it worked by scaling all the colour components, which worked reasonably for colours in the vicinity of white, but failed badly on a black background. Now it generates the highlight and lowlight colours by mixing the background colour with white and black respectively. Where there isn't enough headroom, it adjusts the background by mixing in a negative amount of white or black, which makes sense geometrically if not in paint. There is still a problem that green and yellow colours don't end up with bright enough highlights. I think this is because the code doesn't understand that green is brighter than red or blue.
Diffstat (limited to 'html/range.html')
0 files changed, 0 insertions, 0 deletions