-
-
Notifications
You must be signed in to change notification settings - Fork 10.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Grabbing scrollbar doesn't work on my backend #8310
Comments
You can see the cursor blinking in the text field at the bottom, you probably have code stealing the focus and active item every frame and preventing other items to be used. |
That was the problem, thanks! |
You want to keep which behavior? The behavior of scrollbar and any other widgets not being usable? Try to describe in details what you actually want and you’ll find your answer. Perhaps you want to focus the input text when its parent window is appearing? Perhaps you want to focus the input text when the parent window is focused and no item is active ? Perhaps you want to focus the input text every time something has been input into it ? |
As long as the window is visible, I want to be able to type in the input text, even if I click outside of the input text. It must keep the focus, except if the user interacts with the scrollbar. I tried |
Version/Branch of Dear ImGui:
Version 1.91.5
Back-ends:
Custom
Compiler, OS:
Windows
Full config/build information:
No response
Details:
My Issue/Question:
I have an application based on VTK and created my own backend for both rendering and interaction handling by forwarding event from VTK to imgui.
Everything works well but I can't grab the scrollbar to scroll the widget content.
Using mouse wheel or clicking on the empty space does scroll it properly.
However, when clicking on the scrollbar, the color changes until I release the button which makes me think imgui correctly receive the mouse down/up events, but I cannot move the scrollbar. The mouse position is also properly updated between the down and up event.
In the attached video, you can see the mouse wheel working, then simple click on empty space working too, but grabbing failing.
Any idea of what could happen here?
Screenshots/Video:
Recording.2025-01-11.214834.mp4
Minimal, Complete and Verifiable Example code:
No response
The text was updated successfully, but these errors were encountered: