diff --git a/examples/gg/raven_text_rendering.v b/examples/gg/raven_text_rendering.v index 439377a9cd..2c77a27071 100644 --- a/examples/gg/raven_text_rendering.v +++ b/examples/gg/raven_text_rendering.v @@ -73,7 +73,6 @@ fn main() { window_title: 'Empty window' user_data: app bg_color: bg_color - init_fn: init_gui frame_fn: frame font_path: os.resource_abs_path('../assets/fonts/RobotoMono-Regular.ttf') //window_user_ptr: ctx diff --git a/vlib/gg/text_rendering.v b/vlib/gg/text_rendering.v index a9c4bf39fd..b3d24a418c 100644 --- a/vlib/gg/text_rendering.v +++ b/vlib/gg/text_rendering.v @@ -11,7 +11,7 @@ const ( ) pub struct FT { - pub: +pub: fons &C.FONScontext font_normal int @@ -84,15 +84,15 @@ pub fn (ft &FT) flush(){ sfons.flush(ft.fons) } -pub fn (ft &FT) text_width(s string) int { +pub fn (ft &Context) text_width(s string) int { return 0 } -pub fn (ft &FT) text_height(s string) int { +pub fn (ft &Context) text_height(s string) int { return 0 } -pub fn (ft &FT) text_size(s string) (int, int) { +pub fn (ft &Context) text_size(s string) (int, int) { return 0,0 }