KD Chart 2  [rev.2.5.1]
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Macros Pages
Public Types | Public Member Functions | List of all members
KDChart::RulerAttributes Class Reference

A set of attributes controlling the appearance of axis rulers. More...

#include <KDChartRulerAttributes.h>

Public Types

typedef QMap< qreal, QPen > TickMarkerPensMap
 

Public Member Functions

bool hasTickMarkPenAt (qreal value) const
 
int labelMargin () const
 
int majorTickMarkLength () const
 
bool majorTickMarkLengthIsSet () const
 
QPen majorTickMarkPen () const
 
bool majorTickMarkPenIsSet () const
 
int minorTickMarkLength () const
 
bool minorTickMarkLengthIsSet () const
 
QPen minorTickMarkPen () const
 
bool minorTickMarkPenIsSet () const
 
bool operator!= (const RulerAttributes &other) const
 
RulerAttributesoperator= (const RulerAttributes &)
 
bool operator== (const RulerAttributes &) const
 
 RulerAttributes ()
 
 RulerAttributes (const RulerAttributes &)
 
void setLabelMargin (int margin)
 Set margin that should be used between the labels and the ticks. More...
 
void setMajorTickMarkLength (int length)
 Sets the length of major tick marks. More...
 
void setMajorTickMarkPen (const QPen &pen)
 Sets the pen used to draw major tick marks. More...
 
void setMinorTickMarkLength (int length)
 Sets the length of minor tick marks. More...
 
void setMinorTickMarkPen (const QPen &pen)
 Sets the pen used to draw minor tick marks. More...
 
void setShowFirstTick (bool show)
 Shows or hides the first tick. More...
 
void setShowMajorTickMarks (bool show)
 Shows or hides major tick marks. More...
 
void setShowMinorTickMarks (bool show)
 Shows or hides minor tick marks. More...
 
void setShowRulerLine (bool show)
 
void setTickMarkColor (const QColor &color)
 Color setter method provided for convenience. More...
 
void setTickMarkPen (const QPen &pen)
 Sets the pen used to draw the tick marks. More...
 
void setTickMarkPen (qreal value, const QPen &pen)
 Sets the pen used to draw the tick mark at a specific value. More...
 
bool showFirstTick () const
 
bool showMajorTickMarks () const
 
bool showMinorTickMarks () const
 
bool showRulerLine () const
 
QColor tickMarkColor () const
 
QPen tickMarkPen () const
 
QPen tickMarkPen (qreal value) const
 
TickMarkerPensMap tickMarkPens () const
 
 ~RulerAttributes ()
 

Detailed Description

A set of attributes controlling the appearance of axis rulers.

Definition at line 39 of file KDChartRulerAttributes.h.

Member Typedef Documentation

Definition at line 76 of file KDChartRulerAttributes.h.

Constructor & Destructor Documentation

RulerAttributes::RulerAttributes ( )

Definition at line 87 of file KDChartRulerAttributes.cpp.

RulerAttributes::RulerAttributes ( const RulerAttributes r)

Definition at line 93 of file KDChartRulerAttributes.cpp.

RulerAttributes::~RulerAttributes ( )

Definition at line 265 of file KDChartRulerAttributes.cpp.

Member Function Documentation

bool RulerAttributes::hasTickMarkPenAt ( qreal  value) const

Definition at line 162 of file KDChartRulerAttributes.cpp.

References d.

Referenced by KDChart::CartesianAxis::paintCtx().

int RulerAttributes::labelMargin ( ) const

Definition at line 208 of file KDChartRulerAttributes.cpp.

References d.

Referenced by KDChart::CartesianAxis::paintCtx().

int RulerAttributes::majorTickMarkLength ( ) const

Definition at line 219 of file KDChartRulerAttributes.cpp.

References d.

Referenced by KDChart::CartesianAxis::tickLength().

bool RulerAttributes::majorTickMarkLengthIsSet ( ) const

Definition at line 224 of file KDChartRulerAttributes.cpp.

References d.

Referenced by operator==().

QPen RulerAttributes::majorTickMarkPen ( ) const

Definition at line 119 of file KDChartRulerAttributes.cpp.

References d.

Referenced by operator<<(), operator==(), and KDChart::CartesianAxis::paintCtx().

bool RulerAttributes::majorTickMarkPenIsSet ( ) const

Definition at line 114 of file KDChartRulerAttributes.cpp.

References d.

Referenced by operator==().

int RulerAttributes::minorTickMarkLength ( ) const

Definition at line 235 of file KDChartRulerAttributes.cpp.

References d.

Referenced by KDChart::CartesianAxis::tickLength().

bool RulerAttributes::minorTickMarkLengthIsSet ( ) const

Definition at line 240 of file KDChartRulerAttributes.cpp.

References d.

Referenced by operator==().

QPen RulerAttributes::minorTickMarkPen ( ) const

Definition at line 135 of file KDChartRulerAttributes.cpp.

References d.

Referenced by operator<<(), operator==(), and KDChart::CartesianAxis::paintCtx().

bool RulerAttributes::minorTickMarkPenIsSet ( ) const

Definition at line 130 of file KDChartRulerAttributes.cpp.

References d.

Referenced by operator==().

bool KDChart::RulerAttributes::operator!= ( const RulerAttributes other) const

Definition at line 132 of file KDChartRulerAttributes.h.

References KDGantt::operator==().

RulerAttributes & RulerAttributes::operator= ( const RulerAttributes r)

Definition at line 255 of file KDChartRulerAttributes.cpp.

References d.

bool RulerAttributes::operator== ( const RulerAttributes r) const
void RulerAttributes::setLabelMargin ( int  margin)

Set margin that should be used between the labels and the ticks.

By default the value is -1, which means that half of the label's font height/width should be used as margin.

Definition at line 203 of file KDChartRulerAttributes.cpp.

References d.

void RulerAttributes::setMajorTickMarkLength ( int  length)

Sets the length of major tick marks.

Definition at line 213 of file KDChartRulerAttributes.cpp.

References d.

void RulerAttributes::setMajorTickMarkPen ( const QPen &  pen)

Sets the pen used to draw major tick marks.

Definition at line 108 of file KDChartRulerAttributes.cpp.

References d.

void RulerAttributes::setMinorTickMarkLength ( int  length)

Sets the length of minor tick marks.

Definition at line 229 of file KDChartRulerAttributes.cpp.

References d.

void RulerAttributes::setMinorTickMarkPen ( const QPen &  pen)

Sets the pen used to draw minor tick marks.

Definition at line 124 of file KDChartRulerAttributes.cpp.

References d.

void RulerAttributes::setShowFirstTick ( bool  show)

Shows or hides the first tick.

This is usually where the axes cross. The tick itself may be obscured by the other axis, but the label will be visible.

Definition at line 245 of file KDChartRulerAttributes.cpp.

References d.

void RulerAttributes::setShowMajorTickMarks ( bool  show)

Shows or hides major tick marks.

Definition at line 183 of file KDChartRulerAttributes.cpp.

References d.

void RulerAttributes::setShowMinorTickMarks ( bool  show)

Shows or hides minor tick marks.

Definition at line 193 of file KDChartRulerAttributes.cpp.

References d.

void RulerAttributes::setShowRulerLine ( bool  show)

Definition at line 297 of file KDChartRulerAttributes.cpp.

References d.

void RulerAttributes::setTickMarkColor ( const QColor &  color)

Color setter method provided for convenience.

Definition at line 173 of file KDChartRulerAttributes.cpp.

References d.

void RulerAttributes::setTickMarkPen ( const QPen &  pen)

Sets the pen used to draw the tick marks.

Definition at line 98 of file KDChartRulerAttributes.cpp.

References d.

void RulerAttributes::setTickMarkPen ( qreal  value,
const QPen &  pen 
)

Sets the pen used to draw the tick mark at a specific value.

Note: This will not paint a tick mark at the specified value if it wasn't already drawn before.

Definition at line 140 of file KDChartRulerAttributes.cpp.

References d.

bool RulerAttributes::showFirstTick ( ) const

Definition at line 250 of file KDChartRulerAttributes.cpp.

References d.

Referenced by operator==(), and KDChart::CartesianAxis::paintCtx().

bool RulerAttributes::showMajorTickMarks ( ) const

Definition at line 188 of file KDChartRulerAttributes.cpp.

References d.

Referenced by operator==().

bool RulerAttributes::showMinorTickMarks ( ) const

Definition at line 198 of file KDChartRulerAttributes.cpp.

References d.

Referenced by operator==().

bool RulerAttributes::showRulerLine ( ) const

Definition at line 302 of file KDChartRulerAttributes.cpp.

References d.

Referenced by operator==(), and KDChart::CartesianAxis::paintCtx().

QColor RulerAttributes::tickMarkColor ( ) const

Definition at line 178 of file KDChartRulerAttributes.cpp.

References d.

QPen RulerAttributes::tickMarkPen ( ) const

Definition at line 103 of file KDChartRulerAttributes.cpp.

References d.

Referenced by operator<<(), operator==(), and KDChart::CartesianAxis::paintCtx().

QPen RulerAttributes::tickMarkPen ( qreal  value) const

Definition at line 146 of file KDChartRulerAttributes.cpp.

References d.

RulerAttributes::TickMarkerPensMap RulerAttributes::tickMarkPens ( ) const

Definition at line 157 of file KDChartRulerAttributes.cpp.

References d.

Referenced by operator<<().


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

Klarälvdalens Datakonsult AB (KDAB)
Qt-related services and products
http://www.kdab.com/
http://www.kdab.com/products/kd-chart/