ltk

Function parse_hex

Source
pub fn parse_hex(s: &str) -> Option<Color>
Expand description

Parse a hex colour string ("#RGB" / "#RGBA" / "#RRGGBB" / "#RRGGBBAA", with or without the leading #, case-insensitive) into a Color. Returns None for malformed input.