Skip to content

Commit

Permalink
Always clear pen/brush before drawing layer effects (fix #15696)
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Oct 16, 2016
1 parent 6c53641 commit 55f2071
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/core/effects/qgspainteffect.cpp
Expand Up @@ -163,6 +163,11 @@ void QgsPaintEffect::end( QgsRenderContext &context )
context.setPainter( mPrevPainter );
mPrevPainter = nullptr;

// clear any existing pen/brush - sometimes these are not correctly restored when restoring a painter
// with a QPicture destination - see #15696
context.painter()->setPen( Qt::NoPen );
context.painter()->setBrush( Qt::NoBrush );

//draw using effect
render( *mTempPicture, context );

Expand Down

0 comments on commit 55f2071

Please sign in to comment.