Skip to content
This repository has been archived by the owner on Jun 3, 2020. It is now read-only.

Classified / data defined symbology #55

Open
mhugo opened this issue Mar 24, 2020 · 4 comments
Open

Classified / data defined symbology #55

mhugo opened this issue Mar 24, 2020 · 4 comments
Labels
enhancement New feature or request

Comments

@mhugo
Copy link
Contributor

mhugo commented Mar 24, 2020

For "regular" plots (not the special case of stratigraphy), data are rendered by considering one QGIS feature for the whole dataset.

It means we render a multipoint, a multilinestring ... or a polygon.

The problem with this current approach is that we cannot have a symbology that changes with each data point. No classification / graduation / data defined, etc.

I am facing a use case where I need to distinguish between different kinds of data based on their attribute.

I then plan to modify the current behavior and render one QGIS feature for each data point. But I see the following drawbacks:

  • if we want to keep the "polygon" rendering mode, we need to keep one feature = all the data points
  • having one feature per data point may add some performance issues.

So, in the end, I think I will:

  • add a symbology option "render each data point separately"
    • if enabled the user can choose a more complex symbology type ("classification", "graduated", "rule-based", etc.), but it only works for "points" and "lines" rendering, not "polygon"
  • if disabled (default) we keep the current rendering mode

This should however add some code complexities.

@vmora @troopa81 @delhomer Any comments ?

@delhomer
Copy link
Contributor

From your summary, I understand that it is not possible to represent different data series in the same QGIS plot, isn't it? (Which would be equivalent to have two, maybe three, multipoints/multilines structures within the same graph.)

I'm quite uncomfortable with the idea of adding more if-then ad hoc cases, however I have no better idea, given my knowledge of the source code...

@troopa81
Copy link
Contributor

@mhugo Is not the whole point of LayerData interface ?

Then you can have specific symbology regarding attribute values, no?

@mhugo
Copy link
Contributor Author

mhugo commented Mar 25, 2020

@troopa81 Yes, it is, but this is just an interface. In the end, everything is drawn as a big array of (x,y) values

@mhugo
Copy link
Contributor Author

mhugo commented Mar 25, 2020

@delhomer Having more than one plots on the same graph would indeed answer the initial needs and should be easier (?) to implement. It also shares view with what we had in #28 about "merged plots"

So a data-defined symbology for each plot is probably not a priority.

Thanks for your inputs !

@mhugo mhugo added the enhancement New feature or request label Mar 25, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants