Skip to content

Commit

Permalink
Use the correct text size and height in tiny_skia
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuamegnauth54 committed Sep 6, 2023
1 parent bdf1855 commit cee0ed6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tiny_skia/src/text.rs
Original file line number Diff line number Diff line change
Expand Up @@ -406,8 +406,8 @@ impl Cache {

if let hash_map::Entry::Vacant(entry) = self.entries.entry(hash) {
let metrics = cosmic_text::Metrics::new(
key.line_height,
(key.line_height * 1.2).max(f32::MIN_POSITIVE),
key.size,
key.line_height.max(f32::MIN_POSITIVE),
);
let mut buffer = cosmic_text::Buffer::new(font_system, metrics);

Expand Down

0 comments on commit cee0ed6

Please sign in to comment.