Skip to content
Permalink
Browse files
fix highlighting for identify tool when OTF enabled (closes #4843)
  • Loading branch information
alexbruy committed Feb 11, 2012
1 parent 49cdac0 commit 09ce9d47b442577890484104af49fc4fa85c7ee2
Showing with 6 additions and 0 deletions.
  1. +6 −0 src/app/qgshighlight.cpp
@@ -18,6 +18,7 @@
#include "qgsgeometry.h"
#include "qgsmapcanvas.h"
#include "qgsmaprenderer.h"
#include "qgscoordinatetransform.h"
#include "qgsvectorlayer.h"
#include <QPainter>

@@ -31,6 +32,11 @@ QgsHighlight::QgsHighlight( QgsMapCanvas* mapCanvas, QgsGeometry *geom, QgsVecto
, mLayer( layer )
{
mGeometry = geom ? new QgsGeometry( *geom ) : 0;
if ( mapCanvas->mapRenderer()->hasCrsTransformEnabled() )
{
QgsCoordinateTransform transform( mLayer->crs(), mapCanvas->mapRenderer()->destinationCrs() );
mGeometry->transform( transform );
}
updateRect();
update();
setColor( QColor( Qt::lightGray ) );

0 comments on commit 09ce9d4

Please sign in to comment.