summaryrefslogtreecommitdiff
path: root/library/src
diff options
context:
space:
mode:
Diffstat (limited to 'library/src')
-rw-r--r--library/src/layout/mod.rs10
1 files changed, 5 insertions, 5 deletions
diff --git a/library/src/layout/mod.rs b/library/src/layout/mod.rs
index 02d3bca5..1e437723 100644
--- a/library/src/layout/mod.rs
+++ b/library/src/layout/mod.rs
@@ -251,6 +251,11 @@ impl<'a, 'v, 't> Builder<'a, 'v, 't> {
self.scratch.content.alloc(EquationElem::new(content.clone()).pack());
}
+ if let Some(realized) = realize(self.vt, content, styles)? {
+ let stored = self.scratch.content.alloc(realized);
+ return self.accept(stored, styles);
+ }
+
if let Some((elem, local)) = content.to_styled() {
return self.styled(elem, local, styles);
}
@@ -262,11 +267,6 @@ impl<'a, 'v, 't> Builder<'a, 'v, 't> {
return Ok(());
}
- if let Some(realized) = realize(self.vt, content, styles)? {
- let stored = self.scratch.content.alloc(realized);
- return self.accept(stored, styles);
- }
-
if self.list.accept(content, styles) {
return Ok(());
}