casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Protected Member Functions | Private Attributes
casa::WCPositionEvent Class Reference

Class which stores WorldCanvas position event information. More...

#include <WCPositionEvent.h>

Inheritance diagram for casa::WCPositionEvent:
casa::WCMotionEvent casa::WorldCanvasEvent casa::DisplayEvent

List of all members.

Public Member Functions

 WCPositionEvent (WorldCanvas *wc, const Display::KeySym &key, const Bool &keyState, 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 key which is pressed and its state (ie.
virtual ~WCPositionEvent ()
 Destructor.
virtual Display::KeySym key () const
 Which key was pressed or released?
virtual Bool keystate () const
 What state is the key in: True for pressed, False for released.

Protected Member Functions

 WCPositionEvent ()
 (Required) default constructor.
 WCPositionEvent (const WCPositionEvent &other)
 (Required) copy constructor.
WCPositionEventoperator= (const WCPositionEvent &other)
 (Required) copy assignment.

Private Attributes

Display::KeySym itsKey
 Store the key that was pressed or released here.
Bool itsKeyState
 Store the state of that key here.

Detailed Description

Class which stores WorldCanvas position event information.

Intended use:

Public interface

Review Status

Date Reviewed:
yyyy/mm/dd

Etymology

"WCPositionEvent" is a contraction and concatenation of "WorldCanvas", "Position" and "Event", and describes position events occuring on WorldCanvases.

Prerequisite

Synopsis

This class adds to the information stored in the WCMotionEvent class. It adds information describing key that has been pressed or released, and the state of that key.

Example

Motivation

A compact way of passing passing position event information around the WorldCanvas-oriented display classes was needed, with a functional but tight and efficient interface.

Thrown Exceptions

.

Definition at line 83 of file WCPositionEvent.h.


Constructor & Destructor Documentation

casa::WCPositionEvent::WCPositionEvent ( WorldCanvas wc,
const Display::KeySym key,
const Bool keyState,
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 key which is pressed and its state (ie.

pressed or released), the state of the keyboard and pointer modifiers, and the pixel, linear and world coordinates of the event.

Destructor.

(Required) default constructor.

(Required) copy constructor.


Member Function Documentation

virtual Display::KeySym casa::WCPositionEvent::key ( ) const [inline, virtual]

Which key was pressed or released?

Definition at line 104 of file WCPositionEvent.h.

References itsKey.

virtual Bool casa::WCPositionEvent::keystate ( ) const [inline, virtual]

What state is the key in: True for pressed, False for released.

Definition at line 109 of file WCPositionEvent.h.

References itsKeyState.

WCPositionEvent& casa::WCPositionEvent::operator= ( const WCPositionEvent other) [protected]

(Required) copy assignment.


Member Data Documentation

Store the key that was pressed or released here.

Definition at line 126 of file WCPositionEvent.h.

Referenced by key().

Store the state of that key here.

Definition at line 129 of file WCPositionEvent.h.

Referenced by keystate().


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