I have a simple vector layer with LineString geometry. I want to styling this with dash line. How can I implement this with PyQGIS? I need to implement Stroke style property and red color as styling.
1 Answer
symbol = QgsLineSymbol.createSimple({'line_style':'dash','color':symbolColor, 'width':'1.5'})
layer.renderer().setSymbol(symbol)
layer.triggerRepaint()