barchart visualisation improvements
This commit is contained in:
parent
a4506cd44a
commit
4206a8cbf7
|
@ -118,7 +118,7 @@ func (b *BarChart) reselectMaxValue() {
|
|||
func (b *BarChart) Draw(buffer *ui.Buffer) {
|
||||
b.Block.Draw(buffer)
|
||||
|
||||
barWidth := int(math.Ceil(float64(b.Inner.Dx()-2*barIndent-len(b.bars)*barIndent) / float64(len(b.bars))))
|
||||
barWidth := int(math.Floor(float64(b.Inner.Dx()-len(b.bars)*barIndent) / float64(len(b.bars))))
|
||||
barXCoordinate := b.Inner.Min.X + barIndent
|
||||
|
||||
labelStyle := ui.NewStyle(b.palette.BaseColor)
|
||||
|
|
Loading…
Reference in New Issue