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
With ImGui::GetIO.ConfigFlags |= ImGuiConfigFlags_NavEnableKeyboard the "edit mouse cursor" is lost after Enter is pressed in ImGui::InputText in the Console example in imgui_demo.cpp. This does not happen when NavEnableKeyboard is off, which I think is desirable because the user still has their mouse in the InputText (see video).
Reproduces in Demo on GLFW+OpenGL3 example in Dear ImGui on Windows, also observed on SDL2+OpenGL3 on Ubunto Linux.
Video:
Dear_ImGui_Edit_Cursor_Issue.mp4
Note that the mouse is moved slightly to restore the edit cursor after it is lost by hitting Enter.
Standalone, minimal, complete and verifiable example:
No new code needed to reproduce
The text was updated successfully, but these errors were encountered:
ocornut
changed the title
Inconsistent Mouse Cursor Behavior with NavEnableKeyboard
Inconsistent Mouse Cursor over InputText with NavEnableKeyboard
May 13, 2023
This seems to not be general, but caused by the SetKeyboardFocusHere() call in the console code.
It switches to keyboard mode and then in this situation mouse hovering doesn't highlight items anymore.
I have pushed a workaround for it 349af87
I may decide to generalize this a little bit further in the future.
Thanks for reporting and sorry for my late answer!
Configuration
Issue:
With
ImGui::GetIO.ConfigFlags |= ImGuiConfigFlags_NavEnableKeyboard
the "edit mouse cursor" is lost afterEnter
is pressed inImGui::InputText
in theConsole
example inimgui_demo.cpp
. This does not happen whenNavEnableKeyboard
is off, which I think is desirable because the user still has their mouse in theInputText
(see video).Reproduces in Demo on GLFW+OpenGL3 example in Dear ImGui on Windows, also observed on SDL2+OpenGL3 on Ubunto Linux.
Video:
Dear_ImGui_Edit_Cursor_Issue.mp4
Note that the mouse is moved slightly to restore the edit cursor after it is lost by hitting
Enter
.Standalone, minimal, complete and verifiable example:
No new code needed to reproduce
The text was updated successfully, but these errors were encountered: