1
0
mirror of https://github.com/emilk/egui.git synced 2026-09-02 14:50:03 -04:00

Add Panel to replace SidePanel and TopBottomPanel (#5659)

This combines `SidePanel` and `TopBottomPanel` into a single `Panel`.

The old types are still there as type aliases, but are deprecated.

`.min_width(…)` etc are now called `.min_size(…)` etc.

Again, the old names are still there, but deprecated.

(edited by @emilk)

---------

Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
This commit is contained in:
Bruno Paré-Simard
2025-11-18 09:46:01 -05:00
committed by GitHub
parent 178f3c9198
commit 5b6a0196f9
20 changed files with 695 additions and 795 deletions

View File

@@ -218,7 +218,7 @@ impl winit::application::ApplicationHandler<UserEvent> for GlowApp {
self.egui_glow.as_mut().unwrap().run(
self.gl_window.as_mut().unwrap().window(),
|egui_ctx| {
egui::SidePanel::left("my_side_panel").show(egui_ctx, |ui| {
egui::Panel::left("my_side_panel").show(egui_ctx, |ui| {
ui.heading("Hello World!");
if ui.button("Quit").clicked() {
quit = true;