/// Get this color as a rgba value.
///
/// If this color is a rgba value, return a borrow of it.
/// Otherwise, do the conversion and return an owned value.
Get this color as a rgba value.
If this color is a rgba value, return a borrow of it.
Otherwise, do the conversion and return an owned value.
Get this color as a rgba value . If this color is a rgba value return a borrow of it . Otherwise do the conversion and return an owned value .
pub fn to_rgba(&self) -> Cow<Rgba> {
        match self {
            Color::Rgba(rgba) => Cow::Borrowed(rgba),
            Color::Hsla(hsla) => Cow::Owned(Rgba::from(hsla)),
            Color::Hwba(hwba) => Cow::Owned(Rgba::from(hwba)),
        }
    }
pub fn to_rgba ( & self ) -> Cow < Rgba > { match self { Color :: Rgba ( rgba ) => Cow :: Borrowed ( rgba ) , Color :: Hsla ( hsla ) => Cow :: Owned ( Rgba :: from ( hsla ) ) , Color :: Hwba ( hwba ) => Cow :: Owned ( Rgba :: from ( hwba ) ) , } }
Get this color as a rgba value.
Get this color as a rgba value .
&self