Documentation
¶
Overview ¶
package axis provides implementations of drawing rothko axes.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Label ¶
type Label struct {
// Position is the position of the tick mark as a float in [0, 1].
Position float64
// Text is the text of the tick mark.
Text string
}
Label represents a tick mark on the axis.
type Measured ¶
type Measured struct {
// Width is the width in pixels of the drawn axis.
Width int
// Height is the height in pixels of the drawn axis
Height int
// contains filtered or unexported fields
}
type Options ¶
type Options struct {
// Face is the font face to use for rendering the label text.
Face font.Face
// Labels is the set of labels to draw.
Labels []Label
// Vertical is if the axis is vertical.
Vertical bool
// Length is how long the axis is.
Length int
// If true, vertical axes will be drawn for the left size. Horizontal axes
// ignore this field.
Flip bool
// If true, the label text will not go past the boundaries of Length.
DontBleed bool
}
Options describe the axis rendering options.
Click to show internal directories.
Click to hide internal directories.