pub struct UiElement<'a> {
pub id: Option<u64>,
pub role: UiRole,
pub label: UiLabel<'a>,
pub painted_label: &'a str,
pub bounds: Rect,
pub visible_bounds: Option<Rect>,
pub enabled: bool,
pub focused: bool,
pub interaction_registered: bool,
}Expand description
Borrowed description of one accepted submission, in composition order.
Read after finishing layout/input for current focus. Bounds are the exact
logical rectangles used by painting/hit testing, before viewport projection.
visible_bounds is their positive-area clip intersection, not ink bounds,
occlusion, or a promise that truncated/limited text is all painted. Panels,
text and gradients are paint only. Earlier modal scopes remain inspectable.
Fields§
§id: Option<u64>§role: UiRole§label: UiLabel<'a>§painted_label: &'a strActual retained painter copy (possibly ellipsized); empty for decoration.
bounds: Rect§visible_bounds: Option<Rect>§enabled: boolSubmitted button state, not the host/global input enable flag.
focused: bool§interaction_registered: boolButton belongs to the latest modal scope, or is its blocker. Disabled buttons are still registered and can own/block pointer gestures.
Trait Implementations§
impl<'a> Copy for UiElement<'a>
impl<'a> StructuralPartialEq for UiElement<'a>
Auto Trait Implementations§
impl<'a> Freeze for UiElement<'a>
impl<'a> RefUnwindSafe for UiElement<'a>
impl<'a> Send for UiElement<'a>
impl<'a> Sync for UiElement<'a>
impl<'a> Unpin for UiElement<'a>
impl<'a> UnwindSafe for UiElement<'a>
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