mouseMotionListener
Runs onMouseMove whenever the pointer moves over the component, whether or not a button is held.
onMouseMove is read when the event fires, so writing a fresh lambda on every recomposition registers nothing again.
Return
this chain with the mouse motion callback declared on it.
Parameters
receives the event, whose x and y are in the component's own coordinates and can fall outside it while a drag that began here continues.
See also
Runs onMouseDragged while the pointer moves with a button held, and onMouseMoved while it moves with none. A movement left undeclared reports nowhere.
Each lambda is read when its event fires, so writing a fresh one on every recomposition registers nothing again.
Declaring none at all is refused.
Return
this chain with the mouse motion callbacks declared on it.
Parameters
keeps reporting after the pointer leaves the component, until the button is released.
stops as soon as the pointer leaves.
See also
Attaches a MouseMotionListener (addMouseMotionListener/removeMouseMotionListener).
Return
this chain with the mouse motion listener declared on it.
Parameters
attached by identity, so a remembered instance stays put while a fresh one on every pass is detached and re-added.