1
vote
1answer
36 views

Vertical alignment of a padded font generated by Hiero in libgdx

I've generated bitmap fonts for libgdx using Hiero. I've got several distance field fonts that require a lot of padding, unfortunately they don't seem to align correctly. Below is a font with a ...
2
votes
2answers
265 views

Problem to match font size to the screen resolution in libgdx

I'm having problems to show text on my game at same size on different screens, and I did a simple test. This test consists to show a text fitting at the screen, I want the text has the same size ...
1
vote
1answer
122 views

Dialog Title Does Not Fit

I successfully added my own font to the default .json file and it displays, however I get some weird sizing issues. Specifically when I try to create a Dialog. This is what it looks like: Ignore the ...
1
vote
0answers
66 views

Hiero Font not working [closed]

For ease of use I decided I would use the Skin class to make buttons and text, and the like, rather than draw them myself. So I downloaded Hiero to package a .ttf font into a BitmapFont and it all ...
0
votes
1answer
107 views

“Couldn't load font” LibGDX

yesterday I started working om making custom sized fonts to my game, in game, using FreeTypeFaceGenerator, and yesterday it worked fine, except an exception I was going to handle today. When I loaded ...
2
votes
1answer
403 views

How to match font size with screen resolution?

So I'm working on a game using LibGDX, and I have a problem. To make my game fit most resolutions, I created a base asset for each aspect ratio, for example, a main menu background image, I made it ...
0
votes
2answers
357 views

How do you create fnt (angelcode format) files from existing bitmaps?

I often gets the same problem: Someones creates a nice bitmap font for me in form of a sheet nicely formated into a png, like this: ...and i need to create the angelcode .fnt atlas for using it ...
1
vote
1answer
113 views

Why is my text is too large even when scaled to .05f in libGDX?

I'm trying to scale down my fonts as my game objects are also small. I'd like to scale them down the same way as my sprites. However, if I scale them below .05, the font disappears! My attempt at ...
0
votes
1answer
580 views

LibGdx and in-game fonts - any proven methods?

I use 3 sizes for fonts in my game: small, medium, and large. I take the base font size and attempt to scale the font based on screen size and density, but this is proving to be pretty hard. Does ...
2
votes
1answer
188 views

Libgdx Get Font Height with a Wrap

is possible to get the 'Height' of a font drawed with the drawWrapped methods (with a wrapWidth) ? getMultiLineBounds only works when \n is used, but when drawing with drawWrapped it doesn't give the ...
1
vote
1answer
302 views

How to properly calculate y position when drawing from .fnt bitmap font?

I want to render text to bitmap to use it later as a decal texture. I've read through libGDX fonts drawing code and came up with this: private void writeTextToPixmap(Pixmap destPixmap, Pixmap ...
4
votes
2answers
1k views

Bitmap Font Displays in Center Always Without Coding it Manually (Fix Coordinate Problem onText)

Is there a way on how to stay the texts in center without manually coding it or something, especially when making an update? I'm making a display for the highest score. Let's say that the score is 9. ...
2
votes
1answer
3k views

Using the same font with different sizes in libgdx

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 ...