|
117 | 117 | #include "qgsdecorationcopyright.h"
|
118 | 118 | #include "qgsdecorationnortharrow.h"
|
119 | 119 | #include "qgsdecorationscalebar.h"
|
| 120 | +#include "qgsdecorationgrid.h" |
120 | 121 | #include "qgsembedlayerdialog.h"
|
121 | 122 | #include "qgsencodingfiledialog.h"
|
122 | 123 | #include "qgsexception.h"
|
@@ -1609,6 +1610,7 @@ void QgisApp::setTheme( QString theThemeName )
|
1609 | 1610 | mActionDecorationCopyright->setIcon( getThemeIcon( "/plugins/copyright_label.png" ) );
|
1610 | 1611 | mActionDecorationNorthArrow->setIcon( getThemeIcon( "/plugins/north_arrow.png" ) );
|
1611 | 1612 | mActionDecorationScaleBar->setIcon( getThemeIcon( "/plugins/scale_bar.png" ) );
|
| 1613 | + mActionDecorationGrid->setIcon( getThemeIcon( "/transformed.png" ) ); |
1612 | 1614 |
|
1613 | 1615 | //change themes of all composers
|
1614 | 1616 | QSet<QgsComposer*>::iterator composerIt = mPrintComposers.begin();
|
@@ -2016,6 +2018,12 @@ void QgisApp::createDecorations()
|
2016 | 2018 | connect( mActionDecorationScaleBar, SIGNAL( triggered() ), mDecorationScaleBar, SLOT( run() ) );
|
2017 | 2019 | connect( mMapCanvas, SIGNAL( renderComplete( QPainter * ) ), mDecorationScaleBar, SLOT( renderScaleBar( QPainter * ) ) );
|
2018 | 2020 | connect( this, SIGNAL( projectRead() ), mDecorationScaleBar, SLOT( projectRead() ) );
|
| 2021 | + |
| 2022 | + // TODO draw the decorations in a particular order - perhaps use a vector or decoration objects? |
| 2023 | + mDecorationGrid = new QgsDecorationGrid( this ); |
| 2024 | + connect( mActionDecorationGrid, SIGNAL( triggered() ), mDecorationGrid, SLOT( run() ) ); |
| 2025 | + connect( mMapCanvas, SIGNAL( renderComplete( QPainter * ) ), mDecorationGrid, SLOT( renderGrid( QPainter * ) ) ); |
| 2026 | + connect( this, SIGNAL( projectRead() ), mDecorationGrid, SLOT( projectRead() ) ); |
2019 | 2027 | }
|
2020 | 2028 |
|
2021 | 2029 | // Update file menu with the current list of recently accessed projects
|
|
0 commit comments