Fix examples
This commit is contained in:
parent
a5c548b12f
commit
0dce8b75d1
2 changed files with 4 additions and 4 deletions
|
|
@ -1,6 +1,6 @@
|
|||
// SPDX-License-Identifier: MIT OR Apache-2.0
|
||||
|
||||
use cosmic_text::{Attrs, Buffer, Color, FontSystem, Metrics, SwashCache};
|
||||
use cosmic_text::{Attrs, Buffer, Color, FontSystem, Metrics, Shaping, SwashCache};
|
||||
use std::cmp::{self, Ordering};
|
||||
use termion::{color, cursor};
|
||||
|
||||
|
|
@ -28,7 +28,7 @@ fn main() {
|
|||
let attrs = Attrs::new();
|
||||
|
||||
// Add some text!
|
||||
buffer.set_text(" Hi, Rust! 🦀", attrs);
|
||||
buffer.set_text(" Hi, Rust! 🦀", attrs, Shaping::Advanced);
|
||||
|
||||
// Perform shaping as desired
|
||||
buffer.shape_until_scroll();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue