KChart::LineAttributes

KChart::LineAttributes Class Reference

#include <KChartLineAttributes.h>

Public Types

enum  MissingValuesPolicy { MissingValuesAreBridged, MissingValuesHideSegments, MissingValuesShownAsZero, MissingValuesPolicyIgnored }
 

Public Member Functions

 LineAttributes (const LineAttributes &)
 
int areaBoundingDataset () const
 
bool displayArea () const
 
bool isVisible () const
 
MissingValuesPolicy missingValuesPolicy () const
 
bool operator!= (const LineAttributes &other) const
 
LineAttributesoperator= (const LineAttributes &)
 
bool operator== (const LineAttributes &) const
 
void setAreaBoundingDataset (int dataset)
 
void setDisplayArea (bool display)
 
void setMissingValuesPolicy (MissingValuesPolicy policy)
 
void setTransparency (uint alpha)
 
void setVisible (bool visible)
 
uint transparency () const
 

Detailed Description

Set of attributes for changing the appearance of line charts.

Definition at line 31 of file KChartLineAttributes.h.

Member Enumeration Documentation

MissingValuesPolicy specifies how a missing value will be shown in a line diagram.

Missing value is assumed if the data cell contains a QVariant that can not be interpreted as a qreal, or if the data cell is hidden while its dataset is not hidden.

  • MissingValuesAreBridged the default: No markers will be shown for missing values but the line will be bridged if there is at least one valid cell before and after the missing value(s), otherwise the segment will be hidden.
  • MissingValuesHideSegments Line segments starting with a missing value will not be shown, and no markers will be shown for missing values, so this will look like a piece of the line is missing.
  • MissingValuesShownAsZero Missing value(s) will be treated like normal zero values, and markers will shown for them too, so there will be no visible difference between a zero value and a missing value.
  • MissingValuesPolicyIgnored (internal value, do not use)

Definition at line 52 of file KChartLineAttributes.h.

Member Function Documentation

void LineAttributes::setAreaBoundingDataset ( int  dataset)

Sets the lower or upper (depending on the displayed value being positive or negative, resp.) bounding line (i.e., the dataset with the line data).

The area is then drawn between this line and the line of the specified dataset. Pass -1 to draw the area between this line and the zero line.

Definition at line 123 of file KChartLineAttributes.cpp.

void LineAttributes::setVisible ( bool  visible)

Determines if lines are to be drawn or not.

This property does not effect visibility of markers and text labels.

This is useful for e.g. bubble charts where you need circular markers but want no connecting lines to be drawn.

By default lines are drawn, i.e. this property is true.

Definition at line 133 of file KChartLineAttributes.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.