add Font::get_line_height()

This commit is contained in:
Josh Holtrop 2014-06-23 13:08:29 -04:00
parent 77022ae0b5
commit 959a2571af

View File

@ -13,7 +13,9 @@ namespace jes
Font(); Font();
~Font(); ~Font();
bool load(FT_Library ft, const char * fname, size_t size); bool load(FT_Library ft, const char * fname, size_t size);
int get_line_height() { return round_up_26_6(m_face->size->metrics.height); }
protected: protected:
int round_up_26_6(int val) { return (val + 63) >> 6u; }
FT_Face m_face; FT_Face m_face;
bool m_loaded; bool m_loaded;
}; };