Hi,
I'm currently unable to log onto the openlayers trac, so here's a
very small patch correcting the following bug : if a vector label has
"0" as value to display, it won't display it [1]. See an example with
current trunk with the fix [2].
[1] http://openlayers.org/dev/examples/vector-features-with-text.html
[2]
http://dev4.mapgears.com/tests/openlayers-testslabels/examples/vector-features-with-text.html
--
Alexandre Dubé
Mapgears
www.mapgears.com
Index: lib/OpenLayers/Renderer.js
===================================================================
--- lib/OpenLayers/Renderer.js (revision 10720)
+++ lib/OpenLayers/Renderer.js (working copy)
@@ -178,7 +178,7 @@
style = {display: "none"};
}
var rendered = this.drawGeometry(feature.geometry, style, feature.id);
- if(style.display != "none" && style.label && rendered !== false) {
+ if(style.display != "none" && style.label !== false && rendered !== false) {
var location = feature.geometry.getCentroid();
if(style.labelXOffset || style.labelYOffset) {
xOffset = isNaN(style.labelXOffset) ? 0 : style.labelXOffset;
_______________________________________________
Dev mailing list
d...@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/openlayers-dev