1
0
mirror of https://github.com/emilk/egui.git synced 2026-08-30 13:20:05 -04:00

Enable and fix a bunch more lints

This commit is contained in:
Emil Ernerfeldt
2022-07-11 23:08:48 +02:00
parent e76c919c7e
commit 898f4804b7
21 changed files with 65 additions and 48 deletions

View File

@@ -217,7 +217,7 @@ type FontIndex = usize;
pub struct Font {
fonts: Vec<Arc<FontImpl>>,
/// Lazily calculated.
characters: Option<std::collections::BTreeSet<char>>,
characters: Option<BTreeSet<char>>,
replacement_glyph: (FontIndex, GlyphInfo),
pixels_per_point: f32,
row_height: f32,
@@ -382,7 +382,7 @@ fn allocate_glyph(
}
});
let offset_in_pixels = vec2(bb.min.x as f32, scale_in_pixels + bb.min.y as f32);
let offset_in_pixels = vec2(bb.min.x, scale_in_pixels + bb.min.y);
let offset = offset_in_pixels / pixels_per_point + y_offset * Vec2::Y;
UvRect {
offset,