DesignCraft: An open-source page and layout design editor written by scratch in pure Rust
Glyph outlines: minimal boolean form (clippy 1.96 nonminimal_bool)
Brandon Thomasa79351e24970
diff --git a/crates/render/src/glyphs.rs b/crates/render/src/glyphs.rsindex 0d5e0bec4..0f8a210fd 100644--- a/crates/render/src/glyphs.rs+++ b/crates/render/src/glyphs.rs@@ -64,7 +64,7 @@ pub fn text_line(db: &ScopedFonts<'_>, family: &str, style: &str, text: &str, helet boxed = glyphs.iter().any(|g| g.gid == 0) && db.missing_box(&face).is_some();for g in &glyphs {let outline = db.outline(&face, g.gid);- if !outline.elements().is_empty() && !(boxed && g.gid == 0) {+ if !(outline.elements().is_empty() || (boxed && g.gid == 0)) {ctx.set_transform(kurbo::Affine::translate((x + g.x_offset as f64 * k, baseline - g.y_offset as f64 * k)) * kurbo::Affine::scale(k));ctx.fill_path(&outline);}