azzeddine1265 / libkml

Automatically exported from code.google.com/p/libkml
Other
0 stars 0 forks source link

CreateResolvedStyle creates a style which doesn't include ItemStyle icons #30

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

I have a KML-file with inlined StyleMap in a Placemark. The inlined styles
include IconStyle's with an Icon+href.
The style returned by CreateResolvedStyle doesn't include the Icon in the
IconStyle.

What version of the product are you using? On what operating system?

libkml-0.4.0 on Windows XP

The problem lies in IconStyleIcon::Serialize(), as it serializes itself as
a Type_Icon. So copying an IconStyleIcon failes, because when restoring
from the serialized output, an Icon is created. This icon can't be added to
IconStyle in IconStyle::AddElement().

The attached patch changes the type which is used during serialization of
IconStyleIcon, and resolves the issue with CreateResolvedStyle() for me.
But I didn't test further implication.

Original issue reported on code.google.com by tom....@gmail.com on 16 Oct 2008 at 7:14

Attachments:

GoogleCodeExporter commented 9 years ago
Was fixed in r266. Thanks for the patch!

Original comment by kml.mash...@gmail.com on 16 Oct 2008 at 7:04