camptocamp / cgxp

22 stars 22 forks source link

Redlining: styles in exported KML are not taken into account #849

Open asaunier opened 9 years ago

asaunier commented 9 years ago

The styles contained in the KML files exported by the redlining tool are not taken into account when loaded in Google Earth/Maps or with the AddKmlFile plugin.

May be reproduced at http://mapfish-geoportal.demo-camptocamp.com/1.5

asaunier commented 9 years ago

Actually the problem comes from OpenLayers.Format.KML that does not support styles when exporting features to KML (styles are only supported when importing KML).

The "styles" available in the elements of the exported KML files are only attributes of the exported features but cannot be used as actual styles. In short: there are useless here.

I have found an old ticket in OpenLayers about styles exporting in KML: http://trac.osgeo.org/openlayers/ticket/2409 but it is still open :)