summaryrefslogtreecommitdiff
path: root/utils/themeeditor/graphics/rbfont.cpp
diff options
context:
space:
mode:
authorRobert Bieber <robby@bieberphoto.com>2010-07-07 06:50:30 +0000
committerRobert Bieber <robby@bieberphoto.com>2010-07-07 06:50:30 +0000
commit3214e3710ad0d73c1b775b8af002763cbb42382c (patch)
tree67355953e4e3079d0a3ab4ff688dfa6d413d6f36 /utils/themeeditor/graphics/rbfont.cpp
parentce5ee193d41061a6b8c9a2b87dc8a43303f82ab9 (diff)
downloadrockbox-3214e3710ad0d73c1b775b8af002763cbb42382c.tar.gz
rockbox-3214e3710ad0d73c1b775b8af002763cbb42382c.zip
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
Diffstat (limited to 'utils/themeeditor/graphics/rbfont.cpp')
-rw-r--r--utils/themeeditor/graphics/rbfont.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/utils/themeeditor/graphics/rbfont.cpp b/utils/themeeditor/graphics/rbfont.cpp
index 1c2739d118..e8bff40e13 100644
--- a/utils/themeeditor/graphics/rbfont.cpp
+++ b/utils/themeeditor/graphics/rbfont.cpp
@@ -155,7 +155,8 @@ RBFont::~RBFont()
155 delete[] widthData; 155 delete[] widthData;
156} 156}
157 157
158RBText* RBFont::renderText(QString text, QColor color, QGraphicsItem *parent) 158RBText* RBFont::renderText(QString text, QColor color, int viewWidth,
159 QGraphicsItem *parent)
159{ 160{
160 int firstChar = header.value("firstchar").toInt(); 161 int firstChar = header.value("firstchar").toInt();
161 int height = header.value("height").toInt(); 162 int height = header.value("height").toInt();
@@ -221,6 +222,6 @@ RBText* RBFont::renderText(QString text, QColor color, QGraphicsItem *parent)
221 startX += widths[i]; 222 startX += widths[i];
222 } 223 }
223 224
224 return new RBText(image, parent); 225 return new RBText(image, viewWidth, parent);
225 226
226} 227}