KChart::DataValueAttributes
#include <KChartDataValueAttributes>
Static Public Member Functions | |
static const DataValueAttributes & | defaultAttributes () |
static const QVariant & | defaultAttributesAsVariant () |
Detailed Description
Diagram attributes dealing with data value labels.
The DataValueAttributes group all properties that can be set wrt data value labels and if and how they are displayed. This includes things like the text attributes (font, color), what markers are used, how many decimal digits are displayed, etc.
Definition at line 41 of file KChartDataValueAttributes.h.
Constructor & Destructor Documentation
◆ DataValueAttributes() [1/2]
DataValueAttributes::DataValueAttributes | ( | ) |
Definition at line 81 of file KChartDataValueAttributes.cpp.
◆ DataValueAttributes() [2/2]
DataValueAttributes::DataValueAttributes | ( | const DataValueAttributes & | r | ) |
Definition at line 86 of file KChartDataValueAttributes.cpp.
◆ ~DataValueAttributes()
DataValueAttributes::~DataValueAttributes | ( | ) |
Definition at line 101 of file KChartDataValueAttributes.cpp.
Member Function Documentation
◆ backgroundAttributes()
BackgroundAttributes DataValueAttributes::backgroundAttributes | ( | ) | const |
- Returns
- The background attributes used for painting the data value labels area.
- See also
- BackgroundAttributes
Definition at line 178 of file KChartDataValueAttributes.cpp.
◆ dataLabel()
QString DataValueAttributes::dataLabel | ( | ) | const |
Returns the string displayed instead of the data value label.
- See also
- setDataLabel
Definition at line 248 of file KChartDataValueAttributes.cpp.
◆ decimalDigits()
int DataValueAttributes::decimalDigits | ( | ) | const |
- Returns
- The number of decimal digits displayed.
Definition at line 218 of file KChartDataValueAttributes.cpp.
◆ defaultAttributes()
|
static |
Definition at line 129 of file KChartDataValueAttributes.cpp.
◆ defaultAttributesAsVariant()
|
static |
Definition at line 136 of file KChartDataValueAttributes.cpp.
◆ frameAttributes()
FrameAttributes DataValueAttributes::frameAttributes | ( | ) | const |
- Returns
- The frame attributes used for painting the data value labels area.
- See also
- FrameAttributes
Definition at line 168 of file KChartDataValueAttributes.cpp.
◆ isVisible()
bool DataValueAttributes::isVisible | ( | ) | const |
- Returns
- Whether data value labels should be displayed.
Definition at line 148 of file KChartDataValueAttributes.cpp.
◆ markerAttributes()
MarkerAttributes DataValueAttributes::markerAttributes | ( | ) | const |
- Returns
- The marker attributes used for decorating the data values.
- See also
- MarkerAttributes
Definition at line 188 of file KChartDataValueAttributes.cpp.
◆ mirrorNegativeValueTextRotation()
bool DataValueAttributes::mirrorNegativeValueTextRotation | ( | ) | const |
If true, rotation of negative value labels is negated, so that negative values are rotated in opposite direction of textAttributes().rotation(), and in this sense appear "mirrored" to positive value labels, though the text itself is not mirrored, only its rotation.
Definition at line 198 of file KChartDataValueAttributes.cpp.
◆ negativePosition()
const RelativePosition DataValueAttributes::negativePosition | ( | ) | const |
Return the relative positioning of the data value labels.
- See also
- setNegativePosition
Definition at line 298 of file KChartDataValueAttributes.cpp.
◆ operator!=()
|
inline |
Definition at line 48 of file KChartDataValueAttributes.h.
◆ operator=()
DataValueAttributes & DataValueAttributes::operator= | ( | const DataValueAttributes & | r | ) |
Definition at line 91 of file KChartDataValueAttributes.cpp.
◆ operator==()
bool DataValueAttributes::operator== | ( | const DataValueAttributes & | r | ) | const |
Definition at line 107 of file KChartDataValueAttributes.cpp.
◆ position()
|
inline |
Definition at line 289 of file KChartDataValueAttributes.h.
◆ positivePosition()
const RelativePosition DataValueAttributes::positivePosition | ( | ) | const |
Return the relative positioning of the data value labels.
- See also
- setPositivePosition
Definition at line 308 of file KChartDataValueAttributes.cpp.
◆ prefix()
QString DataValueAttributes::prefix | ( | ) | const |
Returns the string used as a prefix to the data value text.
- See also
- setPrefix
Definition at line 228 of file KChartDataValueAttributes.cpp.
◆ setBackgroundAttributes()
void DataValueAttributes::setBackgroundAttributes | ( | const BackgroundAttributes & | a | ) |
Set the background attributes to use for the data value labels area.
- Parameters
-
a The background attributes to set.
- See also
- BackgroundAttributes
Definition at line 173 of file KChartDataValueAttributes.cpp.
◆ setDataLabel()
void DataValueAttributes::setDataLabel | ( | const QString | label | ) |
display a string label instead of the original data value label Supports HTML code.
- See also
- dataLabel
Definition at line 243 of file KChartDataValueAttributes.cpp.
◆ setDecimalDigits()
void DataValueAttributes::setDecimalDigits | ( | int | digits | ) |
Set how many decimal digits to display when rendering the data value labels.
If there are no decimal digits it will not be displayed.
- Parameters
-
digits The number of decimal digits to use.
Definition at line 213 of file KChartDataValueAttributes.cpp.
◆ setFrameAttributes()
void DataValueAttributes::setFrameAttributes | ( | const FrameAttributes & | a | ) |
Set the frame attributes to use for the data value labels area.
- Parameters
-
a The frame attributes to set.
- See also
- FrameAttributes
Definition at line 163 of file KChartDataValueAttributes.cpp.
◆ setMarkerAttributes()
void DataValueAttributes::setMarkerAttributes | ( | const MarkerAttributes & | a | ) |
Set the marker attributes to use for the data values.
This includes the marker type.
- Parameters
-
a The marker attributes to set.
- See also
- MarkerAttributes
Definition at line 183 of file KChartDataValueAttributes.cpp.
◆ setMirrorNegativeValueTextRotation()
void DataValueAttributes::setMirrorNegativeValueTextRotation | ( | bool | enable | ) |
Definition at line 193 of file KChartDataValueAttributes.cpp.
◆ setNegativePosition()
void DataValueAttributes::setNegativePosition | ( | const RelativePosition & | relPosition | ) |
Defines the relative positioning of the data value labels for negative values.
The position is specified in relation to the respective data value point, or in relation to the respective data representation area, that's one area segment in a LineDiagram showing areas, or one bar in a BarDiagram, one pie slice ...
See detailed description of KChart::Position for an illustration of the different possible reference positions.
- See also
- negativePosition
Definition at line 293 of file KChartDataValueAttributes.cpp.
◆ setPositivePosition()
void DataValueAttributes::setPositivePosition | ( | const RelativePosition & | relPosition | ) |
Defines the relative position of the data value labels for positive values.
The position is specified in relation to the respective data value point, or in relation to the respective data representation area, that's one area segment in a LineDiagram showing areas, or one bar in a BarDiagram, one pie slice ...
See detailed description of KChart::Position for an illustration of the different possible reference positions.
- See also
- positivePosition
Definition at line 303 of file KChartDataValueAttributes.cpp.
◆ setPrefix()
void DataValueAttributes::setPrefix | ( | const QString | prefix | ) |
Prepend a prefix string to the data value label.
- See also
- prefix
Definition at line 223 of file KChartDataValueAttributes.cpp.
◆ setShowOverlappingDataLabels()
void DataValueAttributes::setShowOverlappingDataLabels | ( | bool | showOverlappingDataLabels | ) |
Set whether data value texts overlapping other data value texts of the same diagram should be drawn.
- Parameters
-
showOverlappingDataLabels Whether data texts overlapping other data value texts of the same diagram are drawn.
Definition at line 268 of file KChartDataValueAttributes.cpp.
◆ setShowRepetitiveDataLabels()
void DataValueAttributes::setShowRepetitiveDataLabels | ( | bool | showRepetitiveDataLabels | ) |
Set whether data value labels not different from their predecessors should be drawn.
- Parameters
-
showRepetitiveDataLabels Whether data value not different from their predecessors are drawn.
Definition at line 258 of file KChartDataValueAttributes.cpp.
◆ setSuffix()
void DataValueAttributes::setSuffix | ( | const QString | suffix | ) |
Append a suffix string to the data value label.
- See also
- suffix
Definition at line 233 of file KChartDataValueAttributes.cpp.
◆ setTextAttributes()
void DataValueAttributes::setTextAttributes | ( | const TextAttributes & | a | ) |
Set the text attributes to use for the data value labels.
- Parameters
-
a The text attributes to set.
- See also
- TextAttributes
Definition at line 153 of file KChartDataValueAttributes.cpp.
◆ setUsePercentage()
void DataValueAttributes::setUsePercentage | ( | bool | enable | ) |
Specify whether to use percentages instead of actual data point values when no specific label is set.
In a bar or cartesian diagram, this means that the value will be shown in % in relation to the sum of all values in the same category, in a polar diagram in relation to the sum of all values in a data set.
When this is turned on, the value will not automatically have the '' postfix.
- Parameters
-
enable Whether to enable percentage values
Definition at line 203 of file KChartDataValueAttributes.cpp.
◆ setVisible()
void DataValueAttributes::setVisible | ( | bool | visible | ) |
Set whether data value labels should be displayed.
- Parameters
-
visible Whether data value labels should be displayed.
Definition at line 143 of file KChartDataValueAttributes.cpp.
◆ showOverlappingDataLabels()
bool DataValueAttributes::showOverlappingDataLabels | ( | ) | const |
- Returns
- Whether data value texts overlapping other data value texts of the same diagram are drawn.
Definition at line 263 of file KChartDataValueAttributes.cpp.
◆ showRepetitiveDataLabels()
bool DataValueAttributes::showRepetitiveDataLabels | ( | ) | const |
- Returns
- Whether data values not different from their predecessors are drawn.
Definition at line 253 of file KChartDataValueAttributes.cpp.
◆ suffix()
QString DataValueAttributes::suffix | ( | ) | const |
Returns the string used as a suffix to the data value text.
- See also
- setSuffix
Definition at line 238 of file KChartDataValueAttributes.cpp.
◆ textAttributes()
TextAttributes DataValueAttributes::textAttributes | ( | ) | const |
- Returns
- The text attributes used for painting data value labels.
Definition at line 158 of file KChartDataValueAttributes.cpp.
◆ usePercentage()
bool DataValueAttributes::usePercentage | ( | ) | const |
- Returns
- Whether to use percentage values
- See also
- setUsePercentage
Definition at line 208 of file KChartDataValueAttributes.cpp.
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:09:30 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.