🔧 Allow line height values from 0 to 1

This commit is contained in:
Elena Torro
2025-10-07 09:28:24 +02:00
parent 57a7b5b1da
commit 68cd7075c0

View File

@@ -475,7 +475,7 @@ impl Paragraph {
.unwrap_or(&self.children[0]);
let mut strut_style = skia::textlayout::StrutStyle::default();
let line_height = self.line_height.max(1.0);
let line_height = self.line_height.max(0.0);
strut_style.set_font_size(reference_child.font_size);
strut_style.set_height(line_height);
strut_style.set_height_override(true);