1
0
mirror of https://github.com/emilk/egui.git synced 2026-06-26 22:53:14 -04:00

Round glyph to closes pixel

This commit is contained in:
Emil Ernerfeldt
2025-03-30 17:52:29 +02:00
parent 20667a0592
commit 5f01b0dc9d

View File

@@ -634,6 +634,8 @@ fn galley_from_rows(
// When mixing different `FontImpl` (e.g. latin and emojis),
// we always center the difference:
+ 0.5 * (glyph.font_height - glyph.font_impl_height);
glyph.pos.y = point_scale.round_to_pixel(glyph.pos.y);
}
placed_row.pos.y = cursor_y;