mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
libtxt: record metrics for each font used within a run (flutter/engine#4259)
This commit is contained in:
parent
3a943b12c3
commit
87a0a52941
@ -462,13 +462,14 @@ void Paragraph::Layout(double width, bool force) {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
SkPaint::FontMetrics metrics;
|
||||
paint.getFontMetrics(&metrics);
|
||||
paint_records.emplace_back(run.style, SkPoint::Make(run_x_offset, 0),
|
||||
builder.make(), metrics, line_number,
|
||||
layout.getAdvance());
|
||||
}
|
||||
|
||||
SkPaint::FontMetrics metrics;
|
||||
paint.getFontMetrics(&metrics);
|
||||
paint_records.emplace_back(run.style, SkPoint::Make(run_x_offset, 0),
|
||||
builder.make(), metrics, line_number,
|
||||
layout.getAdvance());
|
||||
run_x_offset += layout.getAdvance();
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user