Mouse events for lines

Includes a rather pointless example, which I will want to revisit at some point.