diff --git a/src/layout/mod.rs b/src/layout/mod.rs
index cb6f1348e..d563dafba 100644
--- a/src/layout/mod.rs
+++ b/src/layout/mod.rs
@@ -17,10 +17,10 @@ use std::rc::Rc;
use crate::eval::{StyleChain, Styled};
use crate::font::FontStore;
-use crate::frame::Frame;
-use crate::geom::{Align, Linear, Point, Sides, Size, Spec};
+use crate::frame::{Element, Frame, Geometry, Shape, Stroke};
+use crate::geom::{Align, Linear, Paint, Point, Sides, Size, Spec};
use crate::image::ImageStore;
-use crate::library::{AlignNode, Move, PadNode, PageNode, SizedNode, TransformNode};
+use crate::library::{AlignNode, Move, PadNode, PageNode, TransformNode};
use crate::Context;
/// The root layout node, a document consisting of top-level page runs.
@@ -153,6 +153,16 @@ impl PackedNode {
}
}
+ /// Fill the frames resulting from a node.
+ pub fn filled(self, fill: Paint) -> Self {
+ FillNode { fill, child: self }.pack()
+ }
+
+ /// Stroke the frames resulting from a node.
+ pub fn stroked(self, stroke: Stroke) -> Self {
+ StrokeNode { stroke, child: self }.pack()
+ }
+
/// Set alignments for this node.
pub fn aligned(self, aligns: Spec