casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | List of all members
casa::PCPositionEH Class Reference

PixelCanvas Event Handler for managing keyboard and mouse button events. More...

#include <PCPositionEH.h>

Inheritance diagram for casa::PCPositionEH:
casa::Annotations casa::PCToolPosEH casa::QtDisplayPanel casa::WorldCanvas

Public Member Functions

 PCPositionEH ()
 Default Constructor Required. More...
 
virtual void operator() (const PCPositionEvent &eh)
 Default just prints the event to cout. More...
 
virtual ~PCPositionEH ()
 Destructor. More...
 

Detailed Description

PixelCanvas Event Handler for managing keyboard and mouse button events.

Prerequisite

Etymology

PCPositionEH : PixelCanvas Position Event Handler

Synopsis

Designed for derivation, this class is the base class which is communicated to when an X button or keyboard event is sent to the PixelCanvas. The application programmer should derive from this class, add any data fields needed, and override operator () to respond properly to keyboard and mouse button events.

Motivation

Wanted a standard method for event management. It was felt that a class might be more flexible than callback methods because a class can contain data and other functions as well.

Example

see the WorldCanvas code see the Display test directory

Definition at line 74 of file PCPositionEH.h.

Constructor & Destructor Documentation

casa::PCPositionEH::PCPositionEH ( )

Default Constructor Required.

virtual casa::PCPositionEH::~PCPositionEH ( )
virtual

Destructor.

Member Function Documentation

virtual void casa::PCPositionEH::operator() ( const PCPositionEvent eh)
virtual

Default just prints the event to cout.

Reimplemented in casa::WorldCanvas, casa::QtDisplayPanel, casa::Annotations, and casa::PCToolPosEH.


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