Skip to content
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

dragScalar sizes the 'input box' too greedily #138

Open
zeroeightysix opened this issue Mar 11, 2020 · 1 comment
Open

dragScalar sizes the 'input box' too greedily #138

zeroeightysix opened this issue Mar 11, 2020 · 1 comment

Comments

@zeroeightysix
Copy link
Collaborator

When indented in tree nodes, dragScalar widgets will use too much space for the input box, often causing the label to be unreadable:

image

Making the window much larger will reveal the label, slowly:
image

Better would be for the input box to size with the window accordingly, and always reserve enough space for the label. This behaviour works fine when not indented, as seen in the demo window:
image

To reproduce:

dsl.treeNode("a") {
    dsl.treeNode("b") {
        dsl.treeNode("c") {
            dragInt("overly long label", ::c)
        }
    }
}
zeroeightysix added a commit to zeroeightysix/KAMI that referenced this issue Jul 1, 2020
This avoids the unfortunate sizing bug explained here: kotlin-graphics/imgui#138
Also makes us use more of the valuable module window space, so why not?

Signed-off-by: Ridan Vandenbergh <[email protected]>
@elect86
Copy link
Collaborator

elect86 commented Apr 13, 2021

This still matches the native behaviour, I'm gonna open an issue over there probably

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants