summaryrefslogtreecommitdiff
path: root/plugingui/label.cc
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2015-11-20 20:03:18 +0100
committerBent Bisballe Nyeng <deva@aasimon.org>2015-11-20 20:03:18 +0100
commit3734f5d3c741e877c49ff1c99ce67cb4a764023b (patch)
tree5fcbcc3d084d5c8d49bd40d726481ca92d54bd5e /plugingui/label.cc
parentc1973bc4d4ec9d8d18a690359a2d649905e35264 (diff)
Only initialise Font once.
Diffstat (limited to 'plugingui/label.cc')
-rw-r--r--plugingui/label.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugingui/label.cc b/plugingui/label.cc
index 1de715b..18ba1e8 100644
--- a/plugingui/label.cc
+++ b/plugingui/label.cc
@@ -33,6 +33,7 @@ namespace GUI {
Label::Label(GUI::Widget *parent)
: Widget(parent)
+ , font(":fontemboss.png")
{
}
@@ -50,7 +51,6 @@ void Label::repaintEvent(GUI::RepaintEvent* repaintEvent)
p.setColour(Colour(1));
- Font font(":fontemboss.png");
p.drawText(10, (height() + font.textHeight()) / 2, font, _text, true);
}