struct FontInfo { FontInfo* next; wchar_t name[32]; int size; bool bold, italic; void* hfont; int height; int ascent; int external_leading; int width_of_space; int GetTextWidth(wchar_t* text, int textlen); ~FontInfo(); }; FontInfo* LoadFont(const wchar_t* name, int size, bool bold, bool italic); void RenderText( const wchar_t* text, FontInfo* font, unsigned char textcolor, unsigned char halocolor, unsigned char* buf, int width, int height, int xstride, int ystride, int left, int top);