Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The dialog resize function does not work in the 2 button interface #360

Open
balloonpopper opened this issue Nov 29, 2024 · 0 comments · May be fixed by #361
Open

The dialog resize function does not work in the 2 button interface #360

balloonpopper opened this issue Nov 29, 2024 · 0 comments · May be fixed by #361
Labels
bug Something isn't working

Comments

@balloonpopper
Copy link
Contributor

balloonpopper commented Nov 29, 2024

Bug description

3 related issues

  1. The _modify_size in dialog_caption.gd doesn't modify the size of the text box correctly - it sets the height of the RichTextLabel, but not the width. Short text lines therefore appear at a different y coordinate to long ones.

  2. Additionally, as text is being typed by the tween, if there's not enough room on the current line for a word, the tween writes whatever part of the word it can fit on the line then erases the half word and rewrites it on the following line before completing it.

  3. The rich text box when you inspect it ends up with a duplicate color entry - i.e.
    [center][color=white][color=white]...[/color][/color][/center]

Steps to reproduce

In a 1080p resolution game, use commands like this

await C.get_OfficerBlonde().say("Hi!")
await C.get_OfficerBlonde().say("Do you know the best thing about this shower, Sonny?")

to write text to the screen. According to dialog_text.gd, "wrap_width := 200.0" but the long line will be displayed ignoring that it goes over 200px.
Also, you'll see that the y coordinate of the two lines is very different.

Expected vs observed behavior

Width enforcement should be respected.
Words should not be half written if they don't fit on a line but should be entirely written in their final form on a brand new line.

Environment information (please complete):

  • Windows 10
  • 4.3
  • Latest dev branch

Additional context

@balloonpopper balloonpopper added the bug Something isn't working label Nov 29, 2024
@balloonpopper balloonpopper linked a pull request Nov 29, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: No status
Development

Successfully merging a pull request may close this issue.

1 participant