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

WorldCanvas event-based zoomer. More...

#include <WCRTZoomer.h>

Inheritance diagram for casa::WCRTZoomer:
casa::WCRectTool casa::WCTool casa::DTVisible casa::DisplayTool

Public Member Functions

 WCRTZoomer (WorldCanvas *wcanvas, Display::KeySym keysym=Display::K_Pointer_Button1)
 Constructor. More...
 
virtual ~WCRTZoomer ()
 Destructor. More...
 
virtual void doubleInside ()
 Functions specific to the zooming - these are called by lower-level event handlers in the base classes. More...
 
virtual void doubleOutside ()
 
virtual void zoomed (const casacore::Vector< casacore::Double > &linBlc, const casacore::Vector< casacore::Double > &linTrc)
 This function is called when a zoom occurs. More...
 
- Public Member Functions inherited from casa::WCRectTool
 WCRectTool (WorldCanvas *wcanvas, Display::KeySym keysym=Display::K_Pointer_Button1, const casacore::Bool persistent=false)
 Constructor. More...
 
virtual ~WCRectTool ()
 Destructor. More...
 
virtual void disable ()
 Switch the tool off - this calls the base class disable, and then erases the rectangle if it's around. More...
 
virtual void keyPressed (const WCPositionEvent &ev)
 Functions called by the local event handling operators - these handle the drawing of the rectangle. More...
 
virtual void keyReleased (const WCPositionEvent &ev)
 
virtual void otherKeyPressed (const WCPositionEvent &ev)
 
virtual void moved (const WCMotionEvent &ev, const viewer::region::region_list_type &)
 
virtual void refresh (const WCRefreshEvent &ev)
 
virtual void rectangleReady ()
 Functions called when a rectangle is ready and not being editted, and when this status changes. More...
 
virtual void rectangleNotReady ()
 
virtual void get (casacore::Int &x1, casacore::Int &y1, casacore::Int &x2, casacore::Int &y2) const
 Retrieve the rectangle corners. More...
 
- Public Member Functions inherited from casa::WCTool
 WCTool (WorldCanvas *wcanvas, const Display::KeySym &keysym=Display::K_Pointer_Button1)
 Constructor taking a pointer to a WorldCanvas to which this tool will attach, and a primary key to respond to. More...
 
virtual ~WCTool ()
 Destructor. More...
 
virtual void enable ()
 Switch the tool on/off - this simply registers or unregisters the event handlers. More...
 
virtual void operator() (const WCPositionEvent &ev)
 Required operators for event handling - these are called when an events occur, and distribute the events to the "user-level" methods. More...
 
virtual void operator() (const WCMotionEvent &ev)
 
virtual void operator() (const WCRefreshEvent &ev)
 
virtual void otherKeyReleased (const WCPositionEvent &)
 
virtual WorldCanvasworldCanvas () const
 Get the WorldCanvas that this Tool is attached to. More...
 
virtual PixelCanvaspixelCanvas () const
 Get the PixelCanvas that this Tool is attached to via its WorldCanvas. More...
 
- Public Member Functions inherited from casa::DisplayTool
virtual ~DisplayTool ()
 Destructor. More...
 
virtual void setKey (const Display::KeySym &keysym)
 Set/get which key to catch. More...
 
virtual Display::KeySym getKey () const
 
- Public Member Functions inherited from casa::DTVisible
 DTVisible ()
 Default constructor. More...
 
virtual ~DTVisible ()
 Destructor. More...
 
virtual casacore::String drawColor () const
 Return the color to use. More...
 
virtual casacore::Int lineWidth () const
 Return the line width to use. More...
 
virtual casacore::Double doubleClickInterval () const
 Return the double click interval (in seconds). More...
 

Private Member Functions

void getLinearCoords (casacore::Vector< casacore::Double > &blc, casacore::Vector< casacore::Double > &trc)
 get the linear coords of the current zoom box More...
 

Additional Inherited Members

- Protected Member Functions inherited from casa::WCTool
 WCTool ()
 (Required) default constructor. More...
 
 WCTool (const WCTool &other)
 (Required) copy constructor. More...
 
WCTooloperator= (const WCTool &other)
 (Required) copy assignment. More...
 
- Protected Member Functions inherited from casa::DisplayTool
 DisplayTool (const Display::KeySym &keysym=Display::K_Pointer_Button1)
 
Constructor taking a key to which this tool will initially be

attached, typically one of the pointer buttons. More...

 
 DisplayTool (const DisplayTool &other)
 Copy constructor - construct a new DisplayTool from other, using copy semantics. More...
 
DisplayTooloperator= (const DisplayTool &other)
 Copy assignment using copy semantics. More...
 
Display::KeyModifier keyModifiers ()
 Return the modifier mask. More...
 
- Protected Member Functions inherited from casa::DTVisible
 DTVisible (const DTVisible &other)
 (Required) copy constructor. More...
 
DTVisibleoperator= (const DTVisible &other)
 (Required) copy assignment. More...
 

Detailed Description

WorldCanvas event-based zoomer.

Intended use:

Public interface

Review Status

<prerequisites> WCRectTool </prerequisites>

Etymology

WCRTZoomer stands for WorldCanvas Rectangling Tool Zoomer

Synopsis

This class finalises the functionality in WCRectTool to implement event-based zooming on a WorldCanvas. casacore::Double clicking inside the constructed rectangle results in zooming in; double clicking outside the rectangle gives zooming out.

Example

Motivation

Zooming is an essential tool for interacting with data displays.

To Do

Definition at line 77 of file WCRTZoomer.h.

Constructor & Destructor Documentation

casa::WCRTZoomer::WCRTZoomer ( WorldCanvas wcanvas,
Display::KeySym  keysym = Display::K_Pointer_Button1 
)

Constructor.

virtual casa::WCRTZoomer::~WCRTZoomer ( )
virtual

Destructor.

Member Function Documentation

virtual void casa::WCRTZoomer::doubleInside ( )
virtual

Functions specific to the zooming - these are called by lower-level event handlers in the base classes.

Reimplemented from casa::WCRectTool.

virtual void casa::WCRTZoomer::doubleOutside ( )
virtual

Reimplemented from casa::WCRectTool.

void casa::WCRTZoomer::getLinearCoords ( casacore::Vector< casacore::Double > &  blc,
casacore::Vector< casacore::Double > &  trc 
)
private

get the linear coords of the current zoom box

virtual void casa::WCRTZoomer::zoomed ( const casacore::Vector< casacore::Double > &  linBlc,
const casacore::Vector< casacore::Double > &  linTrc 
)
virtual

This function is called when a zoom occurs.

It is supplied with the linear coords of the new zoom box, and thus can be implemented to do further actions, or perhaps report the new zoom box to the application


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