font stringSize load

This commit is contained in:
nullifiedcat 2018-07-29 23:52:43 +03:00
parent 6edbc9e4a2
commit 1e03d3843f
2 changed files with 4 additions and 0 deletions

View File

@ -48,6 +48,8 @@ void font::unload()
void font::stringSize(const std::string &string, float *width, float *height)
{
float penX = 0;
float size_x = 0;

View File

@ -31,6 +31,8 @@ void font::unload()
void font::stringSize(const std::string &string, float *width, float *height)
{
if (!isLoaded())
load();
auto &font = detail::font::get(handle);
font.stringSize(string, width, height);
}