change getRenderWidth() default to UTF8

Origin commit data
------------------
Commit: 8b91cda918
Author: vanhofen <vanhofen@gmx.de>
Date: 2014-06-11 (Wed, 11 Jun 2014)

Origin message was:
------------------
- change getRenderWidth() default to UTF8
This commit is contained in:
vanhofen
2014-06-11 11:48:59 +02:00
parent 81d1ff3ebc
commit 3bba3094e2
35 changed files with 127 additions and 128 deletions

View File

@@ -608,7 +608,7 @@ int CLuaInstance::RenderString(lua_State *L)
center = luaL_checkint(L, 9);
if (f >= SNeutrinoSettings::FONT_TYPE_COUNT || f < 0)
f = SNeutrinoSettings::FONT_TYPE_MENU;
int rwidth = g_Font[f]->getRenderWidth(text, true);
int rwidth = g_Font[f]->getRenderWidth(text);
if (center) { /* center the text inside the box */
if (rwidth < w)
x += (w - rwidth) / 2;
@@ -635,7 +635,7 @@ int CLuaInstance::getRenderWidth(lua_State *L)
if (f >= SNeutrinoSettings::FONT_TYPE_COUNT || f < 0)
f = SNeutrinoSettings::FONT_TYPE_MENU;
lua_pushinteger(L, (int)g_Font[f]->getRenderWidth(text, true));
lua_pushinteger(L, (int)g_Font[f]->getRenderWidth(text));
return 1;
}