pub trait AlphaColor {
// Required methods
fn get_alpha(&self) -> f32;
fn set_alpha(&self, a: f32) -> Self;
fn opacify(&self, o: f32) -> Self;
}Expand description
Some methods for working with alpha channel for Rgba & Hsla
Required Methods§
fn get_alpha(&self) -> f32
fn set_alpha(&self, a: f32) -> Self
fn opacify(&self, o: f32) -> Self
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.