QtBase  v6.3.1
Functions | Variables
doc_src_styles.cpp File Reference

Go to the source code of this file.

Functions

opt initFrom (q)
 [0] More...
 
 if (down) opt.state|
 
 if (tristate &&noChange) opt.state|
 
 if (q->testAttribute(Qt::WA_Hover) &&q->underMouse())
 
 if (widget->isEnabled()) state|
 
 if (widget->window() ->testAttribute(Qt::WA_KeyboardFocusChange)) state|
 
 if (widget->window() ->isActiveWindow()) state|
 
p drawControl (QStyle::CE_CheckBox, opt)
 
 drawPrimitive (PE_IndicatorCheckBox, &subopt, p, widget)
 
 drawControl (CE_CheckBoxLabel, &subopt, p, widget)
 
 if (btn->state &State_HasFocus)
 
 if (!styleHint(SH_UnderlineShortcut, btn, widget)) alignment|
 
 if (!btn->icon.isNull())
 
 if (!btn->text.isEmpty())
 

Variables

else opt state
 [0] More...
 
opt text = text
 
opt icon = icon
 
opt iconSize = q->iconSize()
 
 direction = widget->layoutDirection()
 
 rect = widget->rect()
 [4] More...
 
 palette = widget->palette()
 
 fontMetrics = widget->fontMetrics()
 
QStylePainter p (this)
 [1] More...
 
QStyleOptionButton opt = d->getStyleOption()
 
QStyleOptionButton subopt = *btn
 [2] More...
 
const QStyleOptionButtonbtn = qstyleoption_cast<const QStyleOptionButton *>(opt)
 [3] More...
 
uint alignment = visualAlignment(btn->direction, Qt::AlignLeft | Qt::AlignVCenter)
 
QPixmap pix
 
QRect textRect = btn->rect
 

Function Documentation

◆ drawControl() [1/2]

drawControl ( CE_CheckBoxLabel  ,
subopt,
p  ,
widget   
)

◆ drawControl() [2/2]

p drawControl ( QStyle::CE_CheckBox  ,
opt   
)

◆ drawPrimitive()

drawPrimitive ( PE_IndicatorCheckBox  ,
subopt,
p  ,
widget   
)
Here is the caller graph for this function:

◆ if() [1/10]

if ( !btn->icon.  isNull())

Definition at line 127 of file doc_src_styles.cpp.

Here is the call graph for this function:

◆ if() [2/10]

if ( !btn->text.  isEmpty())

Definition at line 135 of file doc_src_styles.cpp.

◆ if() [3/10]

if ( styleHintSH_UnderlineShortcut, btn, widget)

◆ if() [4/10]

if ( btn->state State_HasFocus)

Definition at line 110 of file doc_src_styles.cpp.

Here is the call graph for this function:

◆ if() [5/10]

if ( down  )

◆ if() [6/10]

if ( q->  testAttributeQt::WA_Hover) &&q->underMouse()

Definition at line 60 of file doc_src_styles.cpp.

◆ if() [7/10]

if ( tristate &&  noChange)

◆ if() [8/10]

if ( widget->  isEnabled())

◆ if() [9/10]

if ( widget->  window) ->isActiveWindow()

◆ if() [10/10]

if ( widget->  window) ->testAttribute(Qt::WA_KeyboardFocusChange)

◆ initFrom()

opt initFrom ( q  )

[0]

Variable Documentation

◆ alignment

uint alignment = visualAlignment(btn->direction, Qt::AlignLeft | Qt::AlignVCenter)

Definition at line 121 of file doc_src_styles.cpp.

◆ btn

[3]

[4]

Definition at line 120 of file doc_src_styles.cpp.

◆ direction

direction = widget->layoutDirection()

Definition at line 89 of file doc_src_styles.cpp.

◆ fontMetrics

fontMetrics = widget->fontMetrics()

Definition at line 92 of file doc_src_styles.cpp.

◆ icon

opt icon = icon

Definition at line 67 of file doc_src_styles.cpp.

◆ iconSize

opt iconSize = q->iconSize()

Definition at line 68 of file doc_src_styles.cpp.

◆ opt

QStyleOptionButton opt = d->getStyleOption()

Definition at line 98 of file doc_src_styles.cpp.

◆ p

[1]

[2]

◆ palette

palette = widget->palette()

Definition at line 91 of file doc_src_styles.cpp.

◆ pix

QPixmap pix

Definition at line 125 of file doc_src_styles.cpp.

◆ rect

rect rect QGraphicsRectItem rect = widget->rect()

[4]

[5]

Definition at line 90 of file doc_src_styles.cpp.

◆ state

state
Initial value:
= checked ? QStyle::State_On :
@ State_Off
Definition: qstyle.h:106
@ State_On
Definition: qstyle.h:108

[0]

[1]

Definition at line 58 of file doc_src_styles.cpp.

◆ subopt

[2]

[3]

Definition at line 104 of file doc_src_styles.cpp.

◆ text

opt text = text

Definition at line 66 of file doc_src_styles.cpp.

◆ textRect

QRect textRect = btn->rect

Definition at line 126 of file doc_src_styles.cpp.