Struct swash::ColorPalette [−][src]
pub struct ColorPalette<'a> { /* fields omitted */ }
Collection of colors.
Implementations
impl<'a> ColorPalette<'a>
[src]
impl<'a> ColorPalette<'a>
[src]pub fn index(&self) -> u16
[src]
Returns the index of the palette.
pub fn name_id(&self) -> Option<StringId>
[src]
Returns the name identifier for the palette, if available.
pub fn name(&self, language: Option<&str>) -> Option<LocalizedString<'a>>
[src]
Returns the name for the palette, optionally for a particular language.
pub fn usability(&self) -> Option<Usability>
[src]
Returns the theme usability of the palette, if available.
pub fn len(&self) -> u16
[src]
Returns the number of color entries in the palette.
pub fn get(&self, index: u16) -> [u8; 4]
[src]
Returns the color for the specified entry in RGBA order.
Trait Implementations
impl<'a> Clone for ColorPalette<'a>
[src]
impl<'a> Clone for ColorPalette<'a>
[src]fn clone(&self) -> ColorPalette<'a>
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl<'a> Copy for ColorPalette<'a>
[src]
impl<'a> Copy for ColorPalette<'a>
[src]Auto Trait Implementations
impl<'a> RefUnwindSafe for ColorPalette<'a>
impl<'a> RefUnwindSafe for ColorPalette<'a>
impl<'a> Send for ColorPalette<'a>
impl<'a> Send for ColorPalette<'a>
impl<'a> Sync for ColorPalette<'a>
impl<'a> Sync for ColorPalette<'a>
impl<'a> Unpin for ColorPalette<'a>
impl<'a> Unpin for ColorPalette<'a>
impl<'a> UnwindSafe for ColorPalette<'a>
impl<'a> UnwindSafe for ColorPalette<'a>