You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
after hovering over an item in a nested menu that has a tooltip that goes outside the main window, moving the cursor anywhere else closes the nested menu
my repro example is based on the latest commit on the docking branch (as of writing), but i have encountered this issue in 1.91.6-docking and 1.90.6-docking (and a few earlier docking versions but i don't remember which)
i also think this has been reproduced outside of sdl/opengl with dxgi/dx11 but i can't confirm that
this is not an issue on the non-docking branch, the tooltip is just cut off in that case
Screenshots/Video:
Screencast.From.2024-12-19.20-07-48.mp4
Minimal, Complete and Verifiable Example code:
diff --git a/imgui_demo.cpp b/imgui_demo.cpp
index ed205011..cf760d9b 100644
--- a/imgui_demo.cpp+++ b/imgui_demo.cpp@@ -8338,6 +8338,12 @@ static void ShowExampleMenuFile()
if (ImGui::MenuItem("Open", "Ctrl+O")) {}
if (ImGui::BeginMenu("Open Recent"))
{
+ // BEGIN MENU CLOSE ISSUE+ ImGui::MenuItem("HOVER OVER ME");+ if (ImGui::IsItemHovered()) {+ ImGui::SetTooltip("this is a really long tooltip that will overflow and go outside of the window space and hopefully reproduce the issue i was seeing before");+ }+ // END MENU CLOSE ISSUE
ImGui::MenuItem("fish_hat.c");
ImGui::MenuItem("fish_hat.inl");
ImGui::MenuItem("fish_hat.h");
The text was updated successfully, but these errors were encountered:
ocornut
changed the title
nested menu closes when tooltip goes outside window (1.91.6-docking)
Nested menu closes when tooltip goes outside window (1.91.6-docking)
Dec 20, 2024
Do you have a feature enabled to focus windows on hover?
I don't think so, unless it is a default I'm not aware of.
I also want to emphasize that this is not a Linux/Wayland/GNOME specific issue, I know @Archez has encountered this on macOS and @Malkierian has encountered it on Windows
Version/Branch of Dear ImGui:
Version 1.91.6, Branch: docking
Back-ends:
imgui_impl_sdl2.cpp + imgui_impl_opengl3.cpp
Compiler, OS:
debian sid, gcc/g++ 14.2.0
Full config/build information:
Details:
after hovering over an item in a nested menu that has a tooltip that goes outside the main window, moving the cursor anywhere else closes the nested menu
my repro example is based on the latest commit on the docking branch (as of writing), but i have encountered this issue in
1.91.6-docking
and1.90.6-docking
(and a few earlier docking versions but i don't remember which)i also think this has been reproduced outside of sdl/opengl with dxgi/dx11 but i can't confirm that
this is not an issue on the non-docking branch, the tooltip is just cut off in that case
Screenshots/Video:
Screencast.From.2024-12-19.20-07-48.mp4
Minimal, Complete and Verifiable Example code:
The text was updated successfully, but these errors were encountered: