Skip to content

formdropdown - contentcontainer resize so it fits inside the border - #38707

Open
JanGolicnik wants to merge 2 commits into
ppy:masterfrom
JanGolicnik:fix/dropdownbox-border-overlap
Open

JanGolicnik wants to merge 2 commits into
ppy:masterfrom
JanGolicnik:fix/dropdownbox-border-overlap

Conversation

@JanGolicnik

@JanGolicnik JanGolicnik commented Aug 26, 2026 •

Copy link
Copy Markdown

Fix for #37047

The ContentContainer is always the same size as the MaskingContainer and since the borders are inset they get covered up by the items. The obvious solution of adding a padding to the MaskingContainer doesn't work cause it disables the borders. Would make sense updating with that if there is a known fix.

screenshots after:
Screenshot_2026-08-26_02-20-46
Screenshot_2026-08-26_02-21-01

@JanGolicnik

Copy link
Copy Markdown
Author

can i request come guidance regarding CI, the same tests seem to run fine on my linux and I don't have a windows machine to test with. what can i do to fix this ?

@bdach bdach added the type/cosmetic Only affects the game visually. Doesn't affect things working or not working. label Sep 7, 2026

@bdach bdach left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Test failures are irrelevant in this case and as such fine to ignore.


protected override void UpdateSize(Vector2 newSize)
{
ContentContainer.Height = newSize.Y - FormControlBackground.BORDER_THICKNESS * 4.0f;

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Why times four? That's double of what's actually required to fix the issue, is it not?

@JanGolicnik JanGolicnik Sep 7, 2026 •

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

I set the margin to be BORDER_THICKNESS * 2 (line 302), so the height has to be minus twice that. Was just what i subjectively preferred cause the radius in the corner looks a bit off to me. Shouldve mentioned it in the PR. Should I change it to be exact ?

These are screenshots with the exact values

Screenshot_2026-09-07_23-32-52 Screenshot_2026-09-07_23-32-43

@bdach bdach added subjective PRs with subjective changes which have not been discussed prior. Need team consensus to proceed. waiting-on-design and removed subjective PRs with subjective changes which have not been discussed prior. Need team consensus to proceed. labels Sep 7, 2026
@peppy
peppy self-requested a review November 2, 2026 08:24
@peppy

peppy commented Nov 2, 2026

Copy link
Copy Markdown
Member

This makes content scrollable which wasn't before:

Before After
osu Game Tests 2026-11-02 at 08 30 35@2x osu Game Tests 2026-11-02 at 08 26 42@2x

@JanGolicnik

Copy link
Copy Markdown
Author

This makes content scrollable which wasn't before:
Before After
osu Game Tests 2026-11-02 at 08 30 35@2x osu Game Tests 2026-11-02 at 08 26 42@2x

Fixed. I also removed the extra padding from previous comment while i was at it.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/S type/cosmetic Only affects the game visually. Doesn't affect things working or not working. waiting-on-design

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants