Text Justification not working on UEFN TextBlock

Hi.
Im trying to always center my TextBlock with any Value but its not working sadly.
I tried with DefaultJustifcation and SetJustification but nothing is working for me.

AmountText<public> : text_block = text_block{DefaultTextSize := 32.0, DefaultTextColor := White, DefaultJustification := text_justification.Center}

canvas_slot:

                    Anchors := anchors{Minimum := vector2{X := 0.0, Y := 0.0}, Maximum := vector2{X := 0.0, Y := 0.0}}

                    Offsets := margin{Left := 56.0, Top := 8.0, Right := 0.0, Bottom := 0.0}

                    Widget := AmountText

                    ZOrder := 1

I dont want the Alignment for the whole widget, I want to set the Text Justification to Center.
Does anyone got an Idea for me?

Hello! I see you are using the canvas_slot if I’m not mistaken you would need to set SizeToContent to true, and use the justification also on the text. With that it should adapt to the size of the text and center it.

Thanks for your response, sadly SizeToConent with a DefaultJustification on the text block, did nothing for me.
Textwrapping also doesnt work for me sadly

I found the Issue.
I need to declare SizeToContent to false and I need to define Right and Bottom values to the widget.
Then it does work.

1 Like