as the title says i have a small problem with fot-size in eclipse. i created a font using "BMfont", and i implemented it in my game, but when i tested it on a smaller device it was way too big, is there a code i can use to make it adjust automatically. im using Libgdx ,any help is appreciated.
my code
@Override
public void show() {
stage = new Stage();
Gdx.input.setInputProcessor(stage);
atlas = new TextureAtlas("ui/button.pack");
skin = new Skin(atlas);
table = new Table(skin);
table.setBounds(0, 0, Gdx.graphics.getWidth(), Gdx.graphics.getHeight());
white = new BitmapFont(Gdx.files.internal("font/white.fnt"), false);
black = new BitmapFont(Gdx.files.internal("font/black.fnt"), false);
//maakt buttons
TextButtonStyle textButtonStyle = new TextButtonStyle();
textButtonStyle.up = skin.getDrawable("button.up");
textButtonStyle.down = skin.getDrawable("button.down");
textButtonStyle.pressedOffsetX = 1;
textButtonStyle.pressedOffsetY = -1;
textButtonStyle.font = black;
buttonExit = new TextButton("EXIT", textButtonStyle);
buttonExit.addListener(new ClickListener() {
@Override
public void clicked(InputEvent event, float x, float y) {
Gdx.app.exit();
}
});
buttonExit.pad(20);
//maakt header
LabelStyle headingStyle = new LabelStyle(white, Color.WHITE);
heading = new Label(Papermadness.TITLE, headingStyle);
heading.setFontScale(3);
table.add(heading);
table.row();
table.add(buttonExit);
//table.debug();
stage.addActor(table);
}