Added a smoothing and strikethrough option to font loading. (#1087)
* Added a smoothing option to font loading. * Added a font strikethrough option to font loading. * Fixed underline applying incorrectly in cases of non-underlined fallback fonts being used. Co-authored-by: Guldoman <giulio.lettieri@gmail.com>
This commit is contained in:
co-authored by
Guldoman
parent
f07b62f852
commit
9b1bfeacac
@@ -58,6 +58,13 @@ static int font_get_options(
|
||||
lua_getfield(L, 3, "underline");
|
||||
if (lua_toboolean(L, -1))
|
||||
style_local |= FONT_STYLE_UNDERLINE;
|
||||
lua_getfield(L, 3, "smoothing");
|
||||
if (lua_toboolean(L, -1))
|
||||
style_local |= FONT_STYLE_SMOOTH;
|
||||
lua_getfield(L, 3, "strikethrough");
|
||||
if (lua_toboolean(L, -1))
|
||||
style_local |= FONT_STYLE_STRIKETHROUGH;
|
||||
|
||||
lua_pop(L, 5);
|
||||
|
||||
if (style_local != 0)
|
||||
|
||||
Reference in New Issue
Block a user