Bug report #6152
SLD export saves a schema invalid file
Status: | Closed | ||
---|---|---|---|
Priority: | Normal | ||
Assignee: | |||
Category: | Symbology | ||
Affected QGIS version: | master | Regression?: | No |
Operating System: | Easy fix?: | No | |
Pull Request or Patch supplied: | No | Resolution: | |
Crashes QGIS or corrupts data: | No | Copied to github as #: | 15476 |
Description
The rules generated by QGIS contain schema invalid output, here is a sample:
<se:Rule> <se:Name>159.0550 - 137771.0580</se:Name> <se:Description>159.0550 - 137771.0580</se:Description> ... </se:Rule>
The Description element is defined, in SE 1.1, as:
<xsd:complexType name="DescriptionType"> <xsd:sequence> <xsd:element name="Title" type="xsd:string" minOccurs="0"/> <xsd:element name="Abstract" type="xsd:string" minOccurs="0"/> </xsd:sequence> </xsd:complexType>
So the generated markup should actually look like the following:
<se:Rule> <se:Name>159.0550 - 137771.0580</se:Name> <se:Description> <se:Title>159.0550 - 137771.0580</se:Title> </se:Description> ... </se:Rule>
Associated revisions
sld support: use Title tag (instead of Abstract) exporting styles to SLD (fix #6152)
History
#1
Updated by Giovanni Manghi about 12 years ago
- Status changed from Open to Feedback
- Assignee set to Giuseppe Sucameli
please give a try to qgis master, there have been fixes ablut SLD support after the relase of qgis 1.8
#2
Updated by Andrea Aime about 12 years ago
Btw, this is on Ubuntu 10.04, QGIS 1.8.0 - Lisboa, coming from the UbuntuGIS apt
#3
Updated by Giovanni Manghi about 12 years ago
Andrea Aime wrote:
Btw, this is on Ubuntu 10.04, QGIS 1.8.0 - Lisboa, coming from the UbuntuGIS apt
there is a repo for Ubuntu that allows to install qgis-master, see the qgis download page.
#4
Updated by Andrea Aime about 12 years ago
I've just found the same behavior on the Windows release of QGIS 1.8.0 Lisboa, so it's not OS or package specific
#5
Updated by Giovanni Manghi about 12 years ago
Andrea Aime wrote:
I've just found the same behavior on the Windows release of QGIS 1.8.0 Lisboa, so it's not OS or package specific
can you try qgis-master under Windows? it is easy to install with osgeo4w.
#6
Updated by Andrea Aime about 12 years ago
Ok, with QGis master things look better, the document is valid, but it will still won't work 100% good with SLD based systems:
<se:Rule> <se:Name>159.0550 - 137771.0580</se:Name> <se:Description> <se:Abstract>159.0550 - 137771.0580</se:Abstract> </se:Description> <ogc:Filter> <ogc:And> <ogc:PropertyIsGreaterThan> <ogc:PropertyName>LAND_KM</ogc:PropertyName> <ogc:Literal>159.055</ogc:Literal> </ogc:PropertyIsGreaterThan> <ogc:PropertyIsLessThanOrEqualTo> <ogc:PropertyName>LAND_KM</ogc:PropertyName> <ogc:Literal>137771</ogc:Literal> </ogc:PropertyIsLessThanOrEqualTo> </ogc:And> </ogc:Filter> <se:PolygonSymbolizer> <se:Fill> <se:SvgParameter name="fill">#f7fbff</se:SvgParameter> </se:Fill> <se:Stroke> <se:SvgParameter name="stroke">#000000</se:SvgParameter> <se:SvgParameter name="stroke-width">0.26</se:SvgParameter> </se:Stroke> </se:PolygonSymbolizer> </se:Rule>
The Description tag is now valid, but in order to support proper legend generations in GeoServer it should use Title, not Abstract (which is meant for a verbose description of the style, as opposed to the title, which is meant to be concise and usable in legends)
#7
Updated by Giuseppe Sucameli about 12 years ago
- Status changed from Feedback to In Progress
Andrea Aime wrote:
in order to support proper legend generations in GeoServer it should use Title, not Abstract
I agree, I'm changing it.
#8
Updated by Giuseppe Sucameli about 12 years ago
- Status changed from In Progress to Closed
Fixed in changeset 136a65c7b455ae0d0e1fbcc7c351ebe57ddd45d0.