-
-
Notifications
You must be signed in to change notification settings - Fork 21.4k
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
Godot 3 to 4 Conversion: scene Label align and valign values get discarded #74493
Comments
Layout mode has nothing to do with text alignment inside of the label. You do have a typo in your code sample though. |
Fixed the typo, that happens if you do it free hand. Its just a behaviour that i noticed, that if i just replace the align and valign with the new property names, those settings get discarded, unless i also add the layout_mode = 2 in the .tscn |
That's not possible, something else must be happening at the same time. Please provide MRP that demonstrates the issue. |
Added an MRP created in godot v3.5.1.stable.official [6fed1ff] with 3 .tscn files, 3 times just a label with centered text, the first one with no manual changes to the .tscn, (The third one is not relevant for the core issue of this topic, but just wanted to leave it in for test-purposes) The first scene will remove the alignment |
Also had this issue, had to reset all labels by hand |
Tried this on my machine using the MRP and can confirm that the issue exists. Will try to fix it. |
Godot version
v4.0.stable.official [92bee43]
System information
Windows 10
Issue description
Label align and valign just get discarded, having to replace them with the new values.
in the .tscn files it would be a conversion of:
valign = 1
=vertical_alignment = 1
align = 1
=horizontal_alignment = 1
~~
But to get it to actually work the Label inside the tscn would also need to get the
layout_mode = 2
attribute to have set, else it will discard the replaced values~~(After specific testing this doesnt seem to be the culprit, but the main issue above still stands)
(Tested by changes via external text-editor on the tscn file directly before opening it.)
Steps to reproduce
migration from 3.X to 4
Minimal reproduction project
Reproduction label center getting lost.zip
The text was updated successfully, but these errors were encountered: