Hi,
I resolved it.

It was a my bad coding in other point of the program.

The code

        for range in renderer.ranges():
            theLabel = range.label()

Instead is perfectly working.

Sorry for noise.

Andrea.

Il 01/01/2016 10:14, aperi2007 ha scritto:
Hi,
firstly , Happy New Year 2016 to all the QGIS users !!

I need to access to the label of a graduated rendereing using python.
This is the legend I have:



To access it I use this kind of code:

        for range in renderer.ranges():
            theLabel = range.label()

But I dont retrieve the values of the various labels (example: "<= 50.0", or "50.0 - 200.0")
but instead i have the string "DP39-2001".

AFAIK "DP39-2001" should be the name of the layer , I don't understand why it is accessible in the range.label().

I'm wrong something ?

I'm using QGIS-dev.

Thx,

Andrea Peri.


_______________________________________________
Qgis-user mailing list
[email protected]
List info: http://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: http://lists.osgeo.org/mailman/listinfo/qgis-user

Reply via email to