Reputation: 11
I'm working on a C++ application that uses Dear Imgui for the UI. This app has Multi-Viewports enabled and uses Imgui docking features. The main application window has a menu bar initialized with BeginMenuBar() (not BeginMainMenuBar()) and it's common to have multiple windows open as part of running the application.
Clicking on a menu - e.g "File" - will draw the menu correctly over top of the main application window, but behind any secondary or child windows that are open. This happens if and only if the menu is entirely contained in the viewport of the main application window. If the main application window is resized small enough such that the menu is drawn partially outside of the main window's viewport, then it will be drawn over top of any secondary or child windows.
I've been working through the rendering code but I'm still pretty new to Imgui, so I'd appreciate any help with this issue.
So far I've tried adjusting when the calls to BeginMenuBar() and BeginMenu() are made in the code, but this hasn't affected anything and I really didn't expect it to.
Upvotes: 0
Views: 31