Fix math hiding once more

This commit is contained in:
Laurenz 2023-04-19 16:49:22 +02:00
parent 981c578ff9
commit 5a6330dbfc
4 changed files with 6 additions and 17 deletions

View File

@ -233,9 +233,9 @@ impl GlyphFragment {
};
let size = Size::new(self.width, self.ascent + self.descent);
let mut frame = Frame::new(size);
frame.meta_iter(self.meta);
frame.set_baseline(self.ascent);
frame.push(Point::with_y(self.ascent), FrameItem::Text(item));
frame.meta_iter(self.meta);
frame
}
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.2 KiB

After

Width:  |  Height:  |  Size: 8.7 KiB

View File

@ -1,16 +0,0 @@
// Ensure that the math is properly hidden.
---
#set page(height: 70pt)
Testing $delta$
$ a^2 + b^2 = c^2 $
#hide[
Hello
$ f(x) := x^2 $
World $f(x)$
]

View File

@ -13,3 +13,8 @@ $ 1 + sqrt(x/2) + sqrt(#hide($x/2$)) $
$ a x #link("url", $+ b$) $
$ f f1 f2 $
$ vec(1,2) * 2 $
---
$ x^2 #hide[$(>= phi.alt) union y^2 0$] z^2 $
Hello #hide[there $x$]
and #hide[$ f(x) := x^2 $]