Use f32 instead of i32 for lengths

This allows users to use logical coordinates instead of physical ones.
This commit is contained in:
Héctor Ramón Jiménez 2023-02-04 11:13:53 +01:00
parent f08bea22ed
commit 4320ae6329
No known key found for this signature in database
GPG key ID: 140CC052C94F138E
15 changed files with 203 additions and 155 deletions

View file

@ -184,8 +184,8 @@ impl BufferLine {
pub fn layout(
&mut self,
font_system: &FontSystem,
font_size: i32,
width: i32,
font_size: f32,
width: f32,
wrap: Wrap,
) -> &[LayoutLine] {
if self.layout_opt.is_none() {