ap / vim-css-color

Preview colours in source code while editing
http://www.vim.org/scripts/script.php?script_id=5056
MIT License
1.77k stars 78 forks source link

New features, bugfixes, better testing #187

Open adamhotep opened 1 year ago

adamhotep commented 1 year ago

Benchmark testing showed no appreciable increase in cost to run, but I don't like how inconsistent its stats are.

To implement hwb(), I abstracted hsl2color() to hsl2rgb() in order to retain the RGB channels. While at it, I also converted the other similar functions so there's now only one place where RGB is converted to hexadecimal representation.