#[repr(C)]pub struct Rgb {
pub r: u8,
pub g: u8,
pub b: u8,
}Expand description
True-color RGB representation.
Uses 3 bytes for 24-bit color depth, supporting 16.7 million colors. This is essential for precise brand colors in commercial applications.
Fields§
§r: u8Red channel (0-255)
g: u8Green channel (0-255)
b: u8Blue channel (0-255)
Implementations§
Source§impl Rgb
impl Rgb
Sourcepub const DEFAULT_FG: Self = Self::WHITE
pub const DEFAULT_FG: Self = Self::WHITE
Default foreground (white)
Sourcepub const DEFAULT_BG: Self = Self::BLACK
pub const DEFAULT_BG: Self = Self::BLACK
Default background (black)
Trait Implementations§
impl Copy for Rgb
impl Eq for Rgb
impl StructuralPartialEq for Rgb
Auto Trait Implementations§
impl Freeze for Rgb
impl RefUnwindSafe for Rgb
impl Send for Rgb
impl Sync for Rgb
impl Unpin for Rgb
impl UnwindSafe for Rgb
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more