diff options
Diffstat (limited to 'indra/llrender/llfontgl.cpp')
-rw-r--r-- | indra/llrender/llfontgl.cpp | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/indra/llrender/llfontgl.cpp b/indra/llrender/llfontgl.cpp index 8cd18c5fa1..86a4c35e6d 100644 --- a/indra/llrender/llfontgl.cpp +++ b/indra/llrender/llfontgl.cpp @@ -89,14 +89,24 @@ void LLFontGL::destroyGL() mFontFreetype->destroyGL(); } -BOOL LLFontGL::loadFace(const std::string& filename, F32 point_size, F32 vert_dpi, F32 horz_dpi, S32 components, BOOL is_fallback) +BOOL LLFontGL::loadFace(const std::string& filename, F32 point_size, F32 vert_dpi, F32 horz_dpi, S32 components, BOOL is_fallback, S32 face_n) { if(mFontFreetype == reinterpret_cast<LLFontFreetype*>(NULL)) { mFontFreetype = new LLFontFreetype; } - return mFontFreetype->loadFace(filename, point_size, vert_dpi, horz_dpi, components, is_fallback); + return mFontFreetype->loadFace(filename, point_size, vert_dpi, horz_dpi, components, is_fallback, face_n); +} + +S32 LLFontGL::getNumFaces(const std::string& filename) +{ + if (mFontFreetype == reinterpret_cast<LLFontFreetype*>(NULL)) + { + mFontFreetype = new LLFontFreetype; + } + + return mFontFreetype->getNumFaces(filename); } static LLTrace::BlockTimerStatHandle FTM_RENDER_FONTS("Fonts"); @@ -860,10 +870,6 @@ void LLFontGL::destroyAllGL() U8 LLFontGL::getStyleFromString(const std::string &style) { S32 ret = 0; - if (style.find("NORMAL") != style.npos) - { - ret |= NORMAL; - } if (style.find("BOLD") != style.npos) { ret |= BOLD; @@ -883,7 +889,7 @@ U8 LLFontGL::getStyleFromString(const std::string &style) std::string LLFontGL::getStringFromStyle(U8 style) { std::string style_string; - if (style & NORMAL) + if (style == NORMAL) { style_string += "|NORMAL"; } |