A little question to the egui

I'm very new to Rust.I'm learning egui these days.My egui version is 0.13.1.

my code

let ctx : CtxRef = CtxRef::default();
        egui::CentralPanel::default().show(&ctx, |ui| {
            ui.hyperlink("https://pigeons.cyou");
        });

the exception:

thread 'main' panicked at 'No fonts available until first call to CtxRef::begin_frame()'

I want to know how to fix it.Thanks

1 Like

Since the error message mentions CtxRef::begin_frame(), it seems like your code is supposed to use ctx.begin_frame(…) at some point. Either that’s missing, or if you have it, you aren’t showing us the complete situation here. The documentation of CtxRef has an example of how it might be used.

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.