summaryrefslogtreecommitdiff
path: root/core/fxge/cfx_graphstatedata.h
diff options
context:
space:
mode:
Diffstat (limited to 'core/fxge/cfx_graphstatedata.h')
-rw-r--r--core/fxge/cfx_graphstatedata.h36
1 files changed, 20 insertions, 16 deletions
diff --git a/core/fxge/cfx_graphstatedata.h b/core/fxge/cfx_graphstatedata.h
index a907f2a922..5604802449 100644
--- a/core/fxge/cfx_graphstatedata.h
+++ b/core/fxge/cfx_graphstatedata.h
@@ -7,33 +7,37 @@
#ifndef CORE_FXGE_CFX_GRAPHSTATEDATA_H_
#define CORE_FXGE_CFX_GRAPHSTATEDATA_H_
+#include <vector>
+
#include "core/fxcrt/fx_system.h"
#include "core/fxcrt/retain_ptr.h"
class CFX_GraphStateData final : public Retainable {
public:
- enum LineCap { LineCapButt = 0, LineCapRound = 1, LineCapSquare = 2 };
+ enum LineCap : uint8_t {
+ LineCapButt = 0,
+ LineCapRound = 1,
+ LineCapSquare = 2
+ };
+
+ enum LineJoin : uint8_t {
+ LineJoinMiter = 0,
+ LineJoinRound = 1,
+ LineJoinBevel = 2
+ };
CFX_GraphStateData();
CFX_GraphStateData(const CFX_GraphStateData& src);
~CFX_GraphStateData() override;
- void Copy(const CFX_GraphStateData& src);
- void SetDashCount(int count);
-
- LineCap m_LineCap;
- int m_DashCount;
- float* m_DashArray;
- float m_DashPhase;
+ CFX_GraphStateData& operator=(const CFX_GraphStateData& src);
- enum LineJoin {
- LineJoinMiter = 0,
- LineJoinRound = 1,
- LineJoinBevel = 2,
- };
- LineJoin m_LineJoin;
- float m_MiterLimit;
- float m_LineWidth;
+ LineCap m_LineCap = LineCapButt;
+ LineJoin m_LineJoin = LineJoinMiter;
+ float m_DashPhase = 0.0f;
+ float m_MiterLimit = 10.0f;
+ float m_LineWidth = 1.0f;
+ std::vector<float> m_DashArray;
};
#endif // CORE_FXGE_CFX_GRAPHSTATEDATA_H_