Documentation
¶
Index ¶
- func ArcTo(dc *gg.Context, x1, y1, x2, y2, radius float64)
- func RoundedRect(dc *gg.Context, x, y, w, h, tl, tr, br, bl float64)
- type Canvas
- func (scr *Canvas) FontSize() float64
- func (scr *Canvas) Graphics() *gg.Context
- func (scr *Canvas) LineWidth() float64
- func (scr *Canvas) Reset(width, height int)
- func (scr *Canvas) SavePNG(path string) error
- func (scr *Canvas) SetFontSize(size float64)
- func (scr *Canvas) SetLineWidth(size float64)
- func (scr *Canvas) SetWorldCoordinates(xMin, xMax float64, yMin, yMax float64) error
- func (scr *Canvas) Size() (int, int)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ArcTo ¶ added in v0.4.1
https://github.com/WebKit/webkit/blob/main/Source/WebCore/platform/graphics/cairo/PathCairo.cpp#L204
func RoundedRect ¶ added in v0.4.1
Types ¶
type Canvas ¶
type Canvas struct {
// contains filtered or unexported fields
}
Canvas defines a drawing context.
func (*Canvas) SetFontSize ¶
SetFontSize sets the font's size.
func (*Canvas) SetLineWidth ¶ added in v0.4.1
SetLineWidth sets the lineWidth.
func (*Canvas) SetWorldCoordinates ¶
SetWorldCoordinates sets up user-defined coordinate system.
xMin: x-coordinate of lower left corner of canvas. xMax: x-coordinate of upper right corner of canvas. yMin: y-coordinate of lower left corner of canvas. yMax: y-coordinate of upper right corner of canvas.
Click to show internal directories.
Click to hide internal directories.