22 #include <QMouseEvent>
29 QBitmap panBmp = QBitmap::fromData( QSize( 16, 16 ),
pan_bits );
30 QBitmap panBmpMask = QBitmap::fromData( QSize( 16, 16 ),
pan_mask_bits );
31 mCursor = QCursor( panBmp, panBmpMask, 5, 5 );
37 if (( e->buttons() & Qt::LeftButton ) )
47 if ( e->button() == Qt::LeftButton )
A rectangle specified with double values.
const unsigned char pan_bits[]
void setExtent(const QgsRectangle &r)
Set the extent of the map canvas.
void refresh()
Repaints the canvas map.
Map canvas is a class for displaying all GIS data types on a canvas.
A class to represent a point geometry.
const unsigned char pan_mask_bits[]
void panAction(QMouseEvent *event)
Called when mouse is moving and pan is activated.
const QgsMapToPixel * getCoordinateTransform()
Get the current coordinate transform.
QgsPoint toMapPoint(double x, double y) const
void panActionEnd(QPoint releasePoint)
Ends pan action and redraws the canvas.