Skip to content
Permalink
Browse files
Update tests
  • Loading branch information
nyalldawson committed Oct 22, 2021
1 parent afd2154 commit a4c61f0390694203c8b9fe838f534f0df7af3b3c
@@ -3558,6 +3558,10 @@ void QgsPointPatternFillSymbolLayer::renderPolygon( const QPolygonF &points, con
_renderPolygon( p, points, rings, context );
}

// if invalid parameters, skip out
if ( qgsDoubleNear( width, 0 ) || qgsDoubleNear( height, 0 ) || width < 0 || height < 0 )
return;

p->save();

QPainterPath path;
@@ -161,9 +161,13 @@ void TestQgsPointPatternFillSymbol::pointPatternFillSymbolVector()
QgsMarkerSymbol *pointSymbol = QgsMarkerSymbol::createSimple( properties );

mPointPatternFill->setSubSymbol( pointSymbol );
mPointPatternFill->setDistanceX( 10 );
mPointPatternFill->setDistanceY( 10 );
mMapSettings.setFlag( Qgis::MapSettingsFlag::ForceVectorOutput, true );
const bool res = imageCheck( "symbol_pointfill_vector" );
mMapSettings.setFlag( Qgis::MapSettingsFlag::ForceVectorOutput, false );
mPointPatternFill->setDistanceX( 15 );
mPointPatternFill->setDistanceY( 15 );
QVERIFY( res );

// also confirm that output is indeed vector!
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit a4c61f0

Please sign in to comment.