### Navigation

- index
- modules |
- next |
- previous |
- home|
- examples|
- tutorials|
- pyplot|
- docs »
- The Matplotlib API »
- `Axes` class »

# matplotlib.axes.Axes.drag_pan

`Axes.``drag_pan`(button, key, x, y)

  Called when the mouse moves during a pan operation.

  button is the mouse button number:

  - 1: LEFT
  - 2: MIDDLE
  - 3: RIGHT

  key is a “shift” key

  x, y are the mouse coordinates in display coords.

  Note

  Intended to be overridden by new projection types.