feat: support split line show option for charts, #69
This commit is contained in:
parent
c7c0655113
commit
f1a231ff4b
13 changed files with 23 additions and 21 deletions
5
yaxis.go
5
yaxis.go
|
|
@ -50,6 +50,8 @@ type YAxisOption struct {
|
|||
DivideCount int
|
||||
Unit int
|
||||
isCategoryAxis bool
|
||||
// The flag for show axis split line, set this to true will show axis split line
|
||||
SplitLineShow *bool
|
||||
}
|
||||
|
||||
// NewYAxisOptions returns a y axis option
|
||||
|
|
@ -100,6 +102,9 @@ func (opt *YAxisOption) ToAxisOption(p *Painter) AxisOption {
|
|||
axisOpt.StrokeWidth = 1
|
||||
axisOpt.SplitLineShow = false
|
||||
}
|
||||
if opt.SplitLineShow != nil {
|
||||
axisOpt.SplitLineShow = *opt.SplitLineShow
|
||||
}
|
||||
return axisOpt
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue