Changing Scroll Container properties in the inspector does nothing

Godot Version

4.5

Question

SOLVED:
RTF label has its own scroll feature. To make this work I had to disable Scroll Active, then enable Fit Content so that it behaves like a regular label. That allows the Scroll Container to work properly.

Can the post be marked as solved?


I’ve encountered a curious issue. I have an info box in my game that’s supposed to convey details about a stat when the player clicks on the stat’s name. I do this by having a RTF label inside a scroll container, inside a margin container, inside a panel.

The label starts empty and gets updated when the main scene script calls the update function of the info box scene, which changes the text value to the proper dictionary entry.

Everything about the info box works fine, except for the fact that whenever I try to alter the scroll container’s properties, be it with the inspector or with code, it does literally nothing.

For example, setting the scrolling to disabled, always show, never show etc. does nothing. It will always appear in game as if I selected the “auto“ setting.

Also, scroll_vertical does nothing.

Whenever I update the text I want to automatically scroll back to the top of the window. I tried this:

func update(key):
	$Panel/MarginContainer/ScrollContainer/Label.text = Info.Box[key]
	$Panel/MarginContainer/ScrollContainer.set_deferred("scroll_vertical", 0)

I’ve tried with and without set_deferred, I tried changing it before or after the text update, I even tried big negative and positive values. It simply does nothing.

Any idea what the issue might be?

You need to make an actual reply to mark it as solved.