Skip to content
Permalink
Browse files

fix highlighting for identify tool when OTF enabled (closes #4843)

  • Loading branch information
alexbruy committed Feb 2, 2012
1 parent 42617a0 commit 62ba02efb1427dbbd8c839cc71cc7eecbdee4ccd
Showing with 6 additions and 0 deletions.
  1. +6 −0 src/app/qgshighlight.cpp
@@ -17,6 +17,7 @@
#include "qgsgeometry.h"
#include "qgsmapcanvas.h"
#include "qgsmaprenderer.h"
#include "qgscoordinatetransform.h"
#include "qgsvectorlayer.h"
#include <QPainter>

@@ -30,6 +31,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 62ba02e

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