casa
$Rev:20696$
|
Class which stores WorldCanvas motion event information. More...
#include <WCMotionEvent.h>
Public Member Functions | |
WCMotionEvent (WorldCanvas *wc, const uInt &modifiers, const Int &pixX, const Int &pixY, const Double &linX, const Double &linY, const Vector< Double > &world) | |
Constructor taking a pointer to the WorldCanvas for which the event is valid, the state of the keyboard and pointer modifiers, and the pixel, linear and world coordinates of the event. | |
WCMotionEvent (const WCMotionEvent &other) | |
copy constructor. | |
virtual | ~WCMotionEvent () |
Destructor. | |
virtual Int | pixX () const |
The x and y pixel position of the pointer when the event occurred. | |
virtual Int | pixY () const |
virtual Double | linX () const |
The x and y linear coordinates of the event. | |
virtual Double | linY () const |
virtual const Vector< Double > & | world () const |
The world coordinates describing where the event occurred. | |
virtual uInt | modifiers () const |
Return the state of the "modifiers": this is made up of mask bits referring to various keys on the keyboard (eg. | |
Protected Member Functions | |
WCMotionEvent () | |
(Required) default constructor. | |
WCMotionEvent & | operator= (const WCMotionEvent &other) |
(Required) copy assignment. | |
Private Attributes | |
Int | itsPixX |
Store the pixel position of the event here. | |
Int | itsPixY |
Double | itsLinX |
Store the linear position of the event here. | |
Double | itsLinY |
Vector< Double > | itsWorld |
Store the world position of the event here. | |
uInt | itsModifiers |
Store the button and keyboard modifier masks here. | |
Friends | |
class | QtDisplayPanel |
Class which stores WorldCanvas motion event information.
Public interface
"WCMotionEvent" is a contraction and concatentation of "WorldCanvas", "Motion" and "Event", and describes motion events occuring on WorldCanvases.
This class adds to the information stored in the WorldCanvasEvent class. It adds informatino describing the current position of the mouse or pointing device, and the state of the keyboard modifiers (including the mouse buttons).
A compact way of passing motion event information around the WorldCanvas-oriented display classes was needed, with a functional but tight and efficient interface.
.
Definition at line 79 of file WCMotionEvent.h.
casa::WCMotionEvent::WCMotionEvent | ( | WorldCanvas * | wc, |
const uInt & | modifiers, | ||
const Int & | pixX, | ||
const Int & | pixY, | ||
const Double & | linX, | ||
const Double & | linY, | ||
const Vector< Double > & | world | ||
) |
Constructor taking a pointer to the WorldCanvas for which the event is valid, the state of the keyboard and pointer modifiers, and the pixel, linear and world coordinates of the event.
casa::WCMotionEvent::WCMotionEvent | ( | const WCMotionEvent & | other | ) |
copy constructor.
virtual casa::WCMotionEvent::~WCMotionEvent | ( | ) | [virtual] |
Destructor.
casa::WCMotionEvent::WCMotionEvent | ( | ) | [protected] |
(Required) default constructor.
virtual Double casa::WCMotionEvent::linX | ( | ) | const [inline, virtual] |
The x and y linear coordinates of the event.
Definition at line 108 of file WCMotionEvent.h.
References itsLinX.
virtual Double casa::WCMotionEvent::linY | ( | ) | const [inline, virtual] |
Definition at line 110 of file WCMotionEvent.h.
References itsLinY.
virtual uInt casa::WCMotionEvent::modifiers | ( | ) | const [inline, virtual] |
Return the state of the "modifiers": this is made up of mask bits referring to various keys on the keyboard (eg.
Control, Shift, etc.) and the mouse buttons.
Definition at line 121 of file WCMotionEvent.h.
References itsModifiers.
WCMotionEvent& casa::WCMotionEvent::operator= | ( | const WCMotionEvent & | other | ) | [protected] |
(Required) copy assignment.
virtual Int casa::WCMotionEvent::pixX | ( | ) | const [inline, virtual] |
The x and y pixel position of the pointer when the event occurred.
Definition at line 100 of file WCMotionEvent.h.
References itsPixX.
virtual Int casa::WCMotionEvent::pixY | ( | ) | const [inline, virtual] |
Definition at line 102 of file WCMotionEvent.h.
References itsPixY.
virtual const Vector<Double>& casa::WCMotionEvent::world | ( | ) | const [inline, virtual] |
The world coordinates describing where the event occurred.
Definition at line 115 of file WCMotionEvent.h.
References itsWorld.
friend class QtDisplayPanel [friend] |
Definition at line 131 of file WCMotionEvent.h.
Double casa::WCMotionEvent::itsLinX [private] |
Store the linear position of the event here.
Definition at line 139 of file WCMotionEvent.h.
Referenced by linX().
Double casa::WCMotionEvent::itsLinY [private] |
Definition at line 139 of file WCMotionEvent.h.
Referenced by linY().
uInt casa::WCMotionEvent::itsModifiers [private] |
Store the button and keyboard modifier masks here.
Definition at line 145 of file WCMotionEvent.h.
Referenced by modifiers().
Int casa::WCMotionEvent::itsPixX [private] |
Store the pixel position of the event here.
Definition at line 136 of file WCMotionEvent.h.
Referenced by pixX().
Int casa::WCMotionEvent::itsPixY [private] |
Definition at line 136 of file WCMotionEvent.h.
Referenced by pixY().
Vector<Double> casa::WCMotionEvent::itsWorld [private] |
Store the world position of the event here.
Definition at line 142 of file WCMotionEvent.h.
Referenced by world().