Godot Version
4.4
Question
I’m trying to create a dialog box using a RichText label. The main reason is to be able to be sure that each line appears properly without jumping a word from one line to the next if it doesn’t fit. I do that by setting “Visible Characters Behavior” to “Characters After Shaping”. I want to use this in conjunction the “Visible Ratio”, starting it at 0 and then using a tween to show the message. To let the text scroll as the text starts appearing I also enable the “Scroll Following”.
The problem arises when I see that the text starts already scrolled to the bottom, making like the text is always hidden, until it reaches the last sentence.
I tried setting the scroll value to 0 in GDScript, and also using the method scroll_to_line(). They do scroll to the start of the text, but making this somehow makes the auto scrolling not work. Notice how the scroll jumps back to the top here;
Of couse, if I set the “VIsible Characters Behaviour” back to "“Characters Before Shaping”, the scroll works correctly and starts from the beginning, but as I mentioned, the sentence’s words jump from one line to the next if they don’t fit.
Is there any solution to this?