Skip to content

Commit 21bf070

Browse files
committed
io/pointer: clarify the documentation for Event.Position
Signed-off-by: Elias Naur <[email protected]>
1 parent e2915e5 commit 21bf070

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

io/pointer/pointer.go

+4-2
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,10 @@ type Event struct {
3232
Time time.Duration
3333
// Buttons are the set of pressed mouse buttons for this event.
3434
Buttons Buttons
35-
// Position is the position of the event, relative to
36-
// the current transformation, as set by op.TransformOp.
35+
// Position is the coordinates of the event in the local coordinate
36+
// system of the receiving tag. The transformation from global window
37+
// coordinates to local coordinates is performed by the inverse of
38+
// the [gioui.org/op.TransformOp]s applied to the [InputOp].
3739
Position f32.Point
3840
// Scroll is the scroll amount, if any.
3941
Scroll f32.Point

0 commit comments

Comments
 (0)