OSDN Git Service

Update niftygui 1.3.3
[mikumikustudio/MikuMikuStudio.git] / engine / src / niftygui / com / jme3 / niftygui / RenderFontJme.java
index 0bf421e..349344b 100644 (file)
@@ -97,6 +97,14 @@ public class RenderFontJme implements RenderFont {
         return result;\r
     }\r
 \r
+    public int getWidth(final String str, final float size) {\r
+      // Note: This is supposed to return the width of the String when scaled\r
+      //       with the size factor. Since I don't know how to do that with\r
+      //       the font rendering in jme this will only work correctly with\r
+      //       a size value of 1.f and will return inaccurate values otherwise.\r
+      return getWidth(str);\r
+    }\r
+    \r
     /**\r
      * Return the width of the given character including kerning information.\r
      * @param currentCharacter current character\r