qtoolbarseparator.cpp

Absolute File Name:/home/qt/qt5_coco/qt5/qtbase/src/widgets/widgets/qtoolbarseparator.cpp
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4-
5-
6-
7void QToolBarSeparator::initStyleOption(QStyleOption *option) const-
8{-
9 option->initFrom(this);-
10 if (orientation() == Qt::Horizontal
orientation() ...Qt::HorizontalDescription
TRUEnever evaluated
FALSEnever evaluated
)
0
11 option->state |= QStyle::State_Horizontal;
never executed: option->state |= QStyle::State_Horizontal;
0
12}
never executed: end of block
0
13-
14QToolBarSeparator::QToolBarSeparator(QToolBar *parent)-
15 : QWidget(parent), orient(parent->orientation())-
16{ setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Minimum); }
never executed: end of block
0
17-
18void QToolBarSeparator::setOrientation(Qt::Orientation orientation)-
19{-
20 orient = orientation;-
21 update();-
22}
never executed: end of block
0
23-
24Qt::Orientation QToolBarSeparator::orientation() const-
25{ return
never executed: return orient;
orient;
never executed: return orient;
}
0
26-
27QSize QToolBarSeparator::sizeHint() const-
28{-
29 QStyleOption opt;-
30 initStyleOption(&opt);-
31 const int extent = style()->pixelMetric(QStyle::PM_ToolBarSeparatorExtent, &opt, parentWidget());-
32 return
never executed: return QSize(extent, extent);
QSize(extent, extent);
never executed: return QSize(extent, extent);
0
33}-
34-
35void QToolBarSeparator::paintEvent(QPaintEvent *)-
36{-
37 QPainter p(this);-
38 QStyleOption opt;-
39 initStyleOption(&opt);-
40 style()->drawPrimitive(QStyle::PE_IndicatorToolBarSeparator, &opt, &p, parentWidget());-
41}
never executed: end of block
0
42-
43-
44-
Switch to Source codePreprocessed file

Generated by Squish Coco Non-Commercial 4.3.0-BETA-master-30-08-2018-4cb69e9