summaryrefslogtreecommitdiffstats
path: root/libkdchart/KDChartAxisParamsWrapper.h
blob: de8dbcc3f96fca63513d38f201ea6cf5211edf58 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
#ifndef KDCHARTAXISPARAMSWRAPPER_H
#define KDCHARTAXISPARAMSWRAPPER_H
#include <qobject.h>
#include <KDChartEnums.h>
#include <KDChartAxisParams.h>
#include <qstringlist.h>
#include <qvariant.h>
class KDChartAxisParams;

class KDChartAxisParamsWrapper :public QObject
{
    Q_OBJECT

public:
    KDChartAxisParamsWrapper( KDChartAxisParams* );

public slots:
    // These overload are only for convenience.
    void setAxisValueStart( double axisValueStart );
    void setAxisValueEnd( double axisValueEnd );
    void setAxisValueStart( const QVariant axisValueStart );
    void setAxisValueEnd( const QVariant axisValueEnd );

public slots:
    void setAxisValues( bool axisSteadyValueCalc = true,
                        QVariant axisValueStart = KDCHART_AXIS_LABELS_AUTO_LIMIT,
                        QVariant axisValueEnd = KDCHART_AXIS_LABELS_AUTO_LIMIT,
                        double axisValueDelta = KDCHART_AXIS_LABELS_AUTO_DELTA,
                        int axisDigitsBehindComma = KDCHART_AXIS_LABELS_AUTO_DIGITS,
                        int axisMaxEmptyInnerSpan = KDCHART_DONT_CHANGE_EMPTY_INNER_SPAN_NOW,
                        int takeLabelsFromDataRow = KDChartAxisParams::LabelsFromDataRowNo,
                        int labelTextsDataRow = 0,
                        const QVariant& axisLabelStringList = QVariant( QStringList() ),
                        const QVariant& axisShortLabelsStringList = QVariant( QStringList() ),
                        int axisValueLeaveOut = KDCHART_AXIS_LABELS_AUTO_LEAVEOUT,
                        int axisValueDeltaScale = KDChartAxisParams::ValueScaleNumerical );

    void setAxisLabelStringLists( const QVariant& axisLabelStringList,
                                  const QVariant& axisShortLabelStringList,
                                  const QString& valueStart = QString::null,
                                  const QString& valueEnd   = QString::null );

    void setAxisLabelTexts( const QVariant& axisLabelTexts );
private:
    KDChartAxisParams* _data;
};


#endif /* KDCHARTAXISPARAMSWRAPPER_H */