summaryrefslogtreecommitdiffstats
path: root/src/ui/label.cpp
diff options
context:
space:
mode:
authorPiotr Dziwinski <piotrdz@gmail.com>2012-09-18 17:52:36 +0200
committerPiotr Dziwinski <piotrdz@gmail.com>2012-09-18 17:52:36 +0200
commitda5d4edeb3a41462ec987cb4994a6897823f3f76 (patch)
tree64f213a687681373bee28eb5283fc9023bee6b2b /src/ui/label.cpp
parent4b67386a697c27186b6eb4809bea9547372dacd7 (diff)
downloadcolobot-da5d4edeb3a41462ec987cb4994a6897823f3f76.tar.gz
colobot-da5d4edeb3a41462ec987cb4994a6897823f3f76.tar.bz2
colobot-da5d4edeb3a41462ec987cb4994a6897823f3f76.zip
Fixed invalid text alignment
Diffstat (limited to 'src/ui/label.cpp')
-rw-r--r--src/ui/label.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ui/label.cpp b/src/ui/label.cpp
index c5da211..d7b9cbe 100644
--- a/src/ui/label.cpp
+++ b/src/ui/label.cpp
@@ -69,9 +69,9 @@ void CLabel::Draw()
pos.y = m_pos.y + m_dim.y / 2.0f;
switch (m_textAlign) {
- case Gfx::TEXT_ALIGN_RIGHT: pos.x = m_pos.x; break;
+ case Gfx::TEXT_ALIGN_LEFT: pos.x = m_pos.x; break;
case Gfx::TEXT_ALIGN_CENTER: pos.x = m_pos.x + m_dim.x / 2.0f; break;
- case Gfx::TEXT_ALIGN_LEFT: pos.x = m_pos.x + m_dim.x; break;
+ case Gfx::TEXT_ALIGN_RIGHT: pos.x = m_pos.x + m_dim.x; break;
}
m_engine->GetText()->DrawText(std::string(m_name), m_fontType, m_fontSize, pos, m_dim.x, m_textAlign, 0);