Skip to content

Commit

Permalink
option 2
Browse files Browse the repository at this point in the history
Signed-off-by: Ivan Valdes <[email protected]>
  • Loading branch information
ivanvc committed Dec 11, 2024
1 parent de32de6 commit aed1d42
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions tools/rw-heatmaps/pkg/chart/line_chart.go
Original file line number Diff line number Diff line change
Expand Up @@ -202,22 +202,25 @@ func addValues(p *plot.Plot, legend *plot.Legend, values []int, rec map[int64][]
if err != nil {
panic(err)
}
if index > 0 {
readLine.Dashes = []vg.Length{vg.Points(6), vg.Points(2)}
if index == 0 {
readLine.Color = plotutil.Color(0)
} else {
readLine.Color = plotutil.Color(2)
}
readLine.Color = plotutil.Color(0)
readLine.Width = vg.Length(vg.Millimeter * 0.15 * vg.Length(i+1))
readLine.Dashes = []vg.Length{vg.Points(6), vg.Points(2)}
s.Color = readLine.Color
p.Add(readLine, s)

writeLine, s, err := plotter.NewLinePoints(writePts)
if err != nil {
panic(err)
}
if index > 0 {
writeLine.Dashes = []vg.Length{vg.Points(6), vg.Points(2)}
if index == 0 {
writeLine.Color = plotutil.Color(0)
} else {
writeLine.Color = plotutil.Color(2)
}
writeLine.Color = plotutil.Color(2)
writeLine.Width = vg.Length(vg.Millimeter * 0.15 * vg.Length(i+1))
s.Color = writeLine.Color
p.Add(writeLine, s)
Expand Down

0 comments on commit aed1d42

Please sign in to comment.