diff options
Diffstat (limited to 'core/src/ch/asynk/tankontank/menu')
-rw-r--r-- | core/src/ch/asynk/tankontank/menu/OptionsMenu.java | 5 | ||||
-rw-r--r-- | core/src/ch/asynk/tankontank/menu/ScenariosMenu.java | 5 |
2 files changed, 8 insertions, 2 deletions
diff --git a/core/src/ch/asynk/tankontank/menu/OptionsMenu.java b/core/src/ch/asynk/tankontank/menu/OptionsMenu.java index b073731..c866d30 100644 --- a/core/src/ch/asynk/tankontank/menu/OptionsMenu.java +++ b/core/src/ch/asynk/tankontank/menu/OptionsMenu.java @@ -2,6 +2,7 @@ package ch.asynk.tankontank.menu; import com.badlogic.gdx.graphics.g2d.Batch; import com.badlogic.gdx.graphics.g2d.BitmapFont; +import com.badlogic.gdx.graphics.g2d.GlyphLayout; import com.badlogic.gdx.graphics.g2d.TextureAtlas; import ch.asynk.tankontank.ui.Label; @@ -76,7 +77,9 @@ public class OptionsMenu extends Patch this.checkLabels[i] = l; } getValues(); - checkDy = font.getMultiLineBounds(CHECK).height + 5; + GlyphLayout layout = new GlyphLayout(); + layout.setText(font, CHECK); + checkDy = layout.height + 5; this.visible = false; } diff --git a/core/src/ch/asynk/tankontank/menu/ScenariosMenu.java b/core/src/ch/asynk/tankontank/menu/ScenariosMenu.java index 1eb32fa..7cd6499 100644 --- a/core/src/ch/asynk/tankontank/menu/ScenariosMenu.java +++ b/core/src/ch/asynk/tankontank/menu/ScenariosMenu.java @@ -2,6 +2,7 @@ package ch.asynk.tankontank.menu; import com.badlogic.gdx.graphics.g2d.Batch; import com.badlogic.gdx.graphics.g2d.BitmapFont; +import com.badlogic.gdx.graphics.g2d.GlyphLayout; import com.badlogic.gdx.graphics.g2d.TextureAtlas; import ch.asynk.tankontank.ui.Label; @@ -45,7 +46,9 @@ public class ScenariosMenu extends Patch l.write(game.factory.battles[i].getName()); battleLabels[i] = l; } - checkDy = font.getMultiLineBounds(CHECK).height + 9; + GlyphLayout layout = new GlyphLayout(); + layout.setText(font, CHECK); + checkDy = layout.height + 9; this.visible = false; this.launch = false; |