mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-01 07:35:40 +00:00
op/clip: add note about Path.End
Signed-off-by: Egon Elbre <egonelbre@gmail.com>
This commit is contained in:
@@ -138,6 +138,9 @@ type Path struct {
|
|||||||
func (p *Path) Pos() f32.Point { return p.pen }
|
func (p *Path) Pos() f32.Point { return p.pen }
|
||||||
|
|
||||||
// Begin the path, storing the path data and final Op into ops.
|
// Begin the path, storing the path data and final Op into ops.
|
||||||
|
//
|
||||||
|
// Caller must also call End to finish the drawing.
|
||||||
|
// Forgetting to call it will result in a "panic: cannot mix multi ops with single ones".
|
||||||
func (p *Path) Begin(o *op.Ops) {
|
func (p *Path) Begin(o *op.Ops) {
|
||||||
*p = Path{
|
*p = Path{
|
||||||
ops: &o.Internal,
|
ops: &o.Internal,
|
||||||
|
|||||||
Reference in New Issue
Block a user