Struct tuix::common::Entity [−]
pub struct Entity(_);
Implementations
impl Entity
impl Entity
Creates a null entity
A null entity can be used as a placeholder within a widget struct but cannot be used to get/set properties
Creates a root entity
The root entity represents the main window and is alwys valid. The root entity can be used to set properties on the window, such as background color, as well as sending events to the window such as Restyle and Redraw events.
pub fn generation(&self) -> Option<u8>
pub fn generation(&self) -> Option<u8>
Returns the generation of the entity
Trait Implementations
impl<'a> IntoBranchIterator<'a> for &'a Entity
impl<'a> IntoBranchIterator<'a> for &'a Entity
type IntoIter = BranchIterator<'a>
pub fn branch_iter(
self,
h: &'a Tree
) -> <&'a Entity as IntoBranchIterator<'a>>::IntoIter
impl<'a> IntoChildIterator<'a> for &'a Entity
impl<'a> IntoChildIterator<'a> for &'a Entity
type IntoIter = ChildIterator<'a>
pub fn child_iter(
self,
h: &'a Tree
) -> <&'a Entity as IntoChildIterator<'a>>::IntoIter
impl<'a> IntoParentIterator<'a> for &'a Entity
impl<'a> IntoParentIterator<'a> for &'a Entity
type IntoIter = ParentIterator<'a>
pub fn parent_iter(
self,
h: &'a Tree
) -> <&'a Entity as IntoParentIterator<'a>>::IntoIter
impl<'a> IntoTreeIterator<'a> for &'a Entity
impl<'a> IntoTreeIterator<'a> for &'a Entity
type IntoIter = TreeIterator<'a>
pub fn into_iter(
self,
h: &'a Tree
) -> <&'a Entity as IntoTreeIterator<'a>>::IntoIter
impl<'a> Node<'a> for Entity
impl<'a> Node<'a> for Entity
A type representing an external store in case the position and size data is not be owned by the node itself (e.g. ECS)
pub fn layout_type(
&self,
store: &<Entity as Node<'a>>::Data
) -> Option<LayoutType>
pub fn layout_type(
&self,
store: &<Entity as Node<'a>>::Data
) -> Option<LayoutType>
Get the layout type of the node Read more
pub fn position_type(
&self,
store: &<Entity as Node<'a>>::Data
) -> Option<PositionType>
pub fn position_type(
&self,
store: &<Entity as Node<'a>>::Data
) -> Option<PositionType>
Get the position type of the node Read more
Get the desired space to the left of the node in units
Get the desired min_left of the node in units
Get the desired min_left of the node in units
Get the desired space to the right of the node in units
Get the desired min_left of the node in units
Get the desired min_left of the node in units
Get the desired space above the node in units
Get the desired min_left of the node in units
Get the desired min_left of the node in units
Get the desired space below the node in units
pub fn min_bottom(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
pub fn min_bottom(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
Get the desired min_left of the node in units
pub fn max_bottom(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
pub fn max_bottom(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
Get the desired min_left of the node in units
Get the desired width of the node in units
Get the desired min_width of the node in units
Get the desired max_width of the node in units
Get the desired height of the node in units
pub fn min_height(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
pub fn min_height(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
Get the desired min_height of the node in units
pub fn max_height(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
pub fn max_height(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
Get the desired max_height of the node in units
pub fn child_left(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
pub fn child_left(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
Get the desired space to the left of all child nodes in units Read more
pub fn child_right(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
pub fn child_right(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
Get the desired space to the right of all child nodes in units Read more
Get the desired space above all child nodes in units Read more
pub fn child_bottom(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
pub fn child_bottom(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
Get the desired space below all child nodes in units Read more
Get the desired grid columns as a vector of units
Get the desired grid rows as a vector of units
pub fn row_between(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
pub fn row_between(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
Get the desired space between children in units when stacked in a column
pub fn col_between(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
pub fn col_between(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
Get the desired space between children in units when stacked in a row
pub fn border_left(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
pub fn border_right(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
pub fn border_top(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
pub fn border_bottom(&self, store: &<Entity as Node<'a>>::Data) -> Option<Units>
Get the desired row_index of the node in units
Get the desired col_index of the node in units
pub fn is_disabled(self, state: &mut State) -> bool
pub fn is_hovered(self, state: &mut State) -> bool
pub fn is_selected(self, state: &mut State) -> bool
pub fn is_checked(self, state: &mut State) -> bool
pub fn is_focused(self, state: &mut State) -> bool
pub fn get_overflow(&self, state: &mut State) -> Overflow
pub fn get_display(&self, state: &mut State) -> Display
pub fn get_bottom(&self, state: &mut State) -> Units
pub fn get_height(&self, state: &mut State) -> Units
pub fn get_min_width(&self, state: &mut State) -> Units
pub fn get_max_width(&self, state: &mut State) -> Units
pub fn get_min_height(&self, state: &mut State) -> Units
pub fn get_max_height(&self, state: &mut State) -> Units
pub fn get_border_width(&self, state: &mut State) -> Units
pub fn get_tooltip(&self, state: &mut State) -> String
fn get_layout_type(&self, state: &mut State) -> LayoutType
fn get_background_color(&self, state: &mut State) -> Color
impl StructuralEq for Entity
impl StructuralPartialEq for Entity
Auto Trait Implementations
impl RefUnwindSafe for Entity
impl UnwindSafe for Entity
Blanket Implementations
Mutably borrows from an owned value. Read more
Helper method for sending an event to self with default propagation
Helper method for sending an event to target with default propagation