Bug report #21309
Max. size of symbols with map unit sizes not usable in the legend
Status: | Closed | ||
---|---|---|---|
Priority: | Normal | ||
Assignee: | David Signer | ||
Category: | Map Legend | ||
Affected QGIS version: | 3.5(master) | Regression?: | No |
Operating System: | Ubuntu and Fedora | Easy fix?: | No |
Pull Request or Patch supplied: | No | Resolution: | |
Crashes QGIS or corrupts data: | No | Copied to github as #: | 29127 |
Description
When there is a map unit size configured for the symbols, and a max value, the legend usually takes the size displayed on the map.
Means with this config:
It will be like this:
Where it's not that nice to have the same maximum size in the legend.
But since it takes always the max size in the `GetLegendGraphic` request with QGIS Server, this is much worse here:
`http://qgis.demo/cgi-bin/qgis_mapserv.fcgi?MAP=/home/david/qgis_projects/server_test/co18_results_rock_grid_tes2t.qgs&SERVICE=WMS&REQUEST=GetLegendGraphic&LAYER=hmap_mean_munit&FORMAT=image/png`
Associated revisions
use scale and mapUnitsPerPixel from map parameters bbox and size
in case bbox and size is given in the GetLegendGraphics request, the size of symbols defined by map units is calculated regarding the scale of that.
fixes #21309
use scale and mapUnitsPerPixel from map parameters bbox and size. in case bbox and size is given in the GetLegendGraphics request, the size of symbols defined by map units is calculated regarding the scale of that.
calculate mMmPerMapUnit with mapUnitsPerPixel to avoid to have redundant info
fixes #21309
(cherry-picked from a04f91b840f8bce5cbcbd9d9211fa3aa6fe236c5 7de50a016d896281be2192cf20986f052c411722 3e861635143cb2a7055602bdf369dbcb66fdac25)
use scale and mapUnitsPerPixel from map parameters bbox and size. in case bbox and size is given in the GetLegendGraphics request, the size of symbols defined by map units is calculated regarding the scale of t$
calculate mMmPerMapUnit with mapUnitsPerPixel to avoid to have redundant info
fixes #21309
(cherry-picked from a04f91b840f8bce5cbcbd9d9211fa3aa6fe236c5 7de50a016d896281be2192cf20986f052c411722 3e861635143cb2a7055602bdf369dbcb66fdac25) and resolved conflicts
History
#1 Updated by Giovanni Manghi over 5 years ago
- Assignee deleted (
David Signer) - Status changed from Open to Feedback
- Category changed from Symbology to Map Legend
isn't this the same as #18030 ?
#2 Updated by David Signer over 5 years ago
- Assignee set to David Signer
I'm confused that the circles in the #18030 are bigger in the layer panel than in the map. But I guess, that it's on purpose, that the symbols in the layer panel "grow" with the symbols on the map. Same in the legend (used on print layout or server request) but there it's more important to have a maximum size. (of course it could make sense to use it in the layer panel as well, but I'm not sure...)
#3 Updated by David Signer over 5 years ago
- % Done changed from 0 to 100
- Status changed from Feedback to Closed
Applied in changeset qgis|a04f91b840f8bce5cbcbd9d9211fa3aa6fe236c5.