Replace magic boolean with new Hinting enum
This commit is contained in:
parent
48eda6bd7d
commit
d779057d9c
16 changed files with 96 additions and 50 deletions
|
|
@ -1,7 +1,7 @@
|
|||
// SPDX-License-Identifier: MIT OR Apache-2.0
|
||||
|
||||
use cosmic_text::{
|
||||
Action, Attrs, Buffer, Edit, Family, FontSystem, Metrics, Scroll, Shaping, SwashCache,
|
||||
Action, Attrs, Buffer, Edit, Family, FontSystem, Hinting, Metrics, Scroll, Shaping, SwashCache,
|
||||
};
|
||||
use std::{collections::HashMap, env, fs, num::NonZeroU32, rc::Rc, slice};
|
||||
use tiny_skia::{Color, Paint, PixmapMut, Rect, Transform};
|
||||
|
|
@ -25,7 +25,7 @@ fn main() {
|
|||
|
||||
let mut swash_cache = SwashCache::new();
|
||||
|
||||
let mut buffer = Buffer::new_empty(Metrics::new(14.0, 20.0), false);
|
||||
let mut buffer = Buffer::new_empty(Metrics::new(14.0, 20.0), Hinting::Disabled);
|
||||
|
||||
let mut buffer = buffer.borrow_with(&mut font_system);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue