OpenXLSX 1.9.1
Loading...
Searching...
No Matches
XLSparkline.hpp
Go to the documentation of this file.
1#ifndef OPENXLSX_XLSPARKLINE_HPP
2#define OPENXLSX_XLSPARKLINE_HPP
3
4#include "OpenXLSX-Exports.hpp"
5#include "XLXmlFile.hpp"
6#include <string>
7
8namespace OpenXLSX
9{
14
19 {
21 std::string seriesColor {"FF376092"}; // Default blue-ish
22 std::string negativeColor {"FFD00000"}; // Default red
23 std::string markersColor {"FFD00000"};
24 std::string firstMarkerColor {"FFD00000"};
25 std::string lastMarkerColor {"FFD00000"};
26 std::string highMarkerColor {"FFD00000"};
27 std::string lowMarkerColor {"FFD00000"};
28
29 bool markers {false}; // Show markers
30 bool high {false}; // Highlight highest point
31 bool low {false}; // Highlight lowest point
32 bool first {false}; // Highlight first point
33 bool last {false}; // Highlight last point
34 bool negative {false};// Highlight negative points
35 bool displayXAxis {false}; // Show horizontal axis
36 std::string displayEmptyCellsAs {"gap"}; // gap, zero, span
37 };
38
42 class OPENXLSX_EXPORT XLSparkline
43 {
44 public:
46 explicit XLSparkline(XMLNode node);
48
49 XLSparklineType type() const;
50 void setType(XLSparklineType type);
51
52 std::string location() const;
53 void setLocation(const std::string& sqref);
54
55 std::string dataRange() const;
56 void setDataRange(const std::string& formula);
57
58 private:
59 XMLNode m_node;
60 };
61
62} // namespace OpenXLSX
63
64#endif // OPENXLSX_XLSPARKLINE_HPP
Definition XLXmlParser.hpp:84
The XLSparkline class encapsulates a single sparkline group in a worksheet.
Definition XLSparkline.hpp:43
Definition IZipArchive.hpp:18
XLSparklineType
The XLSparklineType enum represents the type of a sparkline.
Definition XLSparkline.hpp:13
The XLSparklineOptions struct encapsulates configuration for a sparkline group.
Definition XLSparkline.hpp:19
bool first
Definition XLSparkline.hpp:32
std::string negativeColor
Definition XLSparkline.hpp:22
bool markers
Definition XLSparkline.hpp:29
bool low
Definition XLSparkline.hpp:31
std::string lastMarkerColor
Definition XLSparkline.hpp:25
std::string firstMarkerColor
Definition XLSparkline.hpp:24
std::string highMarkerColor
Definition XLSparkline.hpp:26
std::string displayEmptyCellsAs
Definition XLSparkline.hpp:36
XLSparklineType type
Definition XLSparkline.hpp:20
std::string lowMarkerColor
Definition XLSparkline.hpp:27
bool last
Definition XLSparkline.hpp:33
bool displayXAxis
Definition XLSparkline.hpp:35
bool high
Definition XLSparkline.hpp:30
std::string markersColor
Definition XLSparkline.hpp:23
bool negative
Definition XLSparkline.hpp:34
std::string seriesColor
Definition XLSparkline.hpp:21