From bf434ca548e5b29a1c4ffda2a152a2ef816fa1f4 Mon Sep 17 00:00:00 2001 From: Penwing Date: Sun, 14 Jan 2024 11:18:37 +0100 Subject: [PATCH] layout --- src/main.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index 5696c21..9e30fe0 100644 --- a/src/main.rs +++ b/src/main.rs @@ -18,6 +18,7 @@ fn main() -> Result<(), eframe::Error> { #[derive(Default)] struct MyApp { picked_path: Option, + code: String, } impl eframe::App for MyApp { @@ -25,6 +26,7 @@ impl eframe::App for MyApp { egui::SidePanel::left("my_left_panel").show(ctx, |ui| { ui.label("Tree ?"); }); + egui::CentralPanel::default().show(ctx, |ui| { if ui.button("Open fileā€¦").clicked() { if let Some(path) = rfd::FileDialog::new().pick_file() { @@ -40,9 +42,12 @@ impl eframe::App for MyApp { ui.monospace(picked_path); }); } + + //ui.code_editor(&self.code); }); + egui::TopBottomPanel::bottom("terminal").show(ctx, |ui| { - ui.label("Terminal"); + ui.label("Terminal ?"); }); } }