use fltk_decl::DeclarativeApp; const GUI: &str = r#" Group Button 80 30 my_button #0000ff "#; fn main() { // use the filetype and extension that you require. // `run` a callback that runs at least once, or whenever the gui file changes. DeclarativeApp::new_inline(200, 300, "MyApp", serde_xml_rs::from_str(GUI).ok()) .run_once(|_| {}) .unwrap(); }