#[repr(transparent)]pub struct COLORREF(_);
Available on crate feature
user
only.Expand description
COLORREF
struct.
Implementations§
source§impl COLORREF
impl COLORREF
sourcepub const fn new(red: u8, green: u8, blue: u8) -> COLORREF
pub const fn new(red: u8, green: u8, blue: u8) -> COLORREF
Creates a new COLORREF
object with the given color intensities.
Examples
use winsafe::prelude::*;
use winsafe::COLORREF;
let color = COLORREF::new(0xff, 0x80, 0x00);
sourcepub fn new_array<const N: usize>(rgbs: &[(u8, u8, u8); N]) -> [COLORREF; N]
pub fn new_array<const N: usize>(rgbs: &[(u8, u8, u8); N]) -> [COLORREF; N]
Creates an array of COLORREF
objects with the given color intensities.
Examples
use winsafe::prelude::*;
use winsafe::COLORREF;
let colors: [COLORREF; 2] = COLORREF::new_array(&[
(0xff, 0xb2, 0x80),
(0x00, 0xa0, 0x40),
]);