Non-scalable font made out of bitmap images rather than vector data like in Truetype fonts. Used mainly in games. Typically render faster than truetype fonts.
Questions tagged [bitmap-fonts]
92 questions
1
vote
1 answer
LWUIT bitmap font
I'm Developing a small application in one of the classes i'm using two buttons , I have used bitmap fonts for all the components used in application (using Resource Editor) for both English and Persian language. Now I want in result of clicking…
![](../../users/profiles/866080.webp)
aida
- 143
- 1
- 9
1
vote
1 answer
Cannot find BitmapFont.TextBounds in libgdx
I tried to write this piece of code but it is showing error saying it cannot find TextBounds. But it works fine with when I use only BitmapFont.
package com.gamefromscratch;
import com.badlogic.gdx.ApplicationAdapter;
import…
![](../../users/profiles/9818305.webp)
Auler
- 27
- 6
1
vote
0 answers
LibGDX Text is Distorted If I Use GlyphLayout to Draw Bitmap Font
I need to use glyphlayout so that I can centre the text, but I found if I do the text gets distorted due to the spacing being incorrect.
public SimpleButton(String text, float x, float y, float w, float h, BitmapFont font) {
pos = new Vector2(x,…
![](../../users/profiles/4997239.webp)
Hasen
- 7,909
- 17
- 53
- 106
1
vote
1 answer
How to draw text in world coordinate space?
I'm creating a game in libGDX. I want to create some UI elements (buttons and stuff), because of my app design, I would like to draw them in the world space, as other game objects.
I'm using Freetype generator that generates a bitmap font from true…
![](../../users/profiles/10656396.webp)
Jerry Lundegaard
- 198
- 1
- 12
1
vote
1 answer
Libgdx text on Android
I'm new to libgdx and i'm trying to display some text on the screen.
I've watched several tutorials, and they're all saying that I should initiate the BitmapFont with no parameters and it will then use the default font. But on my android device it…
![](../../users/profiles/5494423.webp)
Robert Gers
- 67
- 6
1
vote
1 answer
How to get the natural fontsize of bitmapfont?
If I have a bitmapfont such as;
fonttexture = new Texture(Gdx.files.internal("data/fonttest.png"), true);
font= new BitmapFont(Gdx.files.internal("data/fonttest.fnt"),
new TextureRegion(fonttexture ), true);
Is it possible to…
![](../../users/profiles/377063.webp)
darkflame
- 938
- 8
- 22
1
vote
1 answer
Memory Leak with BitmapFont
I am currently working on an android app using LibGDX and have pinpointed my memory leak down to this one method. Can anyone help me figure out where this is coming from? I have tried looking back through native LibGDX methods but am still having…
![](../../users/profiles/3945799.webp)
Michael
- 83
- 9
1
vote
1 answer
Libgdx font cut
I have an issue with libgdx BitMapFont, I display labels inside of a scene2d table, but the font is "cut" at some parts of the text (see below).
Here is my code :
For declaring the font :
font12 = new…
![](../../users/profiles/1997209.webp)
JavaDev
- 297
- 3
- 15
1
vote
1 answer
Libgdx deprecated drawMultiLine and getBounds
So i found a toolkit to create VisualNovels but it uses
font.drawMultiLine(
batch,
previous.toString() + current.substring(0, c),
dx, dy);
And
else if (font.getBounds(test + words[i] + "…
![](../../users/profiles/5133460.webp)
Darkly
- 347
- 3
- 18
1
vote
1 answer
LibGDX BitmapFont Markup Alpha Value
Alright, so I have a bitmap font with markup enabled. The problem is, I need to set the global alpha value for a whole string of text without setting an individual alpha value for each color code.
For example, I have...
"[#0000ff]this is blue,…
![](../../users/profiles/4151805.webp)
Anuken
- 65
- 10
1
vote
1 answer
LibGDX: Special characters won't display
Hello I try to display special charscters "äöü". I using I18NBundle to store strigs. But the problem shouldn't be here becose if I print it to the console
System.out.println(bundle.get(key));
It does display "äöü".
If I try to get the glyph out of…
![](../../users/profiles/4959397.webp)
Dario Kowalski
- 599
- 4
- 14
1
vote
0 answers
Showing non-western language from right to left in libgdx (Android)
This is my problem:
I'm using Hiero to generate a font for my libgdx game (files .fnt and .png).I success to generate a custom font, but for laguage like arabic (writing text from right to left). i show the result starting from left to right but me…
![](../../users/profiles/3714257.webp)
user3714257
- 47
- 1
- 6
1
vote
1 answer
LibGDX multiple cameras
So, I am working with LiBGDX and Box2D, using the PixelsPerMeter conversion, and I have a camera that follows the player around, but when I turn debug mode on I need to be able to draw a font with the fps on screen, so I always can see it in the…
user4441930
1
vote
1 answer
Merge BitmapFont and UI skin in single Atlas?
If I have a UI with a .atlas and a BitmapFont with a .atlas is there a simple way to combine these into one or do I have to merge them myself in a image file and manually offset all the elements in the combined .atlas to the correct position? It is…
![](../../users/profiles/1322271.webp)
Madmenyo
- 7,643
- 6
- 46
- 88
1
vote
1 answer
BitmapFont special characters not displayed in Android, in desktop version works though
I have a libgdx project that supports an android and a desktop version. For the fonts I previously used the FreeTypeFontGenerator to generate my fonts. Fonts worked fine, but then I decided to create my BitmapFonts with a .fnt & .png file, to have…
![](../../users/profiles/2399024.webp)
donfuxx
- 10,696
- 6
- 41
- 74