3

Anyone knows how to do a color gradient from the console to a shapefile in QGIS (or in Python)? Like the image below.

enter image description here

nmtoken
  • 13,355
  • 5
  • 38
  • 87
Vassilis
  • 3,444
  • 7
  • 44
  • 56

1 Answers1

5

I don't think this is possible in QGIS 2.0. (We already had this question in 2011 - just without the Python aspect: Polygon gradient fills / tint bands in QGIS)

For the next version, a gradient fill has been announced by http://nyalldawson.net/2013/09/sneak-peak/:

enter image description here

This is the responsible class: http://www.qgis.org/api/classQgsGradientFillSymbolLayerV2.html and there seems to be an option to let the gradient start from the center of the polygon:

setReferencePoint1IsCentroid (bool isCentroid) 

Sets the starting point of the gradient to be the feature centroid

underdark
  • 84,148
  • 21
  • 231
  • 413