sht-colour
is for conversions involving SHT colour codes. SHT codes are an intuitive human-readable text format for colours. See https://omaitzen.com/sht/spec/ for the specification. Supports conversion to and from RGB/hex and parsing from text.
```rust use ::sht_colour::{ rgb::{HexRGB, RGB}, Ratio, SHT, };
let redsht = "r".parse::
// RGB
is the standard struct for RGB values, from the rgb
crate.
let redrgb =
// Converting between SHT and HexRGB (with a precision of 1 digit). asserteq!(redsht.torgb(1), redhex); asserteq!(redsht, redhex.tosht(1));
// Converting between HexRGB and RGB.
asserteq!(