22#include <kiwano/platform/NativeObject.hpp>
95 float dash_offset = 0.0f);
105 template <
size_t _DashSize>
107 float dash_offset = 0.0f)
108 :
StrokeStyle(width, cap, line_join, dash_array, _DashSize, dash_offset)
161 void SetDashStyle(
const float* dash_array,
size_t dash_size);
167 template <
size_t _DashSize>
183 Vector<float> dash_array_;
190 return stroke_width_;
215 stroke_width_ = width;
225 line_join_ = line_join;
230 dash_offset_ = dash_offset;
含有本地指针的对象
Definition: NativeObject.hpp:32
线条样式
Definition: StrokeStyle.h:68
float GetDashOffset() const
获取虚线偏移量
Definition: StrokeStyle.h:208
void SetDashStyle(DashStyle dash_style)
设置虚线样式
Definition: StrokeStyle.cpp:60
float GetWidth() const
获取线条宽度
Definition: StrokeStyle.h:188
StrokeStyle(float width, CapStyle cap, LineJoinStyle line_join, float(&dash_array)[_DashSize], float dash_offset=0.0f)
创建线条样式
Definition: StrokeStyle.h:106
void SetDashOffset(float dash_offset)
设置虚线偏移量
Definition: StrokeStyle.h:228
void SetCapStyle(CapStyle cap)
设置线条端点样式
Definition: StrokeStyle.h:218
CapStyle GetCapStyle() const
获取线条端点样式
Definition: StrokeStyle.h:193
void SetLineJoinStyle(LineJoinStyle line_join)
设置线条交点样式
Definition: StrokeStyle.h:223
LineJoinStyle GetLineJoinStyle() const
获取线条交点样式
Definition: StrokeStyle.h:198
void SetDashStyle(float(&dash_array)[_DashSize])
设置虚线样式
Definition: StrokeStyle.h:168
void SetWidth(float width)
设置线条宽度
Definition: StrokeStyle.h:213
const Vector< float > & GetDashArray() const
获取线条虚线的长度与间隙数组
Definition: StrokeStyle.h:203
CapStyle
线条端点样式
Definition: StrokeStyle.h:36
LineJoinStyle
线条交点样式
Definition: StrokeStyle.h:47
DashStyle
线条虚线样式
Definition: StrokeStyle.h:57
@ Triangle
三角样式,三角斜边长度等于线段宽度
@ Square
方形端点,方形突出部分等于线段宽度的一半