Opened 15 years ago

Closed 14 years ago

#1727 closed patch (fixed)

Support Multiple Rules per Style for a Layer

Reported by: springmeyer Owned by: nobody
Priority: minor: annoyance Milestone: Version 1.5.0
Component: Symbology Version: Trunk
Keywords: Cc:
Must Fix for Release: No Platform: All
Platform Version: Awaiting user input: no

Description

It appears that currently QGIS can only apply one style (or set of 'symbols') to a layer (one2one relationship). But to support proper scale dependent rendering of layers it will be necessary to allow multiple rules (with their own min/max visibility) to contain sets of symbols and be applied to a single layer (many2one between style rules-> layer).

This is essentially what all the major web rendering engines support, and well described by the SLD spec (see request for SLD support in #1167).

The challenge here is not writing the code to process and render multiple rules, but in designing and supporting a good user interface to expose the ability to edit styles in this way. It is notable that even the new GeoExt Styler does not yet support this (but has it as a first item on the roadmap as of June 10,2008):

From http://projects.opengeo.org/styler : Symbolizer improvements

In order to support features like roads with outlines, we need the ability to define more than one symbolizer on a rule. Right now there is an assumption that each rule only has one symbolizer. This is not a constraint of SLD, just on what we've built thus far. The first release of Styler also does not support all the potential options for SLD strokes and labels. These should be accessible in the UI, to give users full control over their output.

Design proposal: Symbolizers Implementation details: http://projects.opengeo.org/styler/wiki/Symbolizers and http://projects.opengeo.org/styler/ticket/39

Nevertheless this is an essential feature, that if implemented will bring QGIS to a high level of usefulness for creating mapping styles for web applications.

Attachments (1)

rulebasedrenderer_v2.diff (54.0 KB ) - added by wonder 14 years ago.

Download all attachments as: .zip

Change History (9)

comment:1 by springmeyer, 15 years ago

Whoops, meant to link to the SLD request at: #1726

comment:2 by pcav, 15 years ago

Component: Build/InstallSymbology

comment:3 by pcav, 15 years ago

Platform: DebianAll

comment:4 by pcav, 15 years ago

Milestone: Version 1.2.0

comment:5 by jef, 14 years ago

see also #2584

by wonder, 14 years ago

Attachment: rulebasedrenderer_v2.diff added

comment:6 by wonder, 14 years ago

Type: enhancementpatch

The attached patch rulebasedrenderer_v2.diff adds a rule-based renderer to symbology-ng, together with python bindings and GUI that enables user to effectively work with the rules.

comment:7 by pcav, 14 years ago

Can this be closed following r13710?

comment:8 by wonder, 14 years ago

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.