Public Functions
QLLabel(QWidget* parent = nullptr) | |
QLLabel(const QString& text, QWidget* parent = nullptr) | |
QLLabel(const QLGraphic& graphic, QWidget* parent = nullptr) | |
virtual QList<QLThemeable*> | child_qlthemeables(Qt::FindChildOptions options = Qt::FindDirectChildrenOnly) override |
LAttribute* | fill() const |
QLGraphic* | graphic() const |
void | set_font_size(int size) |
void | set_font_size_f(qreal size) |
virtual QSize | sizeHint() const override |
LAttribute* | text_color() const |
virtual void | update() override |
Protected Functions
void | paintEvent(QPaintEvent* event) override |
Detailed Description
Text Label | Graphic Label |
---|---|
![]() |
![]() |
A QLLabel is a QLabel and a QLThemeable that is used to display text or a QLGraphic.
Member Function Documentation
QLLabel(QWidget* parent = nullptr)
Constructs an empty label.
Constructs a label that displays graphic.
QList<QLThemeable*> child_qlthemeables(Qt::FindChildOptions options = Qt::FindDirectChildrenOnly)
Virtual
Override
Returns a list of child themeables.
This function overrides QLThemeable::child_qlthemeables() to include a pointer to the QLSvgRenderer, if the label uses a graphic that has one.
LAttribute* fill() const
Returns a pointer to the fill attribute of the label.
QLGraphic* graphic() const
Returns a pointer to the label's graphic.
Returns nullptr if the label does not have a graphic.
void set_font_size(int size)
Sets the size of the label's font.
void set_font_size_f(qreal size)
Sets the size of the label's font.
QSize sizeHint() const
Virtual
Override
Returns the recommended size for the label.
LAttribute* text_color() const
Returns a pointer to the text color attribute of the label.
void update()
Virtual
Override
Updates the header view.
This function overrides QLThemeable::update() to update the header view's style sheet.