Implements Label control.
You can find more information in comments below. Overrided methods can be found in corresponding base classes and interfaces.
class CLabel :public virtual ILabel, public CControl
{
public:
enum STATE // Possible states
{
stNormal,
stHovered,
stDisabled
};
public:
RectF getRenderRect() override;
String getCaption() override;
bool setAlign(const ALIGN value) override;
bool setConstraints(const RectF &value) override;
bool setSize(const PointF &value) override;
bool setCaption(const String &value) override;
bool setDPI(const Point &value) override;
// IControl methods
void Refresh(const bool refresh_children) override;
CLabel();
CLabel(IControl *parent);
CLabel(IForm *parent);
STATE getState(); // Return current state
bool isAutoSize() const; // Whether size should be calculated automatically to fit content. By default true
bool isMultiline() const; // Whether display as multiline text. By default false
// Return layout properties
TEXT_ALIGN getCaptionHorizontalAlign() const;
VERTICAL_ALIGN getCaptionVerticalAlign() const;
Color getColor(const STATE state) const;
Color getShadowColor(const STATE state) const;
PointF getShadowShift(const STATE state) const;
int getShadowRadius(const STATE state) const;
bool setAutoSize(const bool value); // Set whether size should be calculated automatically to fit content
bool setMultiline(const bool value);
// Set layout properties
bool setCaptionHorizontalAlign(const TEXT_ALIGN value);
bool setCaptionVerticalAlign(const VERTICAL_ALIGN value);
bool setColor(const STATE state, const Color &value);
bool setShadowColor(const STATE state, const Color &value);
bool setShadowShift(const STATE state, const PointF &value);
bool setShadowRadius(const STATE state, const int value);
};
Namespace: | nitisa::standard |
Include: | Standard/Controls/Label/Label.h |