vtkQtChartContentsSpace Class Reference

#include <vtkQtChartContentsSpace.h>

List of all members.


Detailed Description

The vtkQtChartContentsSpace class defines the contents space for a chart.

Definition at line 41 of file vtkQtChartContentsSpace.h.


Public Slots

void setXOffset (float offset)
 Sets the x offset.
void setYOffset (float offset)
 Sets the y offset.
void setMaximumXOffset (float maximum)
 Sets the maximum x offset.
void setMaximumYOffset (float maximum)
 Sets the maximum y offset.
void panUp ()
 Pans up by a predetermined amount.
void panDown ()
 Pans down by a predetermined amount.
void panLeft ()
 Pans left by a predetermined amount.
void panRight ()
 Pans right by a predetermined amount.
void resetZoom ()
 Resets the zoom factors to 1.
void historyNext ()
 Changes the view to the next one in the history.
void historyPrevious ()
 Changes the view to the previous one in the history.

Signals

void xOffsetChanged (float offset)
 Emitted when the x offset has changed.
void yOffsetChanged (float offset)
 Emitted when the y offset has changed.
void maximumChanged (float xMaximum, float yMaximum)
 Emitted when the maximum offsets have changed.
void historyPreviousAvailabilityChanged (bool available)
 Emitted when the view history availability changes.
void historyNextAvailabilityChanged (bool available)
 Emitted when the view history availability changes.

Public Member Functions

 vtkQtChartContentsSpace (QObject *parent=0)
 Creates a chart contents space instance.
virtual ~vtkQtChartContentsSpace ()
Contents Methods
float getXOffset () const
 Gets the x offset.
float getYOffset () const
 Gets the y offset.
float getMaximumXOffset () const
 Gets the maximum x offset.
float getMaximumYOffset () const
 Gets the maximum y offset.
float getContentsWidth () const
 Gets the contents width.
float getContentsHeight () const
 Gets the contents height.
void translateToLayerContents (QPointF &point) const
 Translates a point to layer contents coordinates.
void translateToLayerContents (QRectF &area) const
 Translates a point to layer contents coordinates.
Size Methods
float getChartWidth () const
 Gets the width of the chart.
float getChartHeight () const
 Gets the height of the chart.
void setChartSize (float width, float height)
 Sets the size of the chart.
void getChartLayerBounds (QRectF &bounds) const
 Gets the chart layer bounds.
void setChartLayerBounds (const QRectF &bounds)
 Sets the chart layer bounds.
Zoom Methods
float getXZoomFactor () const
 Gets the x-axis zoom factor.
float getYZoomFactor () const
 Gets the y-axis zoom factor.
void zoomToFactor (float factor)
 Zooms the chart to the given factor.
void zoomToFactor (float xFactor, float yFactor)
 Zooms the chart to the given factors.
void zoomToFactorX (float factor)
 Zooms only the x-axis to a given factor.
void zoomToFactorY (float factor)
 Zooms only the y-axis to a given factor.
Mouse Interactions
void startInteraction ()
 Signals the start of a mouse move interaction.
bool isInInteraction () const
 Gets whether or not an interaction is currently in progress.
void finishInteraction ()
 Signals the end of a mouse move interaction.
History Methods
bool isHistoryPreviousAvailable () const
 Gets whether or not a previous zoom viewport is available.
bool isHistoryNextAvailable () const
 Gets whether or not a forward zoom viewport is available.

Static Public Member Functions

static float getZoomFactorStep ()
 Gets the zoom factor step.
static void setZoomFactorStep (float step)
 Sets the zoom factor step.
static float getPanStep ()
 Gets the pan step.
static void setPanStep (float step)
 Sets the pan step.

Constructor & Destructor Documentation

vtkQtChartContentsSpace::vtkQtChartContentsSpace ( QObject *  parent = 0  ) 

Creates a chart contents space instance.

Parameters:
parent The parent object.

virtual vtkQtChartContentsSpace::~vtkQtChartContentsSpace (  )  [virtual]


Member Function Documentation

float vtkQtChartContentsSpace::getXOffset (  )  const [inline]

Gets the x offset.

Returns:
The x offset.

Definition at line 58 of file vtkQtChartContentsSpace.h.

float vtkQtChartContentsSpace::getYOffset (  )  const [inline]

Gets the y offset.

Returns:
The y offset.

Definition at line 64 of file vtkQtChartContentsSpace.h.

float vtkQtChartContentsSpace::getMaximumXOffset (  )  const [inline]

Gets the maximum x offset.

Returns:
The maximum x offset.

Definition at line 70 of file vtkQtChartContentsSpace.h.

float vtkQtChartContentsSpace::getMaximumYOffset (  )  const [inline]

Gets the maximum y offset.

Returns:
The maximum y offset.

Definition at line 76 of file vtkQtChartContentsSpace.h.

float vtkQtChartContentsSpace::getContentsWidth (  )  const

Gets the contents width.

Returns:
The contents width.

float vtkQtChartContentsSpace::getContentsHeight (  )  const

Gets the contents height.

Returns:
The contents height.

void vtkQtChartContentsSpace::translateToLayerContents ( QPointF &  point  )  const

Translates a point to layer contents coordinates.

The point is adjusted from widget origin to layer bounds origin. The point is also translated to account for panning offset.

Parameters:
point The point to translate.

void vtkQtChartContentsSpace::translateToLayerContents ( QRectF &  area  )  const

Translates a point to layer contents coordinates.

The rectangle is adjusted from widget origin to layer bounds origin. The rectangle is also translated to account for panning offset.

Parameters:
area The rectangle to translate.

float vtkQtChartContentsSpace::getChartWidth (  )  const [inline]

Gets the width of the chart.

Returns:
The width of the chart.

Definition at line 116 of file vtkQtChartContentsSpace.h.

float vtkQtChartContentsSpace::getChartHeight (  )  const [inline]

Gets the height of the chart.

Returns:
The height of the chart.

Definition at line 122 of file vtkQtChartContentsSpace.h.

void vtkQtChartContentsSpace::setChartSize ( float  width,
float  height 
)

Sets the size of the chart.

The chart size must be set in order to zoom in or out. The contents size methods are only valid when the chart size is set.

Parameters:
width The chart width.
height The chart height.

void vtkQtChartContentsSpace::getChartLayerBounds ( QRectF &  bounds  )  const

Gets the chart layer bounds.

Parameters:
bounds Used to return the chart layer bounds.

void vtkQtChartContentsSpace::setChartLayerBounds ( const QRectF &  bounds  ) 

Sets the chart layer bounds.

Parameters:
bounds The chart layer bounds.

float vtkQtChartContentsSpace::getXZoomFactor (  )  const [inline]

Gets the x-axis zoom factor.

Returns:
The x-axis zoom factor.

Definition at line 151 of file vtkQtChartContentsSpace.h.

float vtkQtChartContentsSpace::getYZoomFactor (  )  const [inline]

Gets the y-axis zoom factor.

Returns:
The y-axis zoom factor.

Definition at line 157 of file vtkQtChartContentsSpace.h.

void vtkQtChartContentsSpace::zoomToFactor ( float  factor  ) 

Zooms the chart to the given factor.

Parameters:
factor The new zoom factor for both axes.
See also:
vtkQtChartContentsSpace::zoomToFactor(float, float)

void vtkQtChartContentsSpace::zoomToFactor ( float  xFactor,
float  yFactor 
)

Zooms the chart to the given factors.

The zoom factors of the chart are independent of each other. In other words, the x-axis can be zoomed to a different factor than the y-axis.

When the zoom factors are changed, the new zoom viewport will be added to the zoom history. The zoom history can be navigated using the historyNext and historyPrevious methods. The user can also navigate through the history using the keyboard shortcuts.

Parameters:
xFactor The x-axis zoom factor.
yFactor The y-axis zoom factor.

void vtkQtChartContentsSpace::zoomToFactorX ( float  factor  ) 

Zooms only the x-axis to a given factor.

Parameters:
factor The x-axis zoom factor.
See also:
vtkQtChartContentsSpace::zoomToFactor(float, float)

void vtkQtChartContentsSpace::zoomToFactorY ( float  factor  ) 

Zooms only the y-axis to a given factor.

Parameters:
factor The y-axis zoom factor.
See also:
vtkQtChartContentsSpace::zoomToFactor(float, float)

void vtkQtChartContentsSpace::startInteraction (  ) 

Signals the start of a mouse move interaction.

While an interaction is in progress, the zoom history will not be updated. When finishInteraction is called, the history is updated if the zoom factors have changed.

See also:
vtkQtChartContentsSpace::finishInteraction()

bool vtkQtChartContentsSpace::isInInteraction (  )  const

Gets whether or not an interaction is currently in progress.

Returns:
True if an interaction is currently in progress.
See also:
vtkQtChartContentsSpace::startInteraction(), vtkQtChartContentsSpace::finishInteraction()

void vtkQtChartContentsSpace::finishInteraction (  ) 

Signals the end of a mouse move interaction.

See also:
vtkQtChartContentsSpace::startInteraction()

bool vtkQtChartContentsSpace::isHistoryPreviousAvailable (  )  const

Gets whether or not a previous zoom viewport is available.

Returns:
True if a previous zoom viewport is available.

bool vtkQtChartContentsSpace::isHistoryNextAvailable (  )  const

Gets whether or not a forward zoom viewport is available.

Returns:
True if a forward zoom viewport is available.

void vtkQtChartContentsSpace::setXOffset ( float  offset  )  [slot]

Sets the x offset.

Parameters:
offset The new x offset.

void vtkQtChartContentsSpace::setYOffset ( float  offset  )  [slot]

Sets the y offset.

Parameters:
offset The new y offset.

void vtkQtChartContentsSpace::setMaximumXOffset ( float  maximum  )  [slot]

Sets the maximum x offset.

Parameters:
maximum The maximum x offset.

void vtkQtChartContentsSpace::setMaximumYOffset ( float  maximum  )  [slot]

Sets the maximum y offset.

Parameters:
maximum The maximum y offset.

void vtkQtChartContentsSpace::panUp (  )  [slot]

Pans up by a predetermined amount.

void vtkQtChartContentsSpace::panDown (  )  [slot]

Pans down by a predetermined amount.

void vtkQtChartContentsSpace::panLeft (  )  [slot]

Pans left by a predetermined amount.

void vtkQtChartContentsSpace::panRight (  )  [slot]

Pans right by a predetermined amount.

void vtkQtChartContentsSpace::resetZoom (  )  [slot]

Resets the zoom factors to 1.

void vtkQtChartContentsSpace::historyNext (  )  [slot]

Changes the view to the next one in the history.

void vtkQtChartContentsSpace::historyPrevious (  )  [slot]

Changes the view to the previous one in the history.

static float vtkQtChartContentsSpace::getZoomFactorStep (  )  [static]

Gets the zoom factor step.

Returns:
The zoom factor step.

static void vtkQtChartContentsSpace::setZoomFactorStep ( float  step  )  [static]

Sets the zoom factor step.

Parameters:
step The new zoom factor step.

static float vtkQtChartContentsSpace::getPanStep (  )  [static]

static void vtkQtChartContentsSpace::setPanStep ( float  step  )  [static]

Sets the pan step.

Parameters:
step The new pan step.

void vtkQtChartContentsSpace::xOffsetChanged ( float  offset  )  [signal]

Emitted when the x offset has changed.

Parameters:
offset The new x offset.

void vtkQtChartContentsSpace::yOffsetChanged ( float  offset  )  [signal]

Emitted when the y offset has changed.

Parameters:
offset The new y offset.

void vtkQtChartContentsSpace::maximumChanged ( float  xMaximum,
float  yMaximum 
) [signal]

Emitted when the maximum offsets have changed.

This signal is sent when either or both of the offsets have changed. Sending the changes as one improves the chart layout.

Parameters:
xMaximum The maximum x offset.
yMaximum The maximum y offset.

void vtkQtChartContentsSpace::historyPreviousAvailabilityChanged ( bool  available  )  [signal]

Emitted when the view history availability changes.

Parameters:
available True if there is a history item available before the current one.

void vtkQtChartContentsSpace::historyNextAvailabilityChanged ( bool  available  )  [signal]

Emitted when the view history availability changes.

Parameters:
available True if there is a history item available after the current one.


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

Generated on Mon Sep 27 18:44:11 2010 for VTK by  doxygen 1.5.6