originalName returns name
name returns name with upper case for the first letter if an option has
been activated.
Regards
Le 09/06/2016 23:34, Germán Carrillo a écrit :
Does anybody have any thought on this?
2016-06-01 10:31 GMT-05:00 Germán Carrillo <[email protected]
<mailto:[email protected]>>:
Hi All,
what is the purpose of originalName() method in QgsMapLayer class?
Documentation states:
Get the original name of the layer.
Returns
the original layer name
Which perhaps isn't clear enough.
Plugin developers reading the API would generally expect
originalName to preserve the name the layer was given when it was
first loaded into QGIS. And it might be so, except for this line
(http://qgis.org/api/2.14/qgsmaplayer_8cpp_source.html#l00117)
that modifies the originalName private variable.
Am I getting it wrong? Is id() supposed to fulfill such requirement?
Regards,
Germán
2015-12-08 6:33 GMT-05:00 René-Luc Dhont <[email protected]
<mailto:[email protected]>>:
Le 22/09/2015 13:36, Paolo Cavallini a écrit :
Il 22/09/2015 13:24, Tom Chadwin ha scritto:
Many apologies - you are right. I change "Layer name",
and couldn't
understand what Display as was meant to be: a
non-editable text field which
mirrors Layer name? Why?
agreed, an old issue, I also do not understant its use.
all the best.
It's not an issue :-)
In QgsMapLayer there are originalName and name.
The method setLayerName sets originalName and name.
The attribute name is the capitalize originalName if the
settings "/qgis/capitaliseLayerName" is set to True.
In the Layer properties the originalName and Name are
displayed and the originalName is the editable attribute.
René-Luc
_______________________________________________
Qgis-developer mailing list
[email protected]
<mailto:[email protected]>
List info: http://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe:
http://lists.osgeo.org/mailman/listinfo/qgis-developer
--
-----------
|\__
(:>__)(
|/
Soluciones Geoinformáticas Libres
http://geotux.tuxfamily.org/
http://twitter.com/GeoTux2
http://about.me/germancarrillo
<http://gis.stackexchange.com/users/4972/germ%c3%a1n-carrillo>
--
-----------
|\__
(:>__)(
|/
Soluciones Geoinformáticas Libres
http://geotux.tuxfamily.org/
http://twitter.com/GeoTux2
http://about.me/germancarrillo
<http://gis.stackexchange.com/users/4972/germ%c3%a1n-carrillo>
_______________________________________________
Qgis-developer mailing list
[email protected]
List info: http://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: http://lists.osgeo.org/mailman/listinfo/qgis-developer