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 Types | Public Slots | Signals | Public Member Functions | Protected Member Functions | Protected Attributes | Properties | List of all members
ctkAxesWidget Class Reference

#include <Libs/Widgets/ctkAxesWidget.h>

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

Public Types

enum  Axis {
  None =0 , Right , Left , Superior ,
  Inferior , Anterior , Posterior
}
 

Public Slots

QStringList axesLabels () const
 Get the axes labels. More...
 
virtual bool hasHeightForWidth () const
 
virtual int heightForWidth (int width) const
 
virtual QSize minimumSizeHint () const
 Size hints. More...
 
void setAutoReset (bool reset)
 Set the autoReset property to None anytime the currentAxis is changed. More...
 
bool setAxesLabels (const QStringList &labels)
 Set the axes labels. More...
 
void setCurrentAxis (Axis axis)
 
void setCurrentAxisToNone ()
 Utility slot that set the current axis to none. More...
 
virtual QSize sizeHint () const
 

Signals

void currentAxisChanged (ctkAxesWidget::Axis axis)
 

Public Member Functions

bool autoReset () const
 
 ctkAxesWidget (QWidget *parent=0)
 
Axis currentAxis () const
 Current selected axis. None by default. More...
 
virtual ~ctkAxesWidget ()
 

Protected Member Functions

void mouseMoveEvent (QMouseEvent *mouseEvent)
 
void mousePressEvent (QMouseEvent *mouseEvent)
 
void mouseReleaseEvent (QMouseEvent *mouseEvent)
 
void paintEvent (QPaintEvent *)
 

Protected Attributes

QScopedPointer< ctkAxesWidgetPrivate > d_ptr
 

Properties

bool autoReset
 
QStringList axesLabels
 
Axis currentAxis
 

Detailed Description

Definition at line 34 of file ctkAxesWidget.h.

Member Enumeration Documentation

◆ Axis

Enumerator
None 
Right 
Left 
Superior 
Inferior 
Anterior 
Posterior 

Definition at line 43 of file ctkAxesWidget.h.

Constructor & Destructor Documentation

◆ ctkAxesWidget()

ctkAxesWidget::ctkAxesWidget ( QWidget *  parent = 0)

◆ ~ctkAxesWidget()

virtual ctkAxesWidget::~ctkAxesWidget ( )
virtual

Member Function Documentation

◆ autoReset()

bool ctkAxesWidget::autoReset ( ) const

If autoReset is true, anytime the current axis is changed, the current axis is automatically reset to None. False by default.

◆ axesLabels

QStringList ctkAxesWidget::axesLabels ( ) const
slot

Get the axes labels.

◆ currentAxis()

Axis ctkAxesWidget::currentAxis ( ) const

Current selected axis. None by default.

◆ currentAxisChanged

void ctkAxesWidget::currentAxisChanged ( ctkAxesWidget::Axis  axis)
signal

◆ hasHeightForWidth

virtual bool ctkAxesWidget::hasHeightForWidth ( ) const
virtualslot

◆ heightForWidth

virtual int ctkAxesWidget::heightForWidth ( int  width) const
virtualslot

◆ minimumSizeHint

virtual QSize ctkAxesWidget::minimumSizeHint ( ) const
virtualslot

Size hints.

◆ mouseMoveEvent()

void ctkAxesWidget::mouseMoveEvent ( QMouseEvent *  mouseEvent)
protected

◆ mousePressEvent()

void ctkAxesWidget::mousePressEvent ( QMouseEvent *  mouseEvent)
protected

◆ mouseReleaseEvent()

void ctkAxesWidget::mouseReleaseEvent ( QMouseEvent *  mouseEvent)
protected

◆ paintEvent()

void ctkAxesWidget::paintEvent ( QPaintEvent *  )
protected

◆ setAutoReset

void ctkAxesWidget::setAutoReset ( bool  reset)
slot

Set the autoReset property to None anytime the currentAxis is changed.

◆ setAxesLabels

bool ctkAxesWidget::setAxesLabels ( const QStringList &  labels)
slot

Set the axes labels.

At least 6 labels are required. If more than 6 labels are given, the additional strings will be ignored.

Returns True if the given labels are either successfully set or if the current values match the provided ones.

See also
axesLabels()

◆ setCurrentAxis

void ctkAxesWidget::setCurrentAxis ( Axis  axis)
slot

Select the current axis and emit the currentAxisChanged signal if it is a new one. Warning, if autoReset is true, the currentAxis will automatically be reset to None.

◆ setCurrentAxisToNone

void ctkAxesWidget::setCurrentAxisToNone ( )
slot

Utility slot that set the current axis to none.

◆ sizeHint

virtual QSize ctkAxesWidget::sizeHint ( ) const
virtualslot

Member Data Documentation

◆ d_ptr

QScopedPointer<ctkAxesWidgetPrivate> ctkAxesWidget::d_ptr
protected

Definition at line 111 of file ctkAxesWidget.h.

Property Documentation

◆ autoReset

bool ctkAxesWidget::autoReset
readwrite

Definition at line 1 of file ctkAxesWidget.h.

◆ axesLabels

QStringList ctkAxesWidget::axesLabels
readwrite

Definition at line 1 of file ctkAxesWidget.h.

◆ currentAxis

Axis ctkAxesWidget::currentAxis
readwrite

Definition at line 1 of file ctkAxesWidget.h.


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