backer/
node.rs

1use core::fmt;
2use std::fmt::{Debug, Formatter};
3
4use crate::layout::NodeValue;
5
6/// A layout tree node. Use methods in [`crate::nodes`] to create nodes.
7pub type Node<State> = NodeWith<State, ()>;
8
9/// A layout tree node. Use methods in [`crate::nodes`] to create nodes.
10pub struct NodeWith<State, Ctx> {
11    pub(crate) inner: NodeValue<State, Ctx>,
12}
13
14impl<State, Ctx> Debug for NodeWith<State, Ctx> {
15    fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result {
16        f.debug_struct("NodeWith")
17            .field("inner", &self.inner)
18            .finish()
19    }
20}