diff options
Diffstat (limited to 'wgpu/src')
-rw-r--r-- | wgpu/src/backend.rs | 4 | ||||
-rw-r--r-- | wgpu/src/text.rs | 8 |
2 files changed, 9 insertions, 3 deletions
diff --git a/wgpu/src/backend.rs b/wgpu/src/backend.rs index 5a275c8a..f19959bd 100644 --- a/wgpu/src/backend.rs +++ b/wgpu/src/backend.rs @@ -197,8 +197,8 @@ impl iced_graphics::Backend for Backend { impl backend::Text for Backend { const ICON_FONT: Font = Font::Name("Iced-Icons"); - const CHECKMARK_ICON: char = '\u{e800}'; - const ARROW_DOWN_ICON: char = '\u{f00c}'; + const CHECKMARK_ICON: char = '\u{f00c}'; + const ARROW_DOWN_ICON: char = '\u{e800}'; fn default_font(&self) -> Font { self.default_font diff --git a/wgpu/src/text.rs b/wgpu/src/text.rs index 2ca3f0d8..4af57af3 100644 --- a/wgpu/src/text.rs +++ b/wgpu/src/text.rs @@ -45,7 +45,13 @@ impl Pipeline { Pipeline { system: Some( SystemBuilder { - fonts: glyphon::FontSystem::new(), + fonts: glyphon::FontSystem::new_with_fonts( + [glyphon::fontdb::Source::Binary(Arc::new( + include_bytes!("../fonts/Iced-Icons.ttf") + .as_slice(), + ))] + .into_iter(), + ), cache_builder: |fonts| glyphon::SwashCache::new(fonts), measurement_cache_builder: |_| RefCell::new(Cache::new()), render_cache_builder: |_| Cache::new(), |