FTBBox FTSimpleLayout::BBox(const wchar_t *string, const int len) { FTBBox tmp; int lines; WrapTextI(string, len, FTPoint(), &tmp, lines); return tmp; }
int FTSimpleLayout::get_lines(const char * string, const int len) { int lines; FTPoint p(0.0f, 0.0f); FTBBox tmp; WrapTextI(string, len, p, &tmp, lines); return lines; }
FTBBox FTSimpleLayout::BBoxL(const char *string, const int len) { FTBBox tmp; int lines; WrapTextI(string, len, FTPoint(), &tmp, lines); double h = lines * currentFont->LineHeight(); tmp.upper.values[1] = tmp.lower.values[1] + h; return tmp; }
inline void FTSimpleLayout::RenderI(const T *string, const int len, FTPoint position) { if (!FTTextureFont::custom_shader) { Render::set_effect(Render::FONT); } pen = FTPoint(0.0f, 0.0f); int lines; WrapTextI(string, len, position, NULL, lines); if (!FTTextureFont::custom_shader) { Render::disable_effect(); } }
void FTSimpleLayoutImpl::WrapText(const wchar_t* buf, const int len, FTPoint position, int renderMode, FTBBox *bounds) { WrapTextI(buf, len, position, renderMode, bounds); }