#include <compdateaxis.h>
Public Member Functions | |
CompDateAxis (AXIS_LOCATION location) | |
virtual void | Draw (wxDC &dc, wxRect rc) |
virtual void | DrawGridLines (wxDC &dc, wxRect rc) |
virtual wxCoord | GetExtent (wxDC &dc) |
virtual void | UpdateBounds () |
virtual void | GetDataBounds (double &minValue, double &maxValue) |
virtual wxCoord | ToGraphics (wxDC &dc, int minCoord, int gRange, double value) |
virtual double | ToData (wxDC &dc, int minCoord, int gRange, wxCoord g) |
void | AddInterval (const wxDateSpan &interval) |
void | AddInterval (const wxTimeSpan &interval) |
void | SetSpanDraw (AreaDraw *spanDraw) |
Protected Member Functions | |
virtual bool | AcceptDataset (Dataset *dataset) |
virtual bool CompDateAxis::AcceptDataset | ( | Dataset * | dataset | ) | [protected, virtual] |
Checks whether dataset can be accepted by this axis. Must be implemented by derivative classes. XXX: maybe remove this method later.
dataset | dataset to be checked |
Implements Axis.
virtual void CompDateAxis::Draw | ( | wxDC & | dc, | |
wxRect | rc | |||
) | [virtual] |
virtual void CompDateAxis::DrawGridLines | ( | wxDC & | dc, | |
wxRect | rcData | |||
) | [virtual] |
Draws grid lines for axis.
dc | device context | |
rc | data area rectangle of plot |
Implements Axis.
virtual void CompDateAxis::GetDataBounds | ( | double & | minValue, | |
double & | maxValue | |||
) | [virtual] |
Returns data bounds.
minValue | output minimal data value | |
maxValue | output maximal data value |
Implements Axis.
virtual wxCoord CompDateAxis::GetExtent | ( | wxDC & | dc | ) | [virtual] |
Used to determine minimal size needed to draw axis contents, minimal width for vertical axes, minimal height for horizontal.
dc | device context |
Implements Axis.
void CompDateAxis::SetSpanDraw | ( | AreaDraw * | spanDraw | ) | [inline] |
Sets area draw to draw spans background. CompDateAxis takes ownership of area draw.
spanDraw | area draw to be set |
virtual double CompDateAxis::ToData | ( | wxDC & | dc, | |
int | minCoord, | |||
int | gRange, | |||
wxCoord | g | |||
) | [virtual] |
Transforms coordinate from graphics space to data space.
dc | device context | |
minCoord | minimal graphics space coordinate | |
gRange | graphics space range | |
value | value in data space |
Reimplemented from Axis.
virtual wxCoord CompDateAxis::ToGraphics | ( | wxDC & | dc, | |
int | minCoord, | |||
int | gRange, | |||
double | value | |||
) | [virtual] |
Transforms coordinate from data space to graphics space.
dc | device context | |
minCoord | minimal graphics space coordinate | |
gRange | graphics space range | |
value | value in data space |
Reimplemented from Axis.
virtual void CompDateAxis::UpdateBounds | ( | ) | [virtual] |
Performs axis bounds update after dataset/s change.
Implements Axis.