Skip to content
Permalink
Browse files

Fix invalid rubber band when digitising polygon and layer CRS

is not the same as map CRS (fix #14117)
  • Loading branch information
nyalldawson committed Jan 18, 2016
1 parent 7e90d57 commit 23fc3cf9ccc1d76baded3f963e936a0e12c80201
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/gui/qgsmaptoolcapture.cpp
@@ -302,7 +302,8 @@ void QgsMapToolCapture::cadCanvasMoveEvent( QgsMapMouseEvent * e )
if ( mCaptureMode == CapturePolygon )
mTempRubberBand->addPoint( *mRubberBand->getPoint( 0, 0 ), false );
QgsPointV2 pt = mCaptureCurve.endPoint();
mTempRubberBand->addPoint( QgsPoint( pt.x(), pt.y() ) );
QgsPoint mapPt = toMapCoordinates( qobject_cast<QgsVectorLayer *>( mCanvas->currentLayer() ), QgsPoint( pt.x(), pt.y() ) );
mTempRubberBand->addPoint( mapPt );
mTempRubberBand->addPoint( point );
}
else

0 comments on commit 23fc3cf

Please sign in to comment.
You can’t perform that action at this time.