vdr
2.2.0
|
#include <font.h>
Public Member Functions | |
cTextWrapper (void) | |
cTextWrapper (const char *Text, const cFont *Font, int Width) | |
~cTextWrapper () | |
void | Set (const char *Text, const cFont *Font, int Width) |
const char * | Text (void) |
int | Lines (void) |
const char * | GetLine (int Line) |
Private Attributes | |
char * | text |
char * | eol |
int | lines |
int | lastLine |
cTextWrapper::cTextWrapper | ( | const char * | Text, |
const cFont * | Font, | ||
int | Width | ||
) |
const char * cTextWrapper::GetLine | ( | int | Line | ) |
|
inline |
Returns the actual number of lines needed to display the full wrapped text.
Definition at line 113 of file font.h.
Referenced by cTextScroller::Total().
void cTextWrapper::Set | ( | const char * | Text, |
const cFont * | Font, | ||
int | Width | ||
) |
Wraps the Text to make it fit into the area defined by the given Width when displayed with the given Font.
Wrapping is done by inserting the necessary number of newline characters into the string.
Definition at line 558 of file font.c.
References MALLOC, stripspace(), Utf8CharGet(), SI::Utf8CharLen(), and cFont::Width().
const char * cTextWrapper::Text | ( | void | ) |