diff options
Diffstat (limited to 'src/export/render.rs')
| -rw-r--r-- | src/export/render.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/export/render.rs b/src/export/render.rs index ff35390e..89a17eea 100644 --- a/src/export/render.rs +++ b/src/export/render.rs @@ -160,7 +160,7 @@ fn render_svg_glyph( // If there's no viewbox defined, use the em square for our scale // transformation ... - let upem = face.units_per_em as f32; + let upem = face.units_per_em() as f32; let (mut width, mut height) = (upem, upem); // ... but if there's a viewbox or width, use that. @@ -232,7 +232,7 @@ fn render_outline_glyph( // Flip vertically because font design coordinate // system is Y-up. - let scale = text.size.to_f32() / face.units_per_em as f32; + let scale = text.size.to_f32() / face.units_per_em() as f32; let ts = ts.pre_scale(scale, -scale); canvas.fill_path(&path, &paint, rule, ts, mask)?; return Some(()); |
