diff options
Diffstat (limited to 'src/library/transform.rs')
| -rw-r--r-- | src/library/transform.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/library/transform.rs b/src/library/transform.rs index e9a41a98..9d04071d 100644 --- a/src/library/transform.rs +++ b/src/library/transform.rs @@ -3,7 +3,7 @@ use super::prelude::*; use crate::geom::Transform; -/// A node that transforms its child without affecting layout. +/// Transform a node without affecting layout. #[derive(Debug, Hash)] pub struct TransformNode<T: TransformKind> { /// Transformation to apply to the contents. @@ -17,8 +17,8 @@ impl<T: TransformKind> TransformNode<T> { /// The origin of the transformation. pub const ORIGIN: Spec<Option<Align>> = Spec::default(); - fn construct(_: &mut EvalContext, args: &mut Args) -> TypResult<Node> { - Ok(Node::inline(Self { + fn construct(_: &mut EvalContext, args: &mut Args) -> TypResult<Template> { + Ok(Template::inline(Self { kind: T::construct(args)?, child: args.expect("body")?, })) |
