implemented continuous pan.
(when the cursor reaches an edge of the image widget it moves to the other edge)