Skip to content
Permalink
Browse files

Save / restore settings for annotation tools. Developed for Faunalia (h…

…ttp://www.faunalia.it) with funding from Regione Toscana - Settore SISTEMA INFORMATIVO TERRITORIALE ED AMBIENTALE
  • Loading branch information
mhugent committed Nov 6, 2012
1 parent 5a9418c commit 550a2c628626bdc4a7b8a329c844729f63e539c7
Showing with 9 additions and 6 deletions.
  1. +9 −6 src/app/qgisapp.cpp
@@ -1414,8 +1414,10 @@ void QgisApp::createToolBars()
{
case 0: defAnnotationAction = mActionTextAnnotation; break;
case 1: defAnnotationAction = mActionFormAnnotation; break;
case 2: defAnnotationAction = mActionAnnotation; break;
case 3: defAnnotationAction = mActionHtmlAnnotation; break;
case 2: defAnnotationAction = mActionHtmlAnnotation; break;
case 3: defAnnotationAction = mActionSvgAnnotation; break;
case 4: defAnnotationAction = mActionAnnotation; break;

}
bt->setDefaultAction( defAnnotationAction );
QAction* annotationAction = mAttributesToolBar->addWidget( bt );
@@ -8001,11 +8003,12 @@ void QgisApp::toolButtonActionTriggered( QAction *action )
settings.setValue( "/UI/annotationTool", 0 );
else if ( action == mActionFormAnnotation )
settings.setValue( "/UI/annotationTool", 1 );
else if ( action == mActionAnnotation )
settings.setValue( "/UI/annotationTool", 2 );
else if ( action == mActionHtmlAnnotation )
settings.setValue( "/UI/annotationTool", 3 );

settings.setValue( "/UI/annotationTool", 2 );
else if ( action == mActionSvgAnnotation )
settings.setValue( "UI/annotationTool", 3 );
else if ( action == mActionAnnotation )
settings.setValue( "/UI/annotationTool", 4 );
bt->setDefaultAction( action );
}

0 comments on commit 550a2c6

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