#include <rexpanderbox.h>
Definition at line 103 of file rexpanderbox.h.
◆ RArrowClickLabel()
| KDcrawIface::RArrowClickLabel::RArrowClickLabel |
( |
QWidget *const | parent = 0 | ) |
|
Definition at line 172 of file rexpanderbox.cpp.
174{
175 setCursor(Qt::PointingHandCursor);
176 setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);
179}
Qt::ArrowType m_arrowType
References m_margin, and m_size.
◆ ~RArrowClickLabel()
| KDcrawIface::RArrowClickLabel::~RArrowClickLabel |
( |
| ) |
|
|
override |
◆ arrowType()
| Qt::ArrowType KDcrawIface::RArrowClickLabel::arrowType |
( |
| ) |
const |
◆ leftClicked
| void KDcrawIface::RArrowClickLabel::leftClicked |
( |
| ) |
|
|
signal |
◆ mousePressEvent()
| void KDcrawIface::RArrowClickLabel::mousePressEvent |
( |
QMouseEvent * | event | ) |
|
|
overrideprotected |
Definition at line 196 of file rexpanderbox.cpp.
197{
198
199
200
201
202 if (event->button() == Qt::LeftButton)
203 {
204 event->accept();
205 }
206}
◆ mouseReleaseEvent()
| void KDcrawIface::RArrowClickLabel::mouseReleaseEvent |
( |
QMouseEvent * | event | ) |
|
|
overrideprotected |
◆ paintEvent()
| void KDcrawIface::RArrowClickLabel::paintEvent |
( |
QPaintEvent * | event | ) |
|
|
overrideprotected |
Definition at line 216 of file rexpanderbox.cpp.
217{
218
219
220
222
223 QStyleOptionFrame opt;
224 opt.initFrom(this);
225 opt.lineWidth = 2;
226 opt.midLineWidth = 0;
227
228
229
230
231
232
234 return;
235
237 return;
238
239 unsigned int x = 0,
y = 0;
241 {
244 }
246 {
249 }
251 {
254 }
255 else
256 {
259 }
260
261
262
263
264
265
266
267
268
269 QStyle::PrimitiveElement e = QStyle::PE_IndicatorArrowLeft;
270
272 {
273 case Qt::LeftArrow:
274 e = QStyle::PE_IndicatorArrowLeft;
275 break;
276 case Qt::RightArrow:
277 e = QStyle::PE_IndicatorArrowRight;
278 break;
279 case Qt::UpArrow:
280 e = QStyle::PE_IndicatorArrowUp;
281 break;
282 case Qt::DownArrow:
283 e = QStyle::PE_IndicatorArrowDown;
284 break;
285 case Qt::NoArrow:
286 break;
287 }
288
289 opt.state |= QStyle::State_Enabled;
291
292 style()->drawPrimitive( e, &opt, &
p,
this );
293}
References m_arrowType, m_margin, m_size, and p.
◆ setArrowType()
| void KDcrawIface::RArrowClickLabel::setArrowType |
( |
Qt::ArrowType | arrowType | ) |
|
◆ sizeHint()
| QSize KDcrawIface::RArrowClickLabel::sizeHint |
( |
| ) |
const |
|
override |
◆ m_arrowType
| Qt::ArrowType KDcrawIface::RArrowClickLabel::m_arrowType |
|
protected |
◆ m_margin
| int KDcrawIface::RArrowClickLabel::m_margin |
|
protected |
◆ m_size
| int KDcrawIface::RArrowClickLabel::m_size |
|
protected |
The documentation for this class was generated from the following files: