Skip to content
Permalink
Browse files

Keep Z/M information when digitizing from a snapped point (fixes #14318)

  • Loading branch information
mhugo committed Feb 17, 2016
1 parent 22b27c5 commit bcded3c2d49957b9871653258eaf9b2c37ecd024
Showing with 4 additions and 3 deletions.
  1. +4 −3 src/gui/qgsmaptoolcapture.cpp
@@ -376,13 +376,14 @@ int QgsMapToolCapture::fetchLayerPoint( QgsPointLocator::Match match , QgsPointV
{
QgsFeature f;
QgsFeatureRequest request;
QgsPoint foundPoint;
request.setFilterFid( match.featureId() );
bool fetched = match.layer()->getFeatures( request ).nextFeature( f );
if ( fetched )
{
foundPoint = f.geometry()->vertexAt( match.vertexIndex() );
layerPoint = QgsPointV2( foundPoint.x(), foundPoint.y() );
QgsVertexId vId;
if ( !f.geometry()->vertexIdFromVertexNr( match.vertexIndex(), vId ) )
return 2;
layerPoint = f.geometry()->geometry()->vertexAt( vId );
return 0;
}
else

0 comments on commit bcded3c

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