1
0
mirror of https://github.com/emilk/egui.git synced 2026-09-01 14:20:04 -04:00

Share font atlas

This commit is contained in:
Emil Ernerfeldt
2019-01-13 00:19:53 +01:00
parent 2fc191eed4
commit 1b8a45a514
7 changed files with 31 additions and 35 deletions

View File

@@ -34,7 +34,7 @@ impl Painter {
pub fn new(
canvas_id: &str,
(tex_width, tex_height, pixels): (u16, u16, &[u8]),
(tex_width, tex_height, pixels): (u16, u16, Vec<u8>),
) -> Result<Painter, JsValue> {
let document = web_sys::window().unwrap().document().unwrap();
let canvas = document.get_element_by_id(canvas_id).unwrap();