Can't scroll without setting custom_minimum_size

Godot Version

v4.3.stable.official [77dcf97d8]

Question

I’m trying to make a Control that will let me slide its contents into visibility in a clipped container. I’m hoping to use a ScrollContainer to do this. Inside of the ScrollContainer I have a custom container that holds two things – the component I want to slide in, and a transparent ColorRect to show otherwise. My intention is to place these two components next to each other and both the same size as the outer ScrollContainer, and then I can scroll to make the sliding component appear.

My custom container positions its two children next to each other and each being the same size as the outer ScrollContainer, so that if the ScrollContainer is scrolled all the way to the left, just one component shows, and all the way to the right, the other (filler) component will show.

My problem is that although the child resizing appears to be working as intended, the ScrollContainer never shows an active scrollbar. (I won’t actually show the scrollbar in production, but it lets me know when things are considered to be scrollable). It seems that the ScrollContainer doesn’t care what size its child actually is. It only cares about its minimum size. So even though my child is twice as wide as the ScrollContainer, it refuses to scroll.

Some screenshots in case that helps.

Slider component:

Scrollee component:

Slider Target component:

Filler component:

Scrollee resizing code (place children left to right, each with same size as the parent ScrollContainer):

I guess I don’t understand why the ScrollContainer cares about the minimum size of its children, rather than their actual size. I would think the children should be free to be any size they wish, and the ScrollContainer should let you scroll around inside. If there’s an assumption that the ScrollContainer will squish its child to its minimum, maybe we can make that optional so that children can size themselves as they wish. Or maybe I’m just missing something.

I have tried setting custom_minimum_size directly, but that breaks several things, including making it not possible to drag-shrink the ScrollContainer to a smaller size (since it knows that its child can’t go any smaller).

Thoughts?