Skip to content

Conversation

@abey79
Copy link
Member

@abey79 abey79 commented Nov 27, 2023

What

This PR changes the way inner margins and ScrollAreas are nested to avoid some visual issues.

Checklist

  • I have read and agree to Contributor Guide and the Code of Conduct
  • I've included a screenshot or gif (if applicable)
  • I have tested demo.rerun.io (if applicable)
  • The PR title and labels are set such as to maximize their usefulness for the next release's CHANGELOG

@abey79 abey79 added 🪳 bug Something isn't working ui concerns graphical user interface exclude from changelog PRs with this won't show up in CHANGELOG.md labels Nov 27, 2023
// Set the clip rectangle to the panel for the benefit of nested, "full span" widgets
// like large collapsing headers. Here, no need to extend `ui.max_rect()` as the
// enclosing frame doesn't have inner margins.
ui.set_clip_rect(ui.max_rect());
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this clip-rect call still needed?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. I believe the ScrollArea sets the clip rect only if it actually cuts into content. Even then, it extends it by clip_rect_margin, leading to glitches such as this:

image

@abey79 abey79 merged commit fd4f9b1 into main Nov 27, 2023
@abey79 abey79 deleted the antoine/fix-panels-scrollarea-layout branch November 27, 2023 13:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🪳 bug Something isn't working exclude from changelog PRs with this won't show up in CHANGELOG.md ui concerns graphical user interface

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Fix Blueprint Tree scrollbar spacing

3 participants