CALCDNumber Class Reference

#include <lcdnumber.h>

Inheritance diagram for CALCDNumber:

Inheritance graph
[legend]

List of all members.

Signals

void valChanged (int iVal)

Public Member Functions

 CALCDNumber (int iMin, int iMax, QWidget *poParent=0, QString oText="")
void setRealValue (int val)
int getRealValue ()
void setMin (int iMin)
void setMax (int iMax)
bool isZero ()

Protected Member Functions

virtual void mousePressEvent (QMouseEvent *poEvt)
virtual void wheelEvent (QWheelEvent *poEvt)
virtual void contextMenuEvent (QContextMenuEvent *poEvt)

Private Attributes

int min_
int max_
QActionnumDisplay_
int realValue_
QString toolTipText_


Detailed Description

Definition at line 34 of file lcdnumber.h.


Constructor & Destructor Documentation

CALCDNumber::CALCDNumber ( int  iMin,
int  iMax,
QWidget poParent = 0,
QString  oText = "" 
)

Constructs the number display

Parameters:
iMin minimal number
iMax maximal number
oToolTipText text to be displayed as tool tip
oShortCut shortcut for a quick change of the number
poParent parent widget
oText name of the widget

Definition at line 30 of file lcdnumber.cpp.

References max_, min_, and setRealValue().

Here is the call graph for this function:


Member Function Documentation

void CALCDNumber::setRealValue ( int  val  ) 

Sets the current value of the number display

Parameters:
iVal new value to be set

Definition at line 42 of file lcdnumber.cpp.

References max_, realValue_, and valChanged().

Referenced by CALCDNumber(), mousePressEvent(), CAMainWin::on_uiInsertPlayable_toggled(), CAMainWin::on_uiNewVoice_triggered(), CAMainWin::on_uiRemoveVoice_triggered(), CAMainWin::scoreViewPortKeyPress(), CAMainWin::scoreViewPortMousePress(), setMax(), setMin(), CAMainWin::setMode(), CAMainWin::updatePlayableToolBar(), and wheelEvent().

Here is the caller graph for this function:

int CALCDNumber::getRealValue (  ) 

Gets the current value of the number display

Definition at line 59 of file lcdnumber.cpp.

References realValue_.

Referenced by CAMainWin::currentVoice(), isZero(), mousePressEvent(), CAMainWin::on_uiInsertPlayable_toggled(), CAMainWin::on_uiLilyPondSource_triggered(), CAMainWin::on_uiRedo_toggled(), CAMainWin::on_uiUndo_toggled(), CAMainWin::pasteAt(), setMax(), setMin(), CAMainWin::updateVoiceToolBar(), and wheelEvent().

Here is the caller graph for this function:

void CALCDNumber::setMin ( int  iMin  ) 

Sets the minimum value of the number display

Parameters:
iMin new minimum value to be set

Definition at line 63 of file lcdnumber.cpp.

References getRealValue(), max_, min_, and setRealValue().

Here is the call graph for this function:

void CALCDNumber::setMax ( int  iMax  ) 

Sets the maximum value of the number display

Parameters:
iMax new maximum value to be set

Definition at line 72 of file lcdnumber.cpp.

References getRealValue(), max_, min_, and setRealValue().

Referenced by CAMainWin::scoreViewPortMousePress(), and CAMainWin::updateVoiceToolBar().

Here is the call graph for this function:

Here is the caller graph for this function:

bool CALCDNumber::isZero (  ) 

Checks if the value is 0 (or false if LCD number wasn't plugged)

Definition at line 81 of file lcdnumber.cpp.

References getRealValue().

Here is the call graph for this function:

void CALCDNumber::valChanged ( int  iVal  )  [signal]

Actually sends out the changed value if triggered via mouse press event

Parameters:
iVal new value

Referenced by setRealValue().

void CALCDNumber::mousePressEvent ( QMouseEvent *  poEvt  )  [protected, virtual]

Event being performed when a mouse button was pressed

Parameters:
poEvt Necessary information about the event

Definition at line 86 of file lcdnumber.cpp.

References getRealValue(), max_, min_, and setRealValue().

Here is the call graph for this function:

void CALCDNumber::wheelEvent ( QWheelEvent *  poEvt  )  [protected, virtual]

Event being performed when a wheel was moved

Parameters:
poEvt Necessary information about the event

Definition at line 102 of file lcdnumber.cpp.

References getRealValue(), max_, min_, and setRealValue().

Here is the call graph for this function:

virtual void CALCDNumber::contextMenuEvent ( QContextMenuEvent *  poEvt  )  [inline, protected, virtual]

Overrides QMainWindow::contextMenuEvent() to prevent showing the context menu when the LCD widget is right-clicked (in a toolbar).

Parameters:
poEvt Pointer to event info.

Definition at line 113 of file lcdnumber.h.


Member Data Documentation

int CALCDNumber::min_ [private]

Definition at line 115 of file lcdnumber.h.

Referenced by CALCDNumber(), mousePressEvent(), setMax(), setMin(), and wheelEvent().

int CALCDNumber::max_ [private]

Definition at line 115 of file lcdnumber.h.

Referenced by CALCDNumber(), mousePressEvent(), setMax(), setMin(), setRealValue(), and wheelEvent().

QAction* CALCDNumber::numDisplay_ [private]

Definition at line 116 of file lcdnumber.h.

int CALCDNumber::realValue_ [private]

Definition at line 117 of file lcdnumber.h.

Referenced by getRealValue(), and setRealValue().

QString CALCDNumber::toolTipText_ [private]

Definition at line 118 of file lcdnumber.h.


The documentation for this class was generated from the following files:
Generated on Sat Feb 9 13:15:13 2008 for Canorus by  doxygen 1.5.3