tibia-client/src/framework/ui/uilabel.h

29 lines
537 B
C
Raw Normal View History

2011-04-08 07:10:00 +02:00
#ifndef UILABEL_H
#define UILABEL_H
2011-08-14 04:09:11 +02:00
#include "uiwidget.h"
2011-04-08 07:10:00 +02:00
2011-08-14 04:09:11 +02:00
class UILabel : public UIWidget
2011-04-08 07:10:00 +02:00
{
public:
virtual void setup();
2011-08-14 04:09:11 +02:00
virtual void render();
2011-04-10 02:51:35 +02:00
2011-08-14 04:09:11 +02:00
void resizeToText();
2011-08-23 17:09:50 +02:00
void setText(const std::string& text);
2011-05-12 00:16:11 +02:00
void setAlign(AlignmentFlag align) { m_align = align; }
2011-04-17 02:36:58 +02:00
2011-08-14 04:09:11 +02:00
std::string getText() const { return m_text; }
AlignmentFlag getAlign() const { return m_align; }
2011-04-22 00:44:30 +02:00
protected:
virtual void onStyleApply(const OTMLNodePtr& styleNode);
2011-04-10 02:51:35 +02:00
private:
std::string m_text;
2011-05-12 00:16:11 +02:00
AlignmentFlag m_align;
2011-04-08 07:10:00 +02:00
};
2011-08-14 04:09:11 +02:00
#endif