diff options
| author | Laurenz <laurmaedje@gmail.com> | 2025-01-10 17:54:11 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-01-10 16:54:11 +0000 |
| commit | 6b9b78596a6103dfbcadafaeb03eda624da5306a (patch) | |
| tree | 073a9e31f504634290337c20432ea13dc7a8953d /crates/typst-layout/src/math/accent.rs | |
| parent | 9473aface183feaf48601c5264c3604f5798169e (diff) | |
Don't generate accessors for required fields (#5680)
Diffstat (limited to 'crates/typst-layout/src/math/accent.rs')
| -rw-r--r-- | crates/typst-layout/src/math/accent.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/typst-layout/src/math/accent.rs b/crates/typst-layout/src/math/accent.rs index 0ebe785f..951870d6 100644 --- a/crates/typst-layout/src/math/accent.rs +++ b/crates/typst-layout/src/math/accent.rs @@ -16,7 +16,7 @@ pub fn layout_accent( styles: StyleChain, ) -> SourceResult<()> { let cramped = style_cramped(); - let mut base = ctx.layout_into_fragment(elem.base(), styles.chain(&cramped))?; + let mut base = ctx.layout_into_fragment(&elem.base, styles.chain(&cramped))?; // Try to replace a glyph with its dotless variant. if let MathFragment::Glyph(glyph) = &mut base { @@ -29,8 +29,8 @@ pub fn layout_accent( let width = elem.size(styles).relative_to(base.width()); - let Accent(c) = elem.accent(); - let mut glyph = GlyphFragment::new(ctx, styles, *c, elem.span()); + let Accent(c) = elem.accent; + let mut glyph = GlyphFragment::new(ctx, styles, c, elem.span()); // Try to replace accent glyph with flattened variant. let flattened_base_height = scaled!(ctx, styles, flattened_accent_base_height); |
