CTK  0.1.0
The Common Toolkit is a community effort to provide support code for medical image analysis, surgical navigation, and related projects.
Public Member Functions | Protected Member Functions | Protected Attributes | Properties | List of all members
ctkPushButton Class Reference

#include <Libs/Widgets/ctkPushButton.h>

Inheritance diagram for ctkPushButton:
Inheritance graph
[legend]
Collaboration diagram for ctkPushButton:
Collaboration graph
[legend]

Public Member Functions

Qt::Alignment buttonTextAlignment () const
 
 ctkPushButton (const QIcon &icon, const QString &text, QWidget *parent=0)
 
 ctkPushButton (const QString &text, QWidget *parent=0)
 
 ctkPushButton (QWidget *parent=0)
 
Qt::Alignment iconAlignment () const
 
virtual QSize minimumSizeHint () const
 
void setButtonTextAlignment (Qt::Alignment buttonTextAlignment)
 
void setIconAlignment (Qt::Alignment iconAlignment)
 
virtual QSize sizeHint () const
 
virtual ~ctkPushButton ()
 

Protected Member Functions

 ctkPushButton (ctkPushButtonPrivate *, QWidget *parent=0)
 
virtual void paintEvent (QPaintEvent *)
 Reimplemented for internal reasons. More...
 

Protected Attributes

QScopedPointer< ctkPushButtonPrivate > d_ptr
 

Properties

Qt::Alignment buttonTextAlignment
 
Qt::Alignment iconAlignment
 

Detailed Description

Description ctkPushButton is an advanced QPushButton. It can control the alignment of text and icons.

Definition at line 37 of file ctkPushButton.h.

Constructor & Destructor Documentation

◆ ctkPushButton() [1/4]

ctkPushButton::ctkPushButton ( QWidget *  parent = 0)

◆ ctkPushButton() [2/4]

ctkPushButton::ctkPushButton ( const QString &  text,
QWidget *  parent = 0 
)

◆ ctkPushButton() [3/4]

ctkPushButton::ctkPushButton ( const QIcon &  icon,
const QString &  text,
QWidget *  parent = 0 
)

◆ ~ctkPushButton()

virtual ctkPushButton::~ctkPushButton ( )
virtual

◆ ctkPushButton() [4/4]

ctkPushButton::ctkPushButton ( ctkPushButtonPrivate *  ,
QWidget *  parent = 0 
)
protected

Member Function Documentation

◆ buttonTextAlignment()

Qt::Alignment ctkPushButton::buttonTextAlignment ( ) const

Return the buttonTextAlignment property value.

See also
buttonTextAlignment

◆ iconAlignment()

Qt::Alignment ctkPushButton::iconAlignment ( ) const

Return the iconAlignment property value.

See also
iconAlignment

◆ minimumSizeHint()

virtual QSize ctkPushButton::minimumSizeHint ( ) const
virtual

◆ paintEvent()

virtual void ctkPushButton::paintEvent ( QPaintEvent *  )
protectedvirtual

Reimplemented for internal reasons.

◆ setButtonTextAlignment()

void ctkPushButton::setButtonTextAlignment ( Qt::Alignment  buttonTextAlignment)

Set the buttonTextAlignment property value.

See also
buttonTextAlignment

◆ setIconAlignment()

void ctkPushButton::setIconAlignment ( Qt::Alignment  iconAlignment)

Set the iconAlignment property value.

See also
iconAlignment

◆ sizeHint()

virtual QSize ctkPushButton::sizeHint ( ) const
virtual

Member Data Documentation

◆ d_ptr

QScopedPointer<ctkPushButtonPrivate> ctkPushButton::d_ptr
protected

Definition at line 77 of file ctkPushButton.h.

Property Documentation

◆ buttonTextAlignment

Qt::Alignment ctkPushButton::buttonTextAlignment
readwrite

Set the alignment of the text on the button, Qt::AlignHCenter|Qt::AlignVCenter by default.

See also
textAlignment(), setTextAlignment(), iconAlignment

Definition at line 1 of file ctkPushButton.h.

◆ iconAlignment

Qt::Alignment ctkPushButton::iconAlignment
readwrite

Set the alignment of the icon with regard to the text. Qt::AlignLeft|Qt::AlignVCenter by default.

See also
iconAlignment(), setIconAlignment(), textAlignment

Definition at line 1 of file ctkPushButton.h.


The documentation for this class was generated from the following file: