Skip to content

Commit 8ffa084

Browse files
committed
Fix arrow and filled marker symbols don't show selection state
1 parent ab782eb commit 8ffa084

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

src/core/symbology-ng/qgsarrowsymbollayer.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -709,7 +709,7 @@ void QgsArrowSymbolLayer::renderPolyline( const QPolygonF& points, QgsSymbolRend
709709
QPointF pd( points.back() );
710710

711711
QPolygonF poly = curvedArrow( po, pm, pd, mScaledArrowStartWidth, mScaledArrowWidth, mScaledHeadLength, mScaledHeadThickness, mComputedHeadType, mComputedArrowType, mScaledOffset );
712-
mSymbol->renderPolygon( poly, /* rings */ nullptr, context.feature(), context.renderContext() );
712+
mSymbol->renderPolygon( poly, /* rings */ nullptr, context.feature(), context.renderContext(), -1, context.selected() );
713713
}
714714
// straight arrow
715715
else if ( points.size() == 2 )
@@ -720,7 +720,7 @@ void QgsArrowSymbolLayer::renderPolyline( const QPolygonF& points, QgsSymbolRend
720720
QPointF pd( points.at( 1 ) );
721721

722722
QPolygonF poly = straightArrow( po, pd, mScaledArrowStartWidth, mScaledArrowWidth, mScaledHeadLength, mScaledHeadThickness, mComputedHeadType, mComputedArrowType, mScaledOffset );
723-
mSymbol->renderPolygon( poly, /* rings */ nullptr, context.feature(), context.renderContext() );
723+
mSymbol->renderPolygon( poly, /* rings */ nullptr, context.feature(), context.renderContext(), -1, context.selected() );
724724
}
725725
}
726726
else
@@ -740,7 +740,7 @@ void QgsArrowSymbolLayer::renderPolyline( const QPolygonF& points, QgsSymbolRend
740740
QPointF pd( points.at( pIdx + 2 ) );
741741

742742
QPolygonF poly = curvedArrow( po, pm, pd, mScaledArrowStartWidth, mScaledArrowWidth, mScaledHeadLength, mScaledHeadThickness, mComputedHeadType, mComputedArrowType, mScaledOffset );
743-
mSymbol->renderPolygon( poly, /* rings */ nullptr, context.feature(), context.renderContext() );
743+
mSymbol->renderPolygon( poly, /* rings */ nullptr, context.feature(), context.renderContext(), -1, context.selected() );
744744
}
745745
// straight arrow
746746
else if ( points.size() - pIdx == 2 )
@@ -751,7 +751,7 @@ void QgsArrowSymbolLayer::renderPolyline( const QPolygonF& points, QgsSymbolRend
751751
QPointF pd( points.at( pIdx + 1 ) );
752752

753753
QPolygonF poly = straightArrow( po, pd, mScaledArrowStartWidth, mScaledArrowWidth, mScaledHeadLength, mScaledHeadThickness, mComputedHeadType, mComputedArrowType, mScaledOffset );
754-
mSymbol->renderPolygon( poly, /* rings */ nullptr, context.feature(), context.renderContext() );
754+
mSymbol->renderPolygon( poly, /* rings */ nullptr, context.feature(), context.renderContext(), -1, context.selected() );
755755
}
756756
}
757757
}
@@ -770,7 +770,7 @@ void QgsArrowSymbolLayer::renderPolyline( const QPolygonF& points, QgsSymbolRend
770770
QPointF pd( points.back() );
771771

772772
QPolygonF poly = straightArrow( po, pd, mScaledArrowStartWidth, mScaledArrowWidth, mScaledHeadLength, mScaledHeadThickness, mComputedHeadType, mComputedArrowType, mScaledOffset );
773-
mSymbol->renderPolygon( poly, /* rings */ nullptr, context.feature(), context.renderContext() );
773+
mSymbol->renderPolygon( poly, /* rings */ nullptr, context.feature(), context.renderContext(), -1, context.selected() );
774774
}
775775
}
776776
else
@@ -787,7 +787,7 @@ void QgsArrowSymbolLayer::renderPolyline( const QPolygonF& points, QgsSymbolRend
787787
QPointF pd( points.at( pIdx + 1 ) );
788788

789789
QPolygonF poly = straightArrow( po, pd, mScaledArrowStartWidth, mScaledArrowWidth, mScaledHeadLength, mScaledHeadThickness, mComputedHeadType, mComputedArrowType, mScaledOffset );
790-
mSymbol->renderPolygon( poly, /* rings */ nullptr, context.feature(), context.renderContext() );
790+
mSymbol->renderPolygon( poly, /* rings */ nullptr, context.feature(), context.renderContext(), -1, context.selected() );
791791
}
792792
}
793793
}

src/core/symbology-ng/qgsmarkersymbollayer.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1695,12 +1695,12 @@ void QgsFilledMarkerSymbolLayer::draw( QgsSymbolRenderContext &context, QgsSimpl
16951695

16961696
if ( !polygon.isEmpty() )
16971697
{
1698-
mFill->renderPolygon( polygon, /* rings */ nullptr, context.feature(), context.renderContext() );
1698+
mFill->renderPolygon( polygon, /* rings */ nullptr, context.feature(), context.renderContext(), -1, context.selected() );
16991699
}
17001700
else
17011701
{
17021702
QPolygonF poly = path.toFillPolygon();
1703-
mFill->renderPolygon( poly, /* rings */ nullptr, context.feature(), context.renderContext() );
1703+
mFill->renderPolygon( poly, /* rings */ nullptr, context.feature(), context.renderContext(), -1, context.selected() );
17041704
}
17051705

17061706

0 commit comments

Comments
 (0)