go-chart/axis.go

20 lines
507 B
Go
Raw Normal View History

2016-07-10 10:11:47 +02:00
package chart
// YAxisType is a type of y-axis; it can either be primary or secondary.
type YAxisType int
const (
// YAxisPrimary is the primary axis.
YAxisPrimary YAxisType = 0
// YAxisSecondary is the secondary axis.
YAxisSecondary YAxisType = 1
)
// Axis is a chart feature detailing what values happen where.
type Axis interface {
GetName() string
GetStyle() Style
2016-07-10 19:43:04 +02:00
GetTicks(r Renderer, ra Range, vf ValueFormatter) []Tick
Render(c *Chart, r Renderer, canvasBox Box, ra Range, ticks []Tick)
2016-07-10 10:11:47 +02:00
}