//! Multi-column layouts. use super::prelude::*; use super::ParNode; /// Separate a region into multiple equally sized columns. #[derive(Debug, Hash)] pub struct ColumnsNode { /// How many columns there should be. pub columns: NonZeroUsize, /// The child to be layouted into the columns. Most likely, this should be a /// flow or stack node. pub child: LayoutNode, } #[class] impl ColumnsNode { /// The size of the gutter space between each column. pub const GUTTER: Linear = Relative::new(0.04).into(); fn construct(_: &mut Vm, args: &mut Args) -> TypResult