20 Q_PROPERTY( QVector< QskLabelData > options READ options
21 WRITE setOptions NOTIFY optionsChanged )
23 Q_PROPERTY(
int currentIndex READ currentIndex
24 WRITE setCurrentIndex NOTIFY currentIndexChanged )
26 Q_PROPERTY( QString currentText READ currentText
27 NOTIFY currentIndexChanged USER
true)
29 Q_PROPERTY(
int count READ count )
31 Q_PROPERTY( QString placeholderText READ placeholderText
32 WRITE setPlaceholderText NOTIFY placeholderTextChanged )
34 Q_PROPERTY(
int indexInPopup READ indexInPopup
35 NOTIFY indexInPopupChanged )
37 Q_PROPERTY(
bool pressed READ isPressed
38 WRITE setPressed NOTIFY pressedChanged FINAL )
43 QSK_SUBCONTROLS( Panel, Icon, Text, StatusIndicator )
44 QSK_STATES( Pressed, PopupOpen )
50 void setPressed(
bool on );
51 bool isPressed()
const;
53 void setPopupOpen(
bool );
54 bool isPopupOpen()
const;
59 int addOption(
const QUrl&,
const QString& );
60 int addOption(
const QString&,
const QString& );
63 void setOptions(
const QVector< QskLabelData >& );
64 void setOptions(
const QStringList& );
66 QVector< QskLabelData > options()
const;
71 int currentIndex()
const;
72 QString currentText()
const;
75 virtual int indexInPopup()
const;
78 QString textAt(
int )
const;
80 QString placeholderText()
const;
81 void setPlaceholderText(
const QString& );
84 void setCurrentIndex(
int );
89 void pressedChanged(
bool );
91 void currentIndexChanged(
int );
92 void indexInPopupChanged(
int );
94 void optionsChanged();
95 void placeholderTextChanged(
const QString& );
98 void mousePressEvent( QMouseEvent* )
override;
99 void mouseReleaseEvent( QMouseEvent* )
override;
101 void keyPressEvent( QKeyEvent* )
override;
102 void keyReleaseEvent( QKeyEvent* )
override;
104 void wheelEvent( QWheelEvent* )
override;
110 virtual void openPopup();
111 virtual void closePopup();
115 std::unique_ptr< PrivateData > m_data;