[][src]Struct glerminal::menu_systems::InterfaceItemBase

pub struct InterfaceItemBase {
    pub can_be_focused: bool,
    pub dirty: bool,
    // some fields omitted
}

The base for all interaceItems. Contains metadata that is handled similarily in each InterfaceItem

Fields

can_be_focused: bool

Whether this InterfaceItem can be (or should be) focused or not

dirty: bool

Whether this InterfaceItem is dirty so it needs redrawing This should be called every time something changes

Methods

impl InterfaceItemBase
[src]

pub fn new(can_be_focused: bool) -> InterfaceItemBase
[src]

Create a new InterfaceItemBase

(use this if you're making a new InterfaceItem)

pub fn get_pos(&self) -> (u32, u32)
[src]

Get the position of the InterfaceItem

pub fn set_pos(&mut self, pos: (u32, u32))
[src]

Set the absolute position of the InterfaceItem

pub fn is_focused(&self) -> bool
[src]

Whether the InterfaceItem is focused or not (and should it receive inputs or not)

pub fn set_focused(&mut self, focused: bool)
[src]

Un/Focus the InterfaceItem

Trait Implementations

impl Clone for InterfaceItemBase
[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl Debug for InterfaceItemBase
[src]

Auto Trait Implementations

Blanket Implementations

impl<T> From for T
[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

impl<T, U> TryFrom for T where
    T: From<U>, 
[src]

type Error = !

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

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

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Erased for T

impl<T> Downcast for T where
    T: Any