Skip to content

Commit

Permalink
[composer] Clean up map grid API, fix bug with grids not rearranging
Browse files Browse the repository at this point in the history
correctly (sponsored by NIWA, New Zealand)
  • Loading branch information
nyalldawson committed Sep 3, 2014
1 parent 4eeb818 commit 6adab88
Show file tree
Hide file tree
Showing 10 changed files with 1,700 additions and 1,029 deletions.
8 changes: 0 additions & 8 deletions src/app/composer/qgscomposer.cpp
Expand Up @@ -3304,14 +3304,6 @@ bool QgsComposer::containsAdvancedEffects() const
return true;
}
}
if ( currentMap->gridEnabled() )
{
// map contains an grid, check its blend mode
if ( currentMap->gridBlendMode() != QPainter::CompositionMode_SourceOver )
{
return true;
}
}
}
}
return false;
Expand Down
213 changes: 108 additions & 105 deletions src/app/composer/qgscomposermapwidget.cpp

Large diffs are not rendered by default.

9 changes: 5 additions & 4 deletions src/app/composer/qgscomposermapwidget.h
Expand Up @@ -20,6 +20,7 @@

#include "ui_qgscomposermapwidgetbase.h"
#include "qgscomposermap.h"
#include "qgscomposermapgrid.h"
#include "qgscomposeritemwidget.h"

class QgsMapLayer;
Expand Down Expand Up @@ -163,14 +164,14 @@ class QgsComposerMapWidget: public QgsComposerItemBaseWidget, private Ui::QgsCom
/**Blocks / unblocks the signals of all GUI elements*/
void blockAllSignals( bool b );

void handleChangedAnnotationPosition( QgsComposerMap::Border border, const QString& text );
void handleChangedAnnotationDirection( QgsComposerMap::Border border, const QString& text );
void handleChangedAnnotationPosition( QgsComposerMapGrid::BorderSide border, const QString& text );
void handleChangedAnnotationDirection( QgsComposerMapGrid::BorderSide border, const QString& text );

void insertAnnotationPositionEntries( QComboBox* c );
void insertAnnotationDirectionEntries( QComboBox* c );

void initAnnotationPositionBox( QComboBox* c, QgsComposerMap::GridAnnotationPosition pos );
void initAnnotationDirectionBox( QComboBox* c, QgsComposerMap::GridAnnotationDirection dir );
void initAnnotationPositionBox( QComboBox* c, QgsComposerMapGrid::AnnotationPosition pos );
void initAnnotationDirectionBox( QComboBox* c, QgsComposerMapGrid::AnnotationDirection dir );

void updateGridLineSymbolMarker( const QgsComposerMapGrid* grid );
void updateGridMarkerSymbolMarker( const QgsComposerMapGrid* grid );
Expand Down
2 changes: 1 addition & 1 deletion src/core/composer/qgscomposeritem.cpp
Expand Up @@ -1280,7 +1280,7 @@ void QgsComposerItem::deleteAlignItems()

void QgsComposerItem::repaint()
{
update();
updateItem();
}

void QgsComposerItem::refreshDataDefinedProperty( const QgsComposerObject::DataDefinedProperty property )
Expand Down

0 comments on commit 6adab88

Please sign in to comment.