[vdr] osd->DrawText with \n and \t
Patrick Fischer
patrick_fischer at gmx.de
Wed Mar 1 14:39:32 CET 2006
Hello
I have some questions about the DrawText from the osd.
Is there any possibility to use newlines(\n) or tabs(\t)?
I have looked at the source and I found this method(part of
cBitmap::DrawText):
while (s && *s) {
const cFont::tCharData *CharData = Font->CharData(*s++);
if (limit && int(x + CharData->width) > limit)
break; // we don't draw partial characters
if (int(x + CharData->width) > 0) {
for (int row = 0; row < h; row++) {
cFont::tPixelData PixelData = CharData->lines[row];
for (int col = CharData->width; col-- > 0; ) {
if (ColorBg != clrTransparent || (PixelData & 1))
SetIndex(x + col, y + row, (PixelData & 1) ? fg
: bg);
PixelData >>= 1;
}
}
}
x += CharData->width;
if (x > width - 1)
break;
}
}
If there i no other possibility to use text over two lines i would like
to patch the code, but maybe there is an other way....
I need \n but maybe \t would be nice too.
Greetings
Patrick
More information about the vdr
mailing list