Skip to main content
2 of 2
deleted 47 characters in body; added 3 characters in body
PolyGeo
  • 65.4k
  • 29
  • 114
  • 345

When I tried the to use code based on the answer by @GreyEyedPallas (in QGIS 2.18), I got a message:

AttributeError: 'NoneType' object has no attribute 'createSymbolLayer'

To fix this, I needed to use ArrowLine instead of LineDecoration as follows:

sl = QgsSymbolLayerV2Registry.instance().symbolLayerMetadata("ArrowLine").createSymbolLayer({ 'width' : '0.26', 'color' : '0,0,0' })  
symbollist = layer.rendererV2().symbols()  
symbol = symbollist[0]  
symbol.appendSymbolLayer(sl)
Jonny
  • 469
  • 3
  • 15