Skip to content

How to add egui Panel in 0.46 #406

Description

@Tuupertunut

In kiss3d 0.46 egui was updated to 0.36, which removes the ability to show an egui::Panel with just an egui::Context. Now an egui::Ui is needed instead. The kiss3d Window::draw_ui(|ctx| { ... }) passes only a egui::Context to the user. In the ui.rs example, the egui::Context is used to only show a egui::Window, which is still possible.

Is there a recommended way how to show a simple egui::Panel, not a movable egui::Window, in kiss3d 0.46?

It seems that bevy has hit the same problem with egui 0.36 update and there is an egui issue emilk/egui#8415 about it.

Currently a user side workaround could be to use egui::Context::run_ui() directly (requires some boilerplate code). One kiss3d side solution would be to have Window::draw_ui() pass an egui::Ui instead of egui::Context, like eframe does.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions