summaryrefslogtreecommitdiff
path: root/src/gui/widgets/radiobutton.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-12-27 14:42:15 +0300
committerAndrei Karas <akaras@inbox.ru>2012-12-27 23:15:05 +0300
commit60add2c149c9c61bfbede5ae92cfe216927aca8a (patch)
tree9ded097faa108eb07b9ca1c8ce4490882e238a44 /src/gui/widgets/radiobutton.cpp
parent2babe1d6491f5231b0e97349ccb198b92bb90ba9 (diff)
downloadmanaplus-60add2c149c9c61bfbede5ae92cfe216927aca8a.tar.gz
manaplus-60add2c149c9c61bfbede5ae92cfe216927aca8a.tar.bz2
manaplus-60add2c149c9c61bfbede5ae92cfe216927aca8a.tar.xz
manaplus-60add2c149c9c61bfbede5ae92cfe216927aca8a.zip
Improve a bit draw speed in other controls.
Diffstat (limited to 'src/gui/widgets/radiobutton.cpp')
-rw-r--r--src/gui/widgets/radiobutton.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/gui/widgets/radiobutton.cpp b/src/gui/widgets/radiobutton.cpp
index 1c56f787e..b2f38db4a 100644
--- a/src/gui/widgets/radiobutton.cpp
+++ b/src/gui/widgets/radiobutton.cpp
@@ -152,10 +152,11 @@ void RadioButton::draw(gcn::Graphics* graphics)
BLOCK_START("RadioButton::draw")
drawBox(graphics);
- graphics->setFont(getFont());
+ gcn::Font *const font = getFont();
+ graphics->setFont(font);
graphics->setColor(mForegroundColor);
- graphics->drawText(getCaption(), mPadding + mImageSize + mSpacing,
+ font->drawString(graphics, mCaption, mPadding + mImageSize + mSpacing,
mPadding);
BLOCK_END("RadioButton::draw")
}