Skip to content
Permalink
Browse files

Fix set-but-unused build warning

  • Loading branch information
nyalldawson committed Aug 31, 2020
1 parent e8a7795 commit c79c8fc12c7be81b0b3aa3da8f1568d7cfb77059
Showing with 0 additions and 4 deletions.
  1. +0 −4 src/core/symbology/qgsmarkersymbollayer.cpp
@@ -2024,7 +2024,6 @@ void QgsSvgMarkerSymbolLayer::renderPoint( QPointF point, QgsSymbolRenderContext
bool fitsInCache = true;
bool usePict = true;
bool rasterizeSelected = !mHasFillParam || mDataDefinedProperties.isActive( QgsSymbolLayer::PropertyName );
double hwRatio = 1.0;
if ( ( !context.renderContext().forceVectorOutput() && !rotated ) || ( context.selected() && rasterizeSelected ) )
{
QImage img = QgsApplication::svgCache()->svgAsImage( path, size, fillColor, strokeColor, strokeWidth,
@@ -2043,12 +2042,10 @@ void QgsSvgMarkerSymbolLayer::renderPoint( QPointF point, QgsSymbolRenderContext
QImage transparentImage = img.copy();
QgsSymbolLayerUtils::multiplyImageOpacity( &transparentImage, context.opacity() );
p->drawImage( -transparentImage.width() / 2.0, -transparentImage.height() / 2.0, transparentImage );
hwRatio = static_cast< double >( transparentImage.height() ) / static_cast< double >( transparentImage.width() );
}
else
{
p->drawImage( -img.width() / 2.0, -img.height() / 2.0, img );
hwRatio = static_cast< double >( img.height() ) / static_cast< double >( img.width() );
}
}
}
@@ -2064,7 +2061,6 @@ void QgsSvgMarkerSymbolLayer::renderPoint( QPointF point, QgsSymbolRenderContext
QgsScopedQPainterState painterPictureState( p );
_fixQPictureDPI( p );
p->drawPicture( 0, 0, pct );
hwRatio = static_cast< double >( pct.height() ) / static_cast< double >( pct.width() );
}
}

0 comments on commit c79c8fc

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