MCPcopy Index your code
hub / github.com/gonum/plot / GlyphBoxes

Method GlyphBoxes

plot.go:421–438  ·  view source on GitHub ↗

GlyphBoxes returns the GlyphBoxes for all plot data that meet the GlyphBoxer interface.

(*Plot)

Source from the content-addressed store, hash-verified

419// GlyphBoxes returns the GlyphBoxes for all plot
420// data that meet the GlyphBoxer interface.
421func (p *Plot) GlyphBoxes(*Plot) (boxes []GlyphBox) {
422 for _, d := range p.plotters {
423 gb, ok := d.(GlyphBoxer)
424 if !ok {
425 continue
426 }
427 for _, b := range gb.GlyphBoxes(p) {
428 if b.Size().X > 0 && (b.X < 0 || b.X > 1) {
429 continue
430 }
431 if b.Size().Y > 0 && (b.Y < 0 || b.Y > 1) {
432 continue
433 }
434 boxes = append(boxes, b)
435 }
436 }
437 return
438}
439
440// NominalX configures the plot to have a nominal X
441// axis—an X axis with names instead of numbers. The

Callers 1

DrawGlyphBoxesMethod · 0.95

Calls 2

GlyphBoxesMethod · 0.65
SizeMethod · 0.65

Tested by

no test coverage detected