DangerousStyleNode

Trait DangerousStyleNode 

Source
pub trait DangerousStyleNode<'dom>:
    TNode
    + Sized
    + NodeInfo
    + Send
    + Sync {
    type ConcreteLayoutNode: LayoutNode<'dom>;

    // Required method
    fn layout_node(&self) -> Self::ConcreteLayoutNode;
}
Expand description

A node that can be passed to stylo and selectors that allows accessing the parent node. We consider this to be too dangerous for normal layout, so it is reserved only for using stylo and selectors.

If you are not interfacing with stylo and selectors you should not use this type, unless you know what you are doing.

Required Associated Types§

Source

type ConcreteLayoutNode: LayoutNode<'dom>

The concrete implementation of LayoutNode implemented in script.

Required Methods§

Source

fn layout_node(&self) -> Self::ConcreteLayoutNode

Get a handle to the original “safe” version of this node, a LayoutNode implementation.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§