Public Member Functions | Protected Member Functions | Protected Attributes

DrawAxis2D Class Reference

List of all members.

Public Member Functions

 DrawAxis2D (uiGraphicsView &)
 ~DrawAxis2D ()
void setDrawRectangle (const uiRect *)
void setup (const uiWorldRect &)
void setup (const StepInterval< float > &xrg, const StepInterval< float > &yrg)
void annotInside (bool yn)
void drawAxisLine (bool yn)
void drawAxes (bool xdir, bool ydir, bool topside, bool leftside)
void drawXAxis (bool topside)
void drawYAxis (bool leftside)
void drawGridLines (bool xdir, bool ydir)
void setXLineStyle (const LineStyle &)
void setYLineStyle (const LineStyle &)
void setGridLineStyle (const LineStyle &)
void setZvalue (int z)

Protected Member Functions

uiRect getDrawArea () const
virtual double getAnnotTextAndPos (bool isx, double proposedpos, BufferString *text=0) const

Protected Attributes

uiGraphicsScenedrawscene_
uiGraphicsViewdrawview_
uiGraphicsItemGroupxaxlineitmgrp_
uiGraphicsItemGroupyaxlineitmgrp_
uiGraphicsItemGroupxaxgriditmgrp_
uiGraphicsItemGroupyaxgriditmgrp_
uiGraphicsItemGroupxaxtxtitmgrp_
uiGraphicsItemGroupyaxtxtitmgrp_
uiRectItemxaxrectitem_
uiLineItemyaxlineitem_
Interval< double > xrg_
Interval< double > yrg_
LineStyle xls_
LineStyle yls_
LineStyle gridls_
SamplingData< double > xaxis_
SamplingData< double > yaxis_
uiRect uirect_
bool useuirect_
bool inside_
bool drawaxisline_
int zValue_

Constructor & Destructor Documentation

DrawAxis2D::DrawAxis2D ( uiGraphicsView  ) 
DrawAxis2D::~DrawAxis2D (  ) 

Member Function Documentation

void DrawAxis2D::annotInside ( bool  yn  )  [inline]
void DrawAxis2D::drawAxes ( bool  xdir,
bool  ydir,
bool  topside,
bool  leftside 
)
void DrawAxis2D::drawAxisLine ( bool  yn  )  [inline]
void DrawAxis2D::drawGridLines ( bool  xdir,
bool  ydir 
)
void DrawAxis2D::drawXAxis ( bool  topside  ) 
void DrawAxis2D::drawYAxis ( bool  leftside  ) 
virtual double DrawAxis2D::getAnnotTextAndPos ( bool  isx,
double  proposedpos,
BufferString text = 0 
) const [protected, virtual]

When drawing the axis, the object proposes an annotation at proposedpos. proposedpos may however not be a good location (e.g. it may not be on an even sample). Default is to display at the proposedpos, with the proposedpos as the text, but inheriting classes may customize this.

Parameters:
isx true if x-axis, false if y-axis.
proposedpos ideal place of annotation
text where the text to display
Returns:
the actual display pos is
uiRect DrawAxis2D::getDrawArea (  )  const [protected]
void DrawAxis2D::setDrawRectangle ( const uiRect  ) 

Specifies a rectangle on the canvas where the axis should be drawn. If set to zero, drawer will draw in the full draw area.

void DrawAxis2D::setGridLineStyle ( const LineStyle  ) 
void DrawAxis2D::setup ( const uiWorldRect &   ) 
void DrawAxis2D::setup ( const StepInterval< float > &  xrg,
const StepInterval< float > &  yrg 
)
void DrawAxis2D::setXLineStyle ( const LineStyle  ) 
void DrawAxis2D::setYLineStyle ( const LineStyle  ) 
void DrawAxis2D::setZvalue ( int  z  )  [inline]

Member Data Documentation

bool DrawAxis2D::drawaxisline_ [protected]
bool DrawAxis2D::inside_ [protected]
bool DrawAxis2D::useuirect_ [protected]
SamplingData<double> DrawAxis2D::xaxis_ [protected]
Interval<double> DrawAxis2D::xrg_ [protected]
SamplingData<double> DrawAxis2D::yaxis_ [protected]
Interval<double> DrawAxis2D::yrg_ [protected]
int DrawAxis2D::zValue_ [protected]