Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

I am using BitmapFonts, LabelStyles and Labels for my texts.

I want to resize some labels, so i use this.

fontType.scale(-.6f);

LabelStyle style = new LabelStyle(fontType, Color.WHITE);

titleLabel = new Label("Points", style);
titleLabel.setColor(Color.RED);
titleLabel.x = 260; 
titleLabel.y = 310;

but when i want to resize another label, all the labels containing that font resize (I create a new LabelStyle). So i resize the label instead of the font, but that doesnt solve the problem, because it doesnt resize the label, any idea?

share|improve this question

1 Answer 1

up vote 2 down vote accepted

I would preffer adding this as a comment, but i have no commetn priviledge yet.

Have you tried creating a new bitmapfont instead of a new label?

share|improve this answer
    
Yes, but is it correct doing that if its the same font? :/ –  Rudy_TM Mar 12 '12 at 21:03
    
I assume it's not that big of a deal. Can't check libgdx code at work. But isn't a spritebatch passed as parameter for the draw method? That at least lets you know it wont impact too much on performance i guess –  Xavier Guzman Mar 13 '12 at 15:36
    
I have tried that and the load time increases a lot XD (4 seconds with 4 bitmapfonts built in the constructor) u.u –  Rudy_TM Mar 13 '12 at 15:42

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.