summaryrefslogtreecommitdiff
path: root/src/interface/Label.cpp
diff options
context:
space:
mode:
authorSimon Robertshaw <simon@hardwired.org.uk>2012-01-29 14:44:36 (GMT)
committer Simon Robertshaw <simon@hardwired.org.uk>2012-01-29 14:44:36 (GMT)
commit680a36549adaed0c3ce7e8906fadbdf190b0b3b0 (patch)
tree21ca16411c1687bb212369a59c5f3de2a0cf023b /src/interface/Label.cpp
parent7c53ca7799832920066c23cfad2f1d7fa82233c7 (diff)
downloadpowder-680a36549adaed0c3ce7e8906fadbdf190b0b3b0.zip
powder-680a36549adaed0c3ce7e8906fadbdf190b0b3b0.tar.gz
Background retrieval of save info and save list.
Diffstat (limited to 'src/interface/Label.cpp')
-rw-r--r--src/interface/Label.cpp13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/interface/Label.cpp b/src/interface/Label.cpp
index 6fc47e2..e5f99a2 100644
--- a/src/interface/Label.cpp
+++ b/src/interface/Label.cpp
@@ -6,7 +6,7 @@
using namespace ui;
-Label::Label(Window* parent_state, std::string labelText):
+/*Label::Label(Window* parent_state, std::string labelText):
Component(parent_state),
text(labelText),
textPosition(ui::Point(0, 0)),
@@ -14,19 +14,20 @@ Label::Label(Window* parent_state, std::string labelText):
textHAlign(AlignCentre)
{
TextPosition();
-}
+}*/
Label::Label(Point position, Point size, std::string labelText):
Component(position, size),
text(labelText),
textPosition(ui::Point(0, 0)),
textVAlign(AlignMiddle),
- textHAlign(AlignCentre)
+ textHAlign(AlignCentre),
+ textColour(255, 255, 255)
{
TextPosition();
}
-Label::Label(std::string labelText):
+/*Label::Label(std::string labelText):
Component(),
text(labelText),
textPosition(ui::Point(0, 0)),
@@ -34,7 +35,7 @@ Label::Label(std::string labelText):
textHAlign(AlignCentre)
{
TextPosition();
-}
+}*/
Label::~Label()
{
@@ -80,6 +81,6 @@ void Label::SetText(std::string text)
void Label::Draw(const Point& screenPos)
{
Graphics * g = Engine::Ref().g;
- g->drawtext(screenPos.X+textPosition.X, screenPos.Y+textPosition.Y, text, 255, 255, 255, 255);
+ g->drawtext(screenPos.X+textPosition.X, screenPos.Y+textPosition.Y, text, textColour.Red, textColour.Green, textColour.Blue, 255);
}