KD Chart 2  [rev.2.7]
KDChartLeveyJenningsGridAttributes.h
Go to the documentation of this file.
1 /****************************************************************************
2 ** Copyright (C) 2001-2020 Klaralvdalens Datakonsult AB. All rights reserved.
3 **
4 ** This file is part of the KD Chart library.
5 **
6 ** Licensees holding valid commercial KD Chart licenses may use this file in
7 ** accordance with the KD Chart Commercial License Agreement provided with
8 ** the Software.
9 **
10 **
11 ** This file may be distributed and/or modified under the terms of the
12 ** GNU General Public License version 2 and version 3 as published by the
13 ** Free Software Foundation and appearing in the file LICENSE.GPL.txt included.
14 **
15 ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
16 ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
17 **
18 ** Contact info@kdab.com if any conditions of this licensing are not
19 ** clear to you.
20 **
21 **********************************************************************/
22 
23 #ifndef KDCHARTLEVEYJENNINGSGRIDATTRIBUTES_H
24 #define KDCHARTLEVEYJENNINGSGRIDATTRIBUTES_H
25 
26 #include <QMetaType>
27 #include "KDChartGlobal.h"
28 #include "KDChartEnums.h"
29 
30 QT_BEGIN_NAMESPACE
31 class QPen;
32 QT_END_NAMESPACE
33 
34 namespace KDChart {
35 
39 class KDCHART_EXPORT LeveyJenningsGridAttributes
40 {
41 public:
45 
47 
48  enum GridType
49  {
51  Calculated
52  };
53 
54  enum Range
55  {
58  OutOfRange
59  };
60 
61  void setGridVisible( GridType type, bool visible );
62  bool isGridVisible( GridType type ) const;
63 
64  void setGridPen( GridType type, const QPen& pen );
65  QPen gridPen( GridType type ) const;
66 
67  void setRangeBrush( Range range, const QBrush& brush );
68  QBrush rangeBrush( Range range ) const;
69 
70  bool operator==( const LeveyJenningsGridAttributes& ) const;
71  inline bool operator!=( const LeveyJenningsGridAttributes& other ) const { return !operator==(other); }
72 
73 private:
75 }; // End of class GridAttributes
76 
77 }
78 
80 
81 QT_BEGIN_NAMESPACE
83 QT_END_NAMESPACE
84 
85 Q_DECLARE_METATYPE( KDChart::LeveyJenningsGridAttributes )
86 
87 #endif // KDCHARTLEVEYJENNINGSGRIDATTRIBUTES_H
bool operator==(const Span &s1, const Span &s2)
bool operator!=(const LeveyJenningsGridAttributes &other) const
Definition of global enums.
#define KDCHART_DECLARE_PRIVATE_BASE_VALUE(X)
Definition: KDChartGlobal.h:71
QT_BEGIN_NAMESPACE Q_DECLARE_TYPEINFO(KDChart::LeveyJenningsGridAttributes, Q_MOVABLE_TYPE)
A set of attributes controlling the appearance of grids.
#define KDCHART_DECLARE_SWAP_SPECIALISATION(X)

Klarälvdalens Datakonsult AB (KDAB)
"The Qt, C++ and OpenGL Experts"
https://www.kdab.com/

https://www.kdab.com/development-resources/qt-tools/kd-chart/