Skip to content

Commit

Permalink
Added GetGlyphRangesThai()
Browse files Browse the repository at this point in the history
  • Loading branch information
nProtect authored and ocornut committed Jul 20, 2016
1 parent ffdd7d7 commit 4141144
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
1 change: 1 addition & 0 deletions imgui.h
Original file line number Diff line number Diff line change
Expand Up @@ -1322,6 +1322,7 @@ struct ImFontAtlas
IMGUI_API const ImWchar* GetGlyphRangesJapanese(); // Default + Hiragana, Katakana, Half-Width, Selection of 1946 Ideographs
IMGUI_API const ImWchar* GetGlyphRangesChinese(); // Japanese + full set of about 21000 CJK Unified Ideographs
IMGUI_API const ImWchar* GetGlyphRangesCyrillic(); // Default + about 400 Cyrillic characters
IMGUI_API const ImWchar* GetGlyphRangesThai(); //Default + Thai charactors

// Members
// (Access texture data via GetTexData*() calls which will setup a default font for you.)
Expand Down
11 changes: 11 additions & 0 deletions imgui_draw.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1652,6 +1652,17 @@ const ImWchar* ImFontAtlas::GetGlyphRangesCyrillic()
return &ranges[0];
}

const ImWchar* ImFontAtlas::GetGlyphRangesThai()
{
static const ImWchar ranges[] =
{
0x0020, 0x00FF, //Basic Latin
0x0E00, 0x0E7F, //Thai Unicode
0,
};
return &ranges[0];
}

//-----------------------------------------------------------------------------
// ImFont
//-----------------------------------------------------------------------------
Expand Down

0 comments on commit 4141144

Please sign in to comment.