-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
ENH: collapsible group box #10302
ENH: collapsible group box #10302
Conversation
And in video: output.mp4 |
In the end it's just an image display, right? It seems like there must be a way in ipyvtklink (or whatever it depends on) to make the image's aspect ratio be respected rather than having it get stretched. It seems like some CSS like |
...I would try adding this property directly in Chrome's inspect mode to see if it works, and if so, then dig into which library would need to have this option added, then add it and make an upstream PR... and for now if we can add our own CSS inline or in a little cell header (seems like it should be possible?) then we can add it ourselves, too -- that way people don't have to upgrade |
Thank you for the great suggestions @larsoner ! According to ipywidgets' doc, using
I made a comparative table to showcase the different options with collapsed groupbox or not:
|
No need for an upstream change, the |
I chose
I realize this might be controversial because what we lose during cropping is basically "background", for the particular case of |
What do you think @agramfort, @larsoner? |
I am interested in a live demo :)
… Message ID: ***@***.***>
|
Contain is the right choice I think |
This is ready to go from my end |
During a video call with @agramfort, we discovered a bug related to picking which is introduced in this PR. I have to debug before merge. |
My guess is that it's an |
Hm... Assuming that the picking with the I'll check the size returned by the viewer both in
Well, yes, if I cannot pinpoint the bug or find no way to fix it. |
I will share what I have learned:
What happens when all the group boxes are folded is that the main 3d viewer in the middle is the widget with the highest height value, defining how stretched the container widget ( So the issue with It is possible to mitigate by using I thought of 2 solutions to deal with this:
I did not manage to make |
This sounds like an upstream ipyvtklink bug, I would open an issue there and see if people have ideas |
Meanwhile, 5014f41 is the kind of hack I have to use to make it work with |
@larsoner I opened Kitware/ipyvtklink#35 |
I see a few options for the PR:
|
For now I would say get rid of @GuillaumeFavelier could you see if you can change their computation in the "a little bit of offset computation" code to fix the bug at their end? It might move things forword (much) faster than waiting for them to fix it. |
I'll see what I can do but I think it might be better to handle it with I updated #8833 with:
|
This is ready to merge from my end @agramfort, @larsoner |
Could be, want to open an issue with them, too? They should know if it's in scope for them or not |
(if it's a fairly trivial fix, sometimes I open a PR-as-issue to just fix the problem, and ask if they think it's acceptable) |
Thanks @GuillaumeFavelier ! On to the next blocker for 1.0, if any? |
I pick from #8833 really. The 1.0 section is done so I'm working on bonus territory and bug fixes. |
For now, I'm on #10305 and I plan to tackle next:
since it should be functionally similar |
I would say "show a dialog to save if trans is not saved" and "multiple threads should block window exit" make the most sense next |
This PR adds support for collapsible group boxes for the
notebook
3d backend. Here is an example with coreg:I know the main render view still appears stretched, there might be way to fix its size somehow
It's an item of #8833