MCPcopy
hub / github.com/tdewolff/canvas / HatchPattern

Struct HatchPattern

patterns.go:47–52  ·  view source on GitHub ↗

type CanvasPattern struct { c *Canvas cell Matrix } func NewPattern(c *Canvas, cell Matrix) *CanvasPattern { return &CanvasPattern{ c: c, cell: cell, } } func (p *CanvasPattern) ClipTo(r Renderer, clip *Path) { //fmt.Println("src", p.c.Size()) //fmt.Println("dst", r.Size()) //fmt.

Source from the content-addressed store, hash-verified

45
46// Hatch pattern is a filling hatch pattern.
47type HatchPattern struct {
48 Fill Paint
49 Thickness float64
50 cell Matrix
51 hatch Hatcher
52}
53
54// Hatcher is a hatch pattern along the cell's axes. The rectangle (x0,y0)-(x1,y1) is expressed in the unit cell's coordinate system, and the returned path should be transformed by the cell to obtain the final hatch pattern.
55type Hatcher func(float64, float64, float64, float64) *Path

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected