KChart::RulerAttributes

KChart::RulerAttributes Class Reference

#include <KChartRulerAttributes.h>

Public Types

typedef QMap< qreal, QPenTickMarkerPensMap
 

Public Member Functions

 RulerAttributes (const RulerAttributes &)
 
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
 
QPen rulerLinePen () const
 
void setLabelMargin (int margin)
 
void setMajorTickMarkLength (int length)
 
void setMajorTickMarkPen (const QPen &pen)
 
void setMinorTickMarkLength (int length)
 
void setMinorTickMarkPen (const QPen &pen)
 
void setRulerLinePen (const QPen &pen)
 
void setShowFirstTick (bool show)
 
void setShowMajorTickMarks (bool show)
 
void setShowMinorTickMarks (bool show)
 
void setShowRulerLine (bool show)
 
void setTickMarkColor (const QColor &color)
 
void setTickMarkPen (const QPen &pen)
 
void setTickMarkPen (qreal value, const QPen &pen)
 
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
 

Detailed Description

A set of attributes controlling the appearance of axis rulers.

Definition at line 36 of file KChartRulerAttributes.h.

Member Function Documentation

QPen RulerAttributes::rulerLinePen ( ) const
Returns
the ruler line pen

Definition at line 299 of file KChartRulerAttributes.cpp.

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 199 of file KChartRulerAttributes.cpp.

void RulerAttributes::setMajorTickMarkLength ( int  length)

Sets the length of major tick marks.

Definition at line 209 of file KChartRulerAttributes.cpp.

void RulerAttributes::setMajorTickMarkPen ( const QPen pen)

Sets the pen used to draw major tick marks.

Definition at line 104 of file KChartRulerAttributes.cpp.

void RulerAttributes::setMinorTickMarkLength ( int  length)

Sets the length of minor tick marks.

Definition at line 225 of file KChartRulerAttributes.cpp.

void RulerAttributes::setMinorTickMarkPen ( const QPen pen)

Sets the pen used to draw minor tick marks.

Definition at line 120 of file KChartRulerAttributes.cpp.

void RulerAttributes::setRulerLinePen ( const QPen pen)

Set the ruler line pen to pen.

Definition at line 294 of file KChartRulerAttributes.cpp.

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 241 of file KChartRulerAttributes.cpp.

void RulerAttributes::setShowMajorTickMarks ( bool  show)

Shows or hides major tick marks.

Definition at line 179 of file KChartRulerAttributes.cpp.

void RulerAttributes::setShowMinorTickMarks ( bool  show)

Shows or hides minor tick marks.

Definition at line 189 of file KChartRulerAttributes.cpp.

void RulerAttributes::setTickMarkColor ( const QColor color)

Color setter method provided for convenience.

Definition at line 169 of file KChartRulerAttributes.cpp.

void RulerAttributes::setTickMarkPen ( const QPen pen)

Sets the pen used to draw the tick marks.

Definition at line 94 of file KChartRulerAttributes.cpp.

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 136 of file KChartRulerAttributes.cpp.


The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Sun Aug 9 2020 22:38:08 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.