28 QgsPoint ptMapCenterRightMU( ptMapCenterMU.
x() + distMU, ptMapCenterMU.
y() );
31 double distLU = sqrt( ptMapCenterLU.sqrDist( ptMapCenterRightLU ) );
32 double ratio = distMU / distLU;
41 else if ( units ==
Pixels )
46 return tolerance *
_ratioMU2LU( mapSettings, layer );
58 else if ( units ==
Pixels )
60 double layerUnitsPerPixel = computeMapUnitPerPixel( layer, mapSettings );
61 return tolerance * layerUnitsPerPixel;
66 return tolerance /
_ratioMU2LU( mapSettings, layer );
78 double tolerance = settings.value(
"/qgis/digitizing/search_radius_vertex_edit", 10 ).toDouble();
88 double tolerance = settings.value(
"/qgis/digitizing/search_radius_vertex_edit", 10 ).toDouble();
101 double tolerance = settings.value(
"/qgis/digitizing/default_snapping_tolerance", 0 ).toDouble();
124 QgsPoint p1 = toLayerCoordinates( layer, mapSettings, QPoint( 0, 1 ) );
125 QgsPoint p2 = toLayerCoordinates( layer, mapSettings, QPoint( 0, 2 ) );
126 QgsPoint p3 = toLayerCoordinates( layer, mapSettings, QPoint( 1, 0 ) );
127 QgsPoint p4 = toLayerCoordinates( layer, mapSettings, QPoint( 2, 0 ) );