22 Q_PROPERTY(
bool visible READ visible WRITE setVisible NOTIFY visibleChanged)
23 Q_PROPERTY(
bool expanded READ expanded WRITE setExpanded NOTIFY expandChanged)
24 Q_PROPERTY(
int width READ width WRITE setWidth NOTIFY widthChanged)
25 Q_PROPERTY(QColor backgroundColor READ backgroundColor WRITE setBackgroundColor NOTIFY backgroundColorChanged)
31 QColor backgroundColor()
const
33 return m_backgroundColor;
35 void setBackgroundColor(QColor backgroundColor)
37 if (m_backgroundColor == backgroundColor)
40 m_backgroundColor = backgroundColor;
41 Q_EMIT backgroundColorChanged(m_backgroundColor);
49 void setVisible(
bool visible)
51 if (m_visible == visible)
55 Q_EMIT visibleChanged(m_visible);
63 void setExpanded(
bool expanded)
65 if (m_expanded == expanded)
68 m_expanded = expanded;
69 Q_EMIT expandChanged(m_expanded);
72 inline bool sectionVisible()
const
74 return m_visible ? m_expanded :
false;
82 void setWidth(
int width)
88 Q_EMIT widthChanged(m_width);
92 void backgroundColorChanged(QColor backgroundColor);
93 void visibleChanged(
bool visible);
94 void expandChanged(
bool expanded);
95 void widthChanged(
int width);
98 bool m_visible =
false;
99 bool m_expanded =
true;
101 QColor m_backgroundColor;