Center align bitmapfont makes the text disappear

Hi,

I have some bitmapfont that I do
[java]score.setAlignment(Align.Center);[/java]
Problem is the text disappears if I do it.
If I set Align to left it’s there again.
I don’t have a long text, only the text “0” to start with.

Is this a bug?

What width have you set it to? Maybe the center is outside the screen?

I think alignment probably doesn’t work like you want. As I recall, it aligns the text to the center of the current text rectangle set with setBox().

If you want the text centered over some location then you have to move the text yourself. Setting the text box with negative coordinates might work, also.