26 lines
702 B
Rust

use crate::app::App;
use crate::theme::onedark::ONE_DARK;
impl eframe::App for App {
fn update(&mut self, ctx: &egui::Context, _frame: &mut eframe::Frame) {
let background_frame = egui::Frame::default().fill(ONE_DARK.bg);
egui::CentralPanel::default()
.frame(background_frame)
.show(ctx, |ui| {
ui.heading(&self.name);
});
egui::Window::new("test window")
.collapsible(false)
.auto_sized()
.show(ctx, |ui| {
ui.heading(&self.name);
for _ in 0..10 {
ui.add(egui::Button::new(&self.name));
}
}
);
}
}