pub fn from_name(name: &str) -> Option<Self> {
        let name = name.to_lowercase();
        let name: &str = &name;
        if name == "transparent" {
            return Some(Self::from_rgba(0, 0, 0, 0));
        }
        LOOKUP.n2v.get(name).map(|n| {
            let [_, r, g, b] = n.to_be_bytes();
            Self::from_rgb(r, g, b)
        })
    }
/// If `name` is a known color name, get the corresponding rgba value.
If `name` is a known color name, get the corresponding rgba value.
If ` name ` is a known color name get the corresponding rgba value .
pub fn from_name(name: &str) -> Option<Self> {
        let name = name.to_lowercase();
        let name: &str = &name;
        if name == "transparent" {
            return Some(Self::from_rgba(0, 0, 0, 0));
        }
        LOOKUP.n2v.get(name).map(|n| {
            let [_, r, g, b] = n.to_be_bytes();
            Self::from_rgb(r, g, b)
        })
    }
pub fn from_name ( name : & str ) -> Option < Self > { let name = name . to_lowercase ( ) ; let name : & str = & name ; if name == " " { return Some ( Self :: from_rgba ( 0 , 0 , 0 , 0 ) ) ; } LOOKUP . n2v . get ( name ) . map ( | n | { let [ _ , r , g , b ] = n . to_be_bytes ( ) ; Self :: from_rgb ( r , g , b ) } ) }
If `name` is a known color name, get the corresponding rgba value.
If ` name ` is a known color name get the corresponding rgba value .
name
&str