forked from len0rd/rockbox
Theme Editor: Made all lines of text render as a single graphic, viewport size limits now enforced on text width
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27327 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
ce5ee193d4
commit
3214e3710a
6 changed files with 59 additions and 38 deletions
|
@ -155,7 +155,8 @@ RBFont::~RBFont()
|
|||
delete[] widthData;
|
||||
}
|
||||
|
||||
RBText* RBFont::renderText(QString text, QColor color, QGraphicsItem *parent)
|
||||
RBText* RBFont::renderText(QString text, QColor color, int viewWidth,
|
||||
QGraphicsItem *parent)
|
||||
{
|
||||
int firstChar = header.value("firstchar").toInt();
|
||||
int height = header.value("height").toInt();
|
||||
|
@ -221,6 +222,6 @@ RBText* RBFont::renderText(QString text, QColor color, QGraphicsItem *parent)
|
|||
startX += widths[i];
|
||||
}
|
||||
|
||||
return new RBText(image, parent);
|
||||
return new RBText(image, viewWidth, parent);
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue