Struct SliderState

Source
pub struct SliderState {
    pub slider_button_key: GuiComponentKey,
    pub slider_frame: FrameState,
    pub percentage: f32,
}

Fields§

§slider_button_key: GuiComponentKey§slider_frame: FrameState§percentage: f32

Trait Implementations§

Source§

impl GuiComponent for SliderState

Source§

fn common(&self) -> &GuiCommonState

Source§

fn common_mut(&mut self) -> &mut GuiCommonState

Source§

fn as_any(&self) -> &dyn Any

Source§

fn is_visible(&self) -> bool

Source§

fn set_visible(&mut self, is_visible: bool)

Source§

fn as_any_mut(&mut self) -> &mut dyn Any

Source§

fn bounds(&self) -> Vec2<f32>

Source§

fn set_bounds(&mut self, bounds: Vec2<f32>)

Source§

fn render_entry<'a>( &mut self, gl: &GlowGL, state: RenderState<'a>, _text_writer: &mut TextWriter, )

this fires the first occurrence in the tree
Source§

fn render_exit<'a>( &mut self, _gl: &GlowGL, _state: RenderState<'a>, _text_writer: &mut TextWriter, )

this fires after everything in the component subtree has been rendered
Source§

fn name(&self) -> &str

Source§

fn set_name(&mut self, name: &str)

Source§

fn flags(&self) -> &ComponentFlags

Source§

fn flags_mut(&mut self) -> &mut ComponentFlags

Source§

fn rel_position(&self) -> &Vec2<f32>

Source§

fn set_rel_position(&mut self, pos: Vec2<f32>)

Source§

fn set_overflowable(&mut self, overflowable: bool)

Source§

fn is_overflowable(&self) -> bool

Source§

fn get_aabb(&self, global_x0: Vec4<f32>) -> AABB2<f32>

Source§

fn translate(&mut self, disp: Vec2<f32>)

Source§

fn is_origin(&self) -> bool

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.