Skip to content

Commit

Permalink
Adds a warning using avoid intersections and topological editing
Browse files Browse the repository at this point in the history
  • Loading branch information
lbartoletti committed May 17, 2021
1 parent 80e3a94 commit de6c1ad
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/app/qgssnappingwidget.cpp
Expand Up @@ -35,6 +35,7 @@
#include "qgslayertreeview.h"
#include "qgsmapcanvas.h"
#include "qgsmaplayer.h"
#include "qgsmessagebar.h"
#include "qgsproject.h"
#include "qgssnappingconfig.h"
#include "qgssnappinglayertreemodel.h"
Expand Down Expand Up @@ -530,12 +531,20 @@ void QgsSnappingWidget::projectAvoidIntersectionModeChanged()
mAllowIntersectionsAction->setChecked( false );
mAvoidIntersectionsCurrentLayerAction->setChecked( true );
mAvoidIntersectionsLayersAction->setChecked( false );
if ( mProject->topologicalEditing() )
{
QgisApp::instance()->messageBar()->pushWarning( tr( "Digitizing Warning" ), tr( "By using both avoid intersections and topological editing, geometries can be transformed automatically. Be careful with your modifications." ) );
}
break;
case QgsProject::AvoidIntersectionsMode::AvoidIntersectionsLayers:
mAvoidIntersectionsModeButton->setDefaultAction( mAvoidIntersectionsLayersAction );
mAllowIntersectionsAction->setChecked( false );
mAvoidIntersectionsCurrentLayerAction->setChecked( false );
mAvoidIntersectionsLayersAction->setChecked( true );
if ( mProject->topologicalEditing() )
{
QgisApp::instance()->messageBar()->pushWarning( tr( "Digitizing Warning" ), tr( "By using both avoid intersections and topological editing, geometries can be transformed automatically. Be careful with your modifications." ) );
}
break;
}
}
Expand Down

0 comments on commit de6c1ad

Please sign in to comment.