0
Reply

Implementing Panning

Richard Gladstone

Richard Gladstone

Jan 27 2007 9:35 PM
1.7k
I am writing a light duty CAD program and am having difficulty implementing panning.  I would like to be able to pan a drawing by grabbing it with the mouse, holding down the left mouse button and moving drawing synchronously with the movement of the mouse. 

The image pans correctly, but the mouse cursor moves faster than the image. Is there a code sample for implementing panning correctly?