laying groundwork for grid lines and a refactor of translate
This commit is contained in:
parent
693a2ab66f
commit
52e80c183d
|
@ -49,7 +49,7 @@ func (as AnnotationSeries) Measure(r Renderer, canvasBox Box, xrange, yrange Ran
|
||||||
Padding: DefaultAnnotationPadding,
|
Padding: DefaultAnnotationPadding,
|
||||||
})
|
})
|
||||||
for _, a := range as.Annotations {
|
for _, a := range as.Annotations {
|
||||||
lx := canvasBox.Left - xrange.Translate(a.X)
|
lx := canvasBox.Left + xrange.Translate(a.X)
|
||||||
ly := canvasBox.Bottom - yrange.Translate(a.Y)
|
ly := canvasBox.Bottom - yrange.Translate(a.Y)
|
||||||
ab := MeasureAnnotation(r, canvasBox, style, lx, ly, a.Label)
|
ab := MeasureAnnotation(r, canvasBox, style, lx, ly, a.Label)
|
||||||
box.Top = MinInt(box.Top, ab.Top)
|
box.Top = MinInt(box.Top, ab.Top)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user