#[repr(C)]pub struct NodeFlags {
pub inner: u32,
}Expand description
Packed representation of tab index + contenteditable flag.
Bit layout (32 bits): [31] contenteditable flag (1 = true) [30:29] tab_index variant: 00 = None (no tab index set) 01 = Auto 10 = OverrideInParent (value in bits [28:0]) 11 = NoKeyboardFocus [28] is_anonymous (1 = anonymous box for table layout) [27:0] OverrideInParent value (max ~268 million)
Fields§
§inner: u32Implementations§
Source§impl NodeFlags
impl NodeFlags
pub const fn new() -> Self
pub const fn is_contenteditable(&self) -> bool
pub const fn set_contenteditable(self, v: bool) -> Self
pub fn set_contenteditable_mut(&mut self, v: bool)
pub fn get_tab_index(&self) -> Option<TabIndex>
Sourcepub const fn is_anonymous(&self) -> bool
pub const fn is_anonymous(&self) -> bool
Returns whether this node is an anonymous box generated for table layout.
pub fn set_anonymous(&mut self, v: bool)
pub fn set_tab_index(&mut self, tab_index: Option<TabIndex>)
Trait Implementations§
Source§impl Ord for NodeFlags
impl Ord for NodeFlags
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialOrd for NodeFlags
impl PartialOrd for NodeFlags
impl Copy for NodeFlags
impl Eq for NodeFlags
impl StructuralPartialEq for NodeFlags
Auto Trait Implementations§
impl Freeze for NodeFlags
impl RefUnwindSafe for NodeFlags
impl Send for NodeFlags
impl Sync for NodeFlags
impl Unpin for NodeFlags
impl UnsafeUnpin for NodeFlags
impl UnwindSafe for NodeFlags
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