pub enum Surface {
Content {
dark: bool,
},
Glass {
dark: f32,
},
}Expand description
What a widget is drawn on. It decides the colors of labels and fills.
Read it from Ui::surface when you draw your own
widget, so it looks right on content and on glass.
Variants§
Implementations§
Source§impl Surface
impl Surface
Sourcepub fn text_color(&self) -> Color
pub fn text_color(&self) -> Color
Returns the color of primary text.
Sourcepub fn secondary_color(&self) -> Color
pub fn secondary_color(&self) -> Color
Returns the color of less important text.
Sourcepub fn tertiary_color(&self) -> Color
pub fn tertiary_color(&self) -> Color
Returns the color of hints and disabled text.
Sourcepub fn fill_color(&self) -> Color
pub fn fill_color(&self) -> Color
Returns the fill of tracks, wells and hovered rows.
Sourcepub fn strong_fill_color(&self) -> Color
pub fn strong_fill_color(&self) -> Color
Returns a stronger fill, for selections and switches that are off.
Sourcepub fn separator_color(&self) -> Color
pub fn separator_color(&self) -> Color
Returns the color of separator lines.
Sourcepub fn thumb_color(&self) -> Color
pub fn thumb_color(&self) -> Color
Returns the color of a thumb at rest.
Trait Implementations§
impl Copy for Surface
impl StructuralPartialEq for Surface
Auto Trait Implementations§
impl Forget for Surface
impl Freeze for Surface
impl Move for Surface
impl RefUnwindSafe for Surface
impl Send for Surface
impl Sync for Surface
impl Unpin for Surface
impl UnsafeUnpin for Surface
impl UnwindSafe for Surface
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.