rwlogo
Rogue Wave Views 5.6

Rogue Wave Views
Charts Package API Reference Guide

Product Documentation:

Rogue Wave Views
Documentation Home

IlvChartInteractor Class Reference

Abstract base class for chart interactors. More...

#include <ilviews/charts/chartint.h>

Inheritance diagram for IlvChartInteractor:
IlvInteractor IlvChartCrossHairInteractor IlvChartDataInteractor IlvChartInteractorDispatcher IlvChartPanInteractor IlvChartScrollInteractor IlvChartZoomInteractor IlvChartDragPointInteractor IlvChartHighlightPointInteractor IlvChartSelectInteractor IlvChartInfoViewInteractor

List of all members.

Public Member Functions

virtual void endSequence (IlvChartGraphic *chart, const IlvEvent &event, const IlvTransformer *t)
 Performs the actions needed when an interactor leaves an event sequence.
virtual IlBoolean handleEvent (IlvGraphic *chart, IlvEvent &event, const IlvTransformer *t=0)=0
 Handles events received by the interactor.
IlBoolean isShared () const
 Indicates whether the current object is a shared instance.
virtual IlBoolean isShowingAbscissaCursor () const
 Indicates whether the interactor uses a cursor on the abscissa.
virtual IlBoolean isShowingOrdinateCursor () const
 Indicates whether the interactor uses a cursor on the ordinate.
virtual void startSequence (IlvChartGraphic *chart, const IlvEvent &event, const IlvTransformer *t)
 Performs the actions needed when an interactor enters an event sequence.

Static Public Member Functions

static IlvChartInteractorGet (const char *name)
 Returns a shared interactor instance.

Protected Member Functions

 IlvChartInteractor ()
 Constructor.

Detailed Description

Abstract base class for chart interactors.

Library: ilvcharts

This class lets you define a behavior for an IlvChartGraphic object. Each subclass will typically implement the interactions needed for a given type of operation (zooming, scrolling, editing, highlighting data points, and so on).


Constructor & Destructor Documentation

IlvChartInteractor::IlvChartInteractor (  )  [protected]

Constructor.

Initializes a new IlvChartInteractor object.


Member Function Documentation

virtual void IlvChartInteractor::endSequence ( IlvChartGraphic chart,
const IlvEvent event,
const IlvTransformer t 
) [virtual]

Performs the actions needed when an interactor leaves an event sequence.

This method must be called explicitly in the IlvChartInteractor::handleEvent method of the interactor subclasses. This method lets you associate an action when the interactor leaves an "event sequence" (an event sequence ends when an IlvButtonUp event is received). The default implementation restores the visibility state of the cursors.

Parameters:
chart The chart object that received the event.
event The received event.
t The transformer applied to the view in which the event occurred.
See also:
isShowingAbscissaCursor.
static IlvChartInteractor* IlvChartInteractor::Get ( const char *  name  )  [static]

Returns a shared interactor instance.

This method lets you retrieve the shared instance corresponding to a given interactor class. Each concrete interactor subclass typically registers one shared instance through a call to the IlvRegisterChartInteractor macro.

Parameters:
name The name under which the shared instance was registered.
Returns:
The shared instance if it was found in the registry and 0 otherwise.
virtual IlBoolean IlvChartInteractor::handleEvent ( IlvGraphic chart,
IlvEvent event,
const IlvTransformer t = 0 
) [pure virtual]

Handles events received by the interactor.

This method is the entry point of all events dispatched to this interactor.

Parameters:
chart The chart object that received the event.
event The received event.
t The transformer applied to the view in which the event occurred.
Returns:
IlTrue if the event was successfully handled and IlFalse otherwise.

Implements IlvInteractor.

Implemented in IlvChartInteractorDispatcher, IlvChartZoomInteractor, IlvChartDragPointInteractor, IlvChartHighlightPointInteractor, IlvChartInfoViewInteractor, IlvChartSelectInteractor, IlvChartCrossHairInteractor, IlvChartPanInteractor, and IlvChartScrollInteractor.

IlBoolean IlvChartInteractor::isShared (  )  const

Indicates whether the current object is a shared instance.

A shared instance is stored in a registry and can be accessed by its registered name. The registered name must match the string returned by the IlvChartInteractor::className method. A shared instance should never be deleted.

Returns:
IlTrue if the interactor is a shared instance and IlFalse otherwise.
virtual IlBoolean IlvChartInteractor::isShowingAbscissaCursor (  )  const [virtual]

Indicates whether the interactor uses a cursor on the abscissa.

Interactor instances will use the API of IlvChartInteractorManager to display and move the corresponding cursor. If this method returns IlTrue and IlvChartInteractorManager::isShowingAbscissaCursor also returns IlTrue, the cursor will be displayed during the event sequence handled by this interactor. The default implementation returns IlFalse.

Returns:
IlTrue if the interactor uses an abscissa cursor and IlFalse otherwise.
See also:
IlvChartInteractorManager.

Reimplemented in IlvChartZoomInteractor, IlvChartDragPointInteractor, and IlvChartCrossHairInteractor.

virtual IlBoolean IlvChartInteractor::isShowingOrdinateCursor (  )  const [virtual]

Indicates whether the interactor uses a cursor on the ordinate.

Interactor instances will use the API of IlvChartInteractorManager to display and move the corresponding cursor. If this method returns IlTrue and IlvChartInteractorManager::isShowingAbscissaCursor also returns IlTrue, the cursor will be displayed during the event sequence handled by this interactor.

Returns:
IlTrue if the interactor uses an ordinate cursor and IlFalse otherwise.
See also:
IlvChartInteractorManager.

Reimplemented in IlvChartZoomInteractor, IlvChartDragPointInteractor, and IlvChartCrossHairInteractor.

virtual void IlvChartInteractor::startSequence ( IlvChartGraphic chart,
const IlvEvent event,
const IlvTransformer t 
) [virtual]

Performs the actions needed when an interactor enters an event sequence.

This method must be called explicitly in the IlvChartInteractor::handleEvent method of the interactor subclasses. This method lets you associate an action when the interactor enters an "event sequence" (an event sequence starts when an IlvButtonDown event is received). The default implementation saves the visibility state of the current cursors and displays the cursors depending on the returned value of isShowingAbscissaCursor and isShowingOrdinateCursor.

Parameters:
chart The chart object that received the event.
event The received event.
t The transformer applied to the view in which the event occurred.
See also:
isShowingAbscissaCursor.
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

© Copyright 2012, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.