pub struct DisplayEnv<'a> {
pub media: Option<&'a MediaEnv>,
pub interaction: Option<&'a InteractionTracker>,
/* private fields */
}Expand description
Committed cascade inputs. Default resolves the static rows only (engines without
responsive support, store-only callers).
Fields§
§media: Option<&'a MediaEnv>@media / show_on environment; None ignores Responsive rows.
interaction: Option<&'a InteractionTracker>Live pseudo-state for StateRules patches.
Implementations§
Source§impl<'a> DisplayEnv<'a>
impl<'a> DisplayEnv<'a>
Sourcepub fn with_interaction(interaction: Option<&'a InteractionTracker>) -> Self
pub fn with_interaction(interaction: Option<&'a InteractionTracker>) -> Self
Static rows plus live pseudo-state (engines without @media / @container support).
Sourcepub fn effective_box(&self, store: &NodeStore, id: NodeId) -> EffectiveBox
pub fn effective_box(&self, store: &NodeStore, id: NodeId) -> EffectiveBox
id’s EffectiveBox under these inputs.
pub fn display(&self, store: &NodeStore, id: NodeId) -> Display
Sourcepub fn is_display_none(&self, store: &NodeStore, id: NodeId) -> bool
pub fn is_display_none(&self, store: &NodeStore, id: NodeId) -> bool
Dead or effectively display: none.
Sourcepub fn is_display_contents(&self, store: &NodeStore, id: NodeId) -> bool
pub fn is_display_contents(&self, store: &NodeStore, id: NodeId) -> bool
Non-root, live and effectively display: contents.
Trait Implementations§
Source§impl<'a> Clone for DisplayEnv<'a>
impl<'a> Clone for DisplayEnv<'a>
impl<'a> Copy for DisplayEnv<'a>
Source§impl<'a> Default for DisplayEnv<'a>
impl<'a> Default for DisplayEnv<'a>
Source§impl ResponsivePatches for DisplayEnv<'_>
impl ResponsivePatches for DisplayEnv<'_>
fn visit_responsive_patches<'a>( &self, store: &'a NodeStore, id: NodeId, f: &mut dyn FnMut(ConditionalTier, RowPatchView<'a>), )
id’s show_on gate fails (display: none beating every rule, like Web’s !important).Source§impl SemanticStyleOracle for DisplayEnv<'_>
impl SemanticStyleOracle for DisplayEnv<'_>
fn is_display_none(&self, store: &NodeStore, id: NodeId) -> bool
Source§fn is_display_contents(&self, store: &NodeStore, id: NodeId) -> bool
fn is_display_contents(&self, store: &NodeStore, id: NodeId) -> bool
Effectively
display: contents (non-root).fn visibility(&self, store: &NodeStore, id: NodeId) -> Visibility
fn is_node_disabled(&self, store: &NodeStore, id: NodeId) -> bool
Source§fn is_inert(&self, _store: &NodeStore, _id: NodeId) -> bool
fn is_inert(&self, _store: &NodeStore, _id: NodeId) -> bool
Inert under the topmost modal (HTML modal-dialog
inert: neither focusable nor
targetable). Oracles without the scene’s overlay resolution answer false.Source§fn is_subtree_display_none(&self, store: &NodeStore, id: NodeId) -> bool
fn is_subtree_display_none(&self, store: &NodeStore, id: NodeId) -> bool
Whether
id or any ancestor is Self::is_display_none.Auto Trait Implementations§
impl<'a> Forget for DisplayEnv<'a>
impl<'a> Freeze for DisplayEnv<'a>
impl<'a> Move for DisplayEnv<'a>
impl<'a> RefUnwindSafe for DisplayEnv<'a>
impl<'a> Send for DisplayEnv<'a>
impl<'a> Sync for DisplayEnv<'a>
impl<'a> Unpin for DisplayEnv<'a>
impl<'a> UnsafeUnpin for DisplayEnv<'a>where
&'a MediaEnv: UnsafeUnpin,
&'a GenSlots<ContainerEnv>: UnsafeUnpin,
&'a InteractionTracker: UnsafeUnpin,
impl<'a> UnwindSafe for DisplayEnv<'a>where
&'a MediaEnv: UnwindSafe,
&'a GenSlots<ContainerEnv>: UnwindSafe,
&'a InteractionTracker: UnwindSafe,
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