Re: [Qgis-user] Wrong retrieving of wms legend

2016-09-09 Thread Andrea Peri
Hi Richard,

I do some other test.

Firstly.
I try to add a dummy style (a style defined without no any kind of
rendering) and the issu on the legend is disappeared.
This is ok.

But do some other test, and see that the question was not really due
to the absence of a style in rasters, but instead to the
definition of the raster layer inside named-grouped and that are
gerarchically defined.
The gerarchical definition of a raster is available in the OGC and was
adopted from the Inspire when it also expand the use definining the
named-groups. That are different from the more commons unnamed-groups.
AFAIK the named group is actually an unavailable feature in
qgis-server, but is available in the geoserver and mapserver systems.

Well, all our wms layer coming from raster dataset are all defined
using "gerarchical named groups".
This allow for example to serve at low scales using a dataset and at
higher scale using others more detailed dataset and showing all of
them as an unique layer wms (always one unique layer wms for all these
datasets at different details).

So, I notice that if I remove the gerarchical named-group definition
of the rt_ofc.10k54 and define it as a simple wms layer coming from a
raster dataset , and also removing the "dummy style", the
issue of retrieving all the legends is disappearing.

So I guess the real problem is that qgis don't understand well the
gerarchical named-grouped layers.
But I understand that is too difficult to support a feature that is
not available in the server side of him.

So assuming that we keave the wms raster as gerarchically named-group
, the workaround to add a dummy style could be a good compromise.

But my trouble is also that perhaps the workaround of add a dummy
style could affect negativelly other wms clients like arcgis.

So before of all we explore the compatibility of this workaround with
other GIS platform.

Thx for your help to understand this really strange issue.

A.


2016-09-08 14:45 GMT+02:00 Richard Duivenvoorde :
>
> Hi Andrea,
>
> note that I also added a comment at the code which is reponsible for this:
>
> https://github.com/qgis/QGIS/commit/69bed218373b3f93671f65bc3d02c45cbf683a48#comments
>
> Patrick's response there on this (see comment):
>
> "
> IMHO, there is nothing to fix in QGIS, here. If a layer defines no
> style, it's wanted that it inherits the parent layer's style. Have a
> look at chapter 7.2.4.6.5 of the WMS implementation specification:
>
> Style declarations are inherited by child Layers. A child shall not
> redefine a Style with the same Name as one
> inherited from a parent. A child may define a new Style with a new Name
> that is not available for the parent Layer.
>
> This PR is just a workaround for MapServer that is defining a style
> named default for both the parent and the child layers. This was making
> QGIS show 2 default styles for every child layers. Style inheritance was
> already there before. Now at has just a saner behavior in regard to
> non-standard compliant servers.
>
> I'll let you forward that to the user ML. I was not subscribed to it and
> therefore cannot reply directly to the thread.
> "
>
> So in short: mapserver does not define a style for the actual layer, so
> qgis tries to get the style (AND it's legendgraphic) from the parent
> layer/node:
>
> http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc=GetCapabilities=WMS
>
> in this case mapserver's rootnode, which has a legendgraphic with all
> child symbols...
>
> so my fix would be: define a style for the child layer 'rt_ofc.10k54',
> so I do not think it has something to do with the dot in the naming?
>
> Regards,
>
> Richard Duivenvoorde
>
>
> On 03-09-16 20:42, aperi2007 wrote:
>> Hi Richard,
>>
>>
>> I tested also the QGIS 2.8 and the QGIS 2.12 no one of them has this issue.
>>
>>>Bingo: that is the one we are actually retrieving, the parent node's
>>
>>> style and legend.
>>>
>>> So: not sure if that is desired behaviour... at least not for a legend..
>>
>> Ok, now is more clear what is happened.
>>
>> The "rt_ofc" is the name of all the wms service.
>> So apply-ing the value "rt_ofc" to the layers parameter mean ask to the
>> wms server to send the response for ALL the layers available in the
>> service.
>>
>> So the problem more probably is that qgis is failing to parse the
>> layername stopping it at the dot character.
>>
>> The QGIS 2.8 and 2.12 don't fail to parse these wms layersname.
>> So it is due to some evolution put in the last qgis.
>>
>> The "rt_oc" part of the layer name is also the name of all the wms service.
>>
>> This will cause to receive the legend of ALL the layers.
>>
>> A.
>>
>>
>>
>> Il 03/09/2016 20:03, Richard Duivenvoorde ha scritto:
>>> Ok, at first the problem seemed the dot in the layernames:
>>>
>>> This is the GetMap request QGIS fires off:
>>>
>>> 

Re: [Qgis-user] Wrong retrieving of wms legend

2016-09-08 Thread Andrea Peri
Hi Richard,
I forward you explanationto the mapserver-user list.

Meanwhile my problem is
what mean give a style to a set of ortophoot as an unique catalogue ?

AFAIK this interpretation of the OGC specs mean that in a WMS service
can be available ONLY 1 image layers.

This also in qgisserver
A QGIS project service more than one layer WMS is wrong because two
distinct raster wms cannot have the same style.
:)

And the inheritance this mean (afaik).

But this seem quite non-sense.
So more probably the style raccomandation is only for wms where there
a style clear need (like when the dataset is a vector).

A.




2016-09-08 14:45 GMT+02:00 Richard Duivenvoorde :
>
> Hi Andrea,
>
> note that I also added a comment at the code which is reponsible for this:
>
> https://github.com/qgis/QGIS/commit/69bed218373b3f93671f65bc3d02c45cbf683a48#comments
>
> Patrick's response there on this (see comment):
>
> "
> IMHO, there is nothing to fix in QGIS, here. If a layer defines no
> style, it's wanted that it inherits the parent layer's style. Have a
> look at chapter 7.2.4.6.5 of the WMS implementation specification:
>
> Style declarations are inherited by child Layers. A child shall not
> redefine a Style with the same Name as one
> inherited from a parent. A child may define a new Style with a new Name
> that is not available for the parent Layer.
>
> This PR is just a workaround for MapServer that is defining a style
> named default for both the parent and the child layers. This was making
> QGIS show 2 default styles for every child layers. Style inheritance was
> already there before. Now at has just a saner behavior in regard to
> non-standard compliant servers.
>
> I'll let you forward that to the user ML. I was not subscribed to it and
> therefore cannot reply directly to the thread.
> "
>
> So in short: mapserver does not define a style for the actual layer, so
> qgis tries to get the style (AND it's legendgraphic) from the parent
> layer/node:
>
> http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc=GetCapabilities=WMS
>
> in this case mapserver's rootnode, which has a legendgraphic with all
> child symbols...
>
> so my fix would be: define a style for the child layer 'rt_ofc.10k54',
> so I do not think it has something to do with the dot in the naming?
>
> Regards,
>
> Richard Duivenvoorde
>
>
> On 03-09-16 20:42, aperi2007 wrote:
>> Hi Richard,
>>
>>
>> I tested also the QGIS 2.8 and the QGIS 2.12 no one of them has this issue.
>>
>>>Bingo: that is the one we are actually retrieving, the parent node's
>>
>>> style and legend.
>>>
>>> So: not sure if that is desired behaviour... at least not for a legend..
>>
>> Ok, now is more clear what is happened.
>>
>> The "rt_ofc" is the name of all the wms service.
>> So apply-ing the value "rt_ofc" to the layers parameter mean ask to the
>> wms server to send the response for ALL the layers available in the
>> service.
>>
>> So the problem more probably is that qgis is failing to parse the
>> layername stopping it at the dot character.
>>
>> The QGIS 2.8 and 2.12 don't fail to parse these wms layersname.
>> So it is due to some evolution put in the last qgis.
>>
>> The "rt_oc" part of the layer name is also the name of all the wms service.
>>
>> This will cause to receive the legend of ALL the layers.
>>
>> A.
>>
>>
>>
>> Il 03/09/2016 20:03, Richard Duivenvoorde ha scritto:
>>> Ok, at first the problem seemed the dot in the layernames:
>>>
>>> This is the GetMap request QGIS fires off:
>>>
>>> http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita&=WMS=1.3.0=GetMap=1063072.194008157123,5185232.179659257643,1388677.251798849553,5543677.86921980232=EPSG:3857=518=569=rt_ofc.10k54==image/png=96_RESOLUTION=96_OPTIONS=dpi:96=TRUE
>>>
>>>
>>> as you see: LAYERS=rt_ofc.10k54
>>>
>>> This is the GetLegendGraphic url created by QGIS:
>>>
>>> http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita=1.3.0=WMS=GetLegendGraphic_version=1.1.0=rt_ofc=image/png=default&=true
>>>
>>>
>>> NOTE: layer=rt_ofc
>>>
>>> (all seen in the debug info on QGIS on Linux (Debug)):
>>>
>>> Which SHOULD be:
>>>
>>> http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita=1.3.0=WMS=GetLegendGraphic_version=1.1.0=rt_ofc.10k54=image/png=default&=true
>>>
>>>
>>> NOTE, I edited: layer=rt_ofc.10k54
>>>
>>> Mmm, not much of an legend, but as least NOT an image of all (vector)
>>> layer legends...
>>>
>>> So crux is: IF a layer parameter has a dot in it's name, only the first
>>> part is used as parameter
>>>
>>> BUT: what is the GetLegendGraphic url advertised by the server:
>>>
>>> http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc=GetCapabilities=WMS
>>>
>>>
>>> Mmm, actually no style/LegendURL advertised :-(
>>>
>>> https://github.com/qgis/QGIS/blob/master/src/providers/wms/qgswmsprovider.cpp#L249
>>>
>>>
>>> points to 

Re: [Qgis-user] Wrong retrieving of wms legend

2016-09-08 Thread Richard Duivenvoorde

Hi Andrea,

note that I also added a comment at the code which is reponsible for this:

https://github.com/qgis/QGIS/commit/69bed218373b3f93671f65bc3d02c45cbf683a48#comments

Patrick's response there on this (see comment):

"
IMHO, there is nothing to fix in QGIS, here. If a layer defines no
style, it's wanted that it inherits the parent layer's style. Have a
look at chapter 7.2.4.6.5 of the WMS implementation specification:

Style declarations are inherited by child Layers. A child shall not
redefine a Style with the same Name as one
inherited from a parent. A child may define a new Style with a new Name
that is not available for the parent Layer.

This PR is just a workaround for MapServer that is defining a style
named default for both the parent and the child layers. This was making
QGIS show 2 default styles for every child layers. Style inheritance was
already there before. Now at has just a saner behavior in regard to
non-standard compliant servers.

I'll let you forward that to the user ML. I was not subscribed to it and
therefore cannot reply directly to the thread.
"

So in short: mapserver does not define a style for the actual layer, so
qgis tries to get the style (AND it's legendgraphic) from the parent
layer/node:

http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc=GetCapabilities=WMS

in this case mapserver's rootnode, which has a legendgraphic with all
child symbols...

so my fix would be: define a style for the child layer 'rt_ofc.10k54',
so I do not think it has something to do with the dot in the naming?

Regards,

Richard Duivenvoorde


On 03-09-16 20:42, aperi2007 wrote:
> Hi Richard,
> 
> 
> I tested also the QGIS 2.8 and the QGIS 2.12 no one of them has this issue.
> 
>>Bingo: that is the one we are actually retrieving, the parent node's
> 
>> style and legend.
>>
>> So: not sure if that is desired behaviour... at least not for a legend..
> 
> Ok, now is more clear what is happened.
> 
> The "rt_ofc" is the name of all the wms service.
> So apply-ing the value "rt_ofc" to the layers parameter mean ask to the
> wms server to send the response for ALL the layers available in the
> service.
> 
> So the problem more probably is that qgis is failing to parse the
> layername stopping it at the dot character.
> 
> The QGIS 2.8 and 2.12 don't fail to parse these wms layersname.
> So it is due to some evolution put in the last qgis.
> 
> The "rt_oc" part of the layer name is also the name of all the wms service.
> 
> This will cause to receive the legend of ALL the layers.
> 
> A.
> 
> 
> 
> Il 03/09/2016 20:03, Richard Duivenvoorde ha scritto:
>> Ok, at first the problem seemed the dot in the layernames:
>>
>> This is the GetMap request QGIS fires off:
>>
>> http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita&=WMS=1.3.0=GetMap=1063072.194008157123,5185232.179659257643,1388677.251798849553,5543677.86921980232=EPSG:3857=518=569=rt_ofc.10k54==image/png=96_RESOLUTION=96_OPTIONS=dpi:96=TRUE
>>
>>
>> as you see: LAYERS=rt_ofc.10k54
>>
>> This is the GetLegendGraphic url created by QGIS:
>>
>> http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita=1.3.0=WMS=GetLegendGraphic_version=1.1.0=rt_ofc=image/png=default&=true
>>
>>
>> NOTE: layer=rt_ofc
>>
>> (all seen in the debug info on QGIS on Linux (Debug)):
>>
>> Which SHOULD be:
>>
>> http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita=1.3.0=WMS=GetLegendGraphic_version=1.1.0=rt_ofc.10k54=image/png=default&=true
>>
>>
>> NOTE, I edited: layer=rt_ofc.10k54
>>
>> Mmm, not much of an legend, but as least NOT an image of all (vector)
>> layer legends...
>>
>> So crux is: IF a layer parameter has a dot in it's name, only the first
>> part is used as parameter
>>
>> BUT: what is the GetLegendGraphic url advertised by the server:
>>
>> http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc=GetCapabilities=WMS
>>
>>
>> Mmm, actually no style/LegendURL advertised :-(
>>
>> https://github.com/qgis/QGIS/blob/master/src/providers/wms/qgswmsprovider.cpp#L249
>>
>>
>> points to pickLegend:
>>
>> https://github.com/qgis/QGIS/blob/master/src/providers/wms/qgswmsprovider.cpp#L227
>>
>>
>> which looks ok:
>>
>> BUT apparently it picks the style of the PARENT-NODE of the layer: THAT
>> one has
>>
>> > xlink:href="http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita=1.3.0=WMS=GetLegendGraphic_version=1.1.0=rt_ofc=image/png=default"/>
>>
>>
>> Bingo: that is the one we are actually retrieving, the parent node's
>> style and legend.
>>
>> So: not sure if that is desired behaviour... at least not for a legend..
>>
>> I think what QGIS does is 'inheriting' default styles from parent nodes.
>> In this case that is plain wrong.
>>
>> Copy/paste this in an QGIS issue?
>>
>> Maybe for the getLegend url, the style should not be inherited?
>> Anybody other ideas?
>>
>> 

Re: [Qgis-user] Wrong retrieving of wms legend

2016-09-03 Thread aperi2007

Hi Richard,


I tested also the QGIS 2.8 and the QGIS 2.12 no one of them has this issue.

>Bingo: that is the one we are actually retrieving, the parent node's


style and legend.

So: not sure if that is desired behaviour... at least not for a legend..


Ok, now is more clear what is happened.

The "rt_ofc" is the name of all the wms service.
So apply-ing the value "rt_ofc" to the layers parameter mean ask to the 
wms server to send the response for ALL the layers available in the service.


So the problem more probably is that qgis is failing to parse the 
layername stopping it at the dot character.


The QGIS 2.8 and 2.12 don't fail to parse these wms layersname.
So it is due to some evolution put in the last qgis.

The "rt_oc" part of the layer name is also the name of all the wms service.

This will cause to receive the legend of ALL the layers.

A.



Il 03/09/2016 20:03, Richard Duivenvoorde ha scritto:

Ok, at first the problem seemed the dot in the layernames:

This is the GetMap request QGIS fires off:

http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita&=WMS=1.3.0=GetMap=1063072.194008157123,5185232.179659257643,1388677.251798849553,5543677.86921980232=EPSG:3857=518=569=rt_ofc.10k54==image/png=96_RESOLUTION=96_OPTIONS=dpi:96=TRUE

as you see: LAYERS=rt_ofc.10k54

This is the GetLegendGraphic url created by QGIS:

http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita=1.3.0=WMS=GetLegendGraphic_version=1.1.0=rt_ofc=image/png=default&=true

NOTE: layer=rt_ofc

(all seen in the debug info on QGIS on Linux (Debug)):

Which SHOULD be:

http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita=1.3.0=WMS=GetLegendGraphic_version=1.1.0=rt_ofc.10k54=image/png=default&=true

NOTE, I edited: layer=rt_ofc.10k54

Mmm, not much of an legend, but as least NOT an image of all (vector)
layer legends...

So crux is: IF a layer parameter has a dot in it's name, only the first
part is used as parameter

BUT: what is the GetLegendGraphic url advertised by the server:

http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc=GetCapabilities=WMS

Mmm, actually no style/LegendURL advertised :-(

https://github.com/qgis/QGIS/blob/master/src/providers/wms/qgswmsprovider.cpp#L249

points to pickLegend:

https://github.com/qgis/QGIS/blob/master/src/providers/wms/qgswmsprovider.cpp#L227

which looks ok:

BUT apparently it picks the style of the PARENT-NODE of the layer: THAT
one has

http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita=1.3.0=WMS=GetLegendGraphic_version=1.1.0=rt_ofc=image/png=default"/>

Bingo: that is the one we are actually retrieving, the parent node's
style and legend.

So: not sure if that is desired behaviour... at least not for a legend..

I think what QGIS does is 'inheriting' default styles from parent nodes.
In this case that is plain wrong.

Copy/paste this in an QGIS issue?

Maybe for the getLegend url, the style should not be inherited?
Anybody other ideas?

Regards,

Richard Duivenvoorde


On 03-09-16 16:08, Andrea Peri wrote:

Hi Richard.
Effectivelly I tested your wms and using it the legend is correctly
retrieved only for the layer choose.
I use qgis 2.16.1.
After I re-test my original url:
(this)
http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc

And again I see the qgis retrieve ALL the legend of all the layers.
I tested other wms of our set of wms service and seem only this has
that problem.

So I do some more proof tested.

And found where is the ISSUE.
QGIS wrong to get the legend when the layer wms requested HAS NOT A LEGEND.
Infact the issu happened when I ask any layer of our wms that is a
RASTER LAYER with no legend defined.
Instead not happened when the layer wms is of a vector dataset (where
the legend happened).

SO If you whould test and see the issue you should use our wms service:
http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc

and choose the layer
rt_ofc.1954

that return the orthophoto imagery of the year 1954.
With this layer the qgis will retrieve ALL the legends of the wms service.

Instead if you choose the layer
rt_ofc.1954.qu
that is a vector dataset (quadre of union)
qgis correctly retrieve only its own legend.

Please can you confirm this ?

Thx

A.




2016-09-03 9:51 GMT+02:00 Richard Duivenvoorde :

On 31-08-16 21:10, Andrea Peri wrote:

Hi,
I notive that in the qgis 2.14.5 and in the qgis 2.16.1
when adding a layer wms choosing from a list of layers available in
the wms service connected,
qgis retrieve as legend of the layer ALL the legends of all the wms
layer available in the wms service.
Using the 2.8 QGIS version, the legend is retrieve correctly (only the
layer choosed).

Someone can confirm this as an issue ?

Hi Andrea,

nope, I have 2.16.1 here, and for example this wms:


Re: [Qgis-user] Wrong retrieving of wms legend

2016-09-03 Thread Richard Duivenvoorde

Ok, at first the problem seemed the dot in the layernames:

This is the GetMap request QGIS fires off:

http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita&=WMS=1.3.0=GetMap=1063072.194008157123,5185232.179659257643,1388677.251798849553,5543677.86921980232=EPSG:3857=518=569=rt_ofc.10k54==image/png=96_RESOLUTION=96_OPTIONS=dpi:96=TRUE

as you see: LAYERS=rt_ofc.10k54

This is the GetLegendGraphic url created by QGIS:

http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita=1.3.0=WMS=GetLegendGraphic_version=1.1.0=rt_ofc=image/png=default&=true

NOTE: layer=rt_ofc

(all seen in the debug info on QGIS on Linux (Debug)):

Which SHOULD be:

http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita=1.3.0=WMS=GetLegendGraphic_version=1.1.0=rt_ofc.10k54=image/png=default&=true

NOTE, I edited: layer=rt_ofc.10k54

Mmm, not much of an legend, but as least NOT an image of all (vector)
layer legends...

So crux is: IF a layer parameter has a dot in it's name, only the first
part is used as parameter

BUT: what is the GetLegendGraphic url advertised by the server:

http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc=GetCapabilities=WMS

Mmm, actually no style/LegendURL advertised :-(

https://github.com/qgis/QGIS/blob/master/src/providers/wms/qgswmsprovider.cpp#L249

points to pickLegend:

https://github.com/qgis/QGIS/blob/master/src/providers/wms/qgswmsprovider.cpp#L227

which looks ok:

BUT apparently it picks the style of the PARENT-NODE of the layer: THAT
one has

http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc_resolution=91=ita=1.3.0=WMS=GetLegendGraphic_version=1.1.0=rt_ofc=image/png=default"/>

Bingo: that is the one we are actually retrieving, the parent node's
style and legend.

So: not sure if that is desired behaviour... at least not for a legend..

I think what QGIS does is 'inheriting' default styles from parent nodes.
In this case that is plain wrong.

Copy/paste this in an QGIS issue?

Maybe for the getLegend url, the style should not be inherited?
Anybody other ideas?

Regards,

Richard Duivenvoorde


On 03-09-16 16:08, Andrea Peri wrote:
> Hi Richard.
> Effectivelly I tested your wms and using it the legend is correctly
> retrieved only for the layer choose.
> I use qgis 2.16.1.
> After I re-test my original url:
> (this)
> http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc
> 
> And again I see the qgis retrieve ALL the legend of all the layers.
> I tested other wms of our set of wms service and seem only this has
> that problem.
> 
> So I do some more proof tested.
> 
> And found where is the ISSUE.
> QGIS wrong to get the legend when the layer wms requested HAS NOT A LEGEND.
> Infact the issu happened when I ask any layer of our wms that is a
> RASTER LAYER with no legend defined.
> Instead not happened when the layer wms is of a vector dataset (where
> the legend happened).
> 
> SO If you whould test and see the issue you should use our wms service:
> http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc
> 
> and choose the layer
> rt_ofc.1954
> 
> that return the orthophoto imagery of the year 1954.
> With this layer the qgis will retrieve ALL the legends of the wms service.
> 
> Instead if you choose the layer
> rt_ofc.1954.qu
> that is a vector dataset (quadre of union)
> qgis correctly retrieve only its own legend.
> 
> Please can you confirm this ?
> 
> Thx
> 
> A.
> 
> 
> 
> 
> 2016-09-03 9:51 GMT+02:00 Richard Duivenvoorde :
>> On 31-08-16 21:10, Andrea Peri wrote:
>>> Hi,
>>> I notive that in the qgis 2.14.5 and in the qgis 2.16.1
>>> when adding a layer wms choosing from a list of layers available in
>>> the wms service connected,
>>> qgis retrieve as legend of the layer ALL the legends of all the wms
>>> layer available in the wms service.
>>> Using the 2.8 QGIS version, the legend is retrieve correctly (only the
>>> layer choosed).
>>>
>>> Someone can confirm this as an issue ?
>>
>> Hi Andrea,
>>
>> nope, I have 2.16.1 here, and for example this wms:
>>
>> https://geodata.nationaalgeoregister.nl/bestuurlijkegrenzen/ows?SERVICE=WMS;
>>
>> I can choose either provincies or landsgrenzen (provinces or country
>> borders), from that same server and both have their own legend.
>>
>> Do you have a WMS url for which this happens for you?
>>
>> What if you look at the capabilities of that service and do the
>> getLegendGrapicRequest by hand. Is it also wrong?
>>
>> Else: create a good issue, with url's screendumps etc etc
>>
>> Regards,
>>
>> Richard Duivenvoorde
>>
> 
> 
> 

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: http://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: http://lists.osgeo.org/mailman/listinfo/qgis-user

Re: [Qgis-user] Wrong retrieving of wms legend

2016-09-03 Thread Andrea Peri
Hi Richard.
Effectivelly I tested your wms and using it the legend is correctly
retrieved only for the layer choose.
I use qgis 2.16.1.
After I re-test my original url:
(this)
http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc

And again I see the qgis retrieve ALL the legend of all the layers.
I tested other wms of our set of wms service and seem only this has
that problem.

So I do some more proof tested.

And found where is the ISSUE.
QGIS wrong to get the legend when the layer wms requested HAS NOT A LEGEND.
Infact the issu happened when I ask any layer of our wms that is a
RASTER LAYER with no legend defined.
Instead not happened when the layer wms is of a vector dataset (where
the legend happened).

SO If you whould test and see the issue you should use our wms service:
http://www502.regione.toscana.it/wmsraster/com.rt.wms.RTmap/wms?map=wmsofc

and choose the layer
rt_ofc.1954

that return the orthophoto imagery of the year 1954.
With this layer the qgis will retrieve ALL the legends of the wms service.

Instead if you choose the layer
rt_ofc.1954.qu
that is a vector dataset (quadre of union)
qgis correctly retrieve only its own legend.

Please can you confirm this ?

Thx

A.




2016-09-03 9:51 GMT+02:00 Richard Duivenvoorde :
> On 31-08-16 21:10, Andrea Peri wrote:
>> Hi,
>> I notive that in the qgis 2.14.5 and in the qgis 2.16.1
>> when adding a layer wms choosing from a list of layers available in
>> the wms service connected,
>> qgis retrieve as legend of the layer ALL the legends of all the wms
>> layer available in the wms service.
>> Using the 2.8 QGIS version, the legend is retrieve correctly (only the
>> layer choosed).
>>
>> Someone can confirm this as an issue ?
>
> Hi Andrea,
>
> nope, I have 2.16.1 here, and for example this wms:
>
> https://geodata.nationaalgeoregister.nl/bestuurlijkegrenzen/ows?SERVICE=WMS;
>
> I can choose either provincies or landsgrenzen (provinces or country
> borders), from that same server and both have their own legend.
>
> Do you have a WMS url for which this happens for you?
>
> What if you look at the capabilities of that service and do the
> getLegendGrapicRequest by hand. Is it also wrong?
>
> Else: create a good issue, with url's screendumps etc etc
>
> Regards,
>
> Richard Duivenvoorde
>



-- 
-
Andrea Peri
. . . . . . . . .
qwerty àèìòù
-
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: http://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: http://lists.osgeo.org/mailman/listinfo/qgis-user

Re: [Qgis-user] Wrong retrieving of wms legend

2016-09-03 Thread Richard Duivenvoorde
On 31-08-16 21:10, Andrea Peri wrote:
> Hi,
> I notive that in the qgis 2.14.5 and in the qgis 2.16.1
> when adding a layer wms choosing from a list of layers available in
> the wms service connected,
> qgis retrieve as legend of the layer ALL the legends of all the wms
> layer available in the wms service.
> Using the 2.8 QGIS version, the legend is retrieve correctly (only the
> layer choosed).
> 
> Someone can confirm this as an issue ?

Hi Andrea,

nope, I have 2.16.1 here, and for example this wms:

https://geodata.nationaalgeoregister.nl/bestuurlijkegrenzen/ows?SERVICE=WMS;

I can choose either provincies or landsgrenzen (provinces or country
borders), from that same server and both have their own legend.

Do you have a WMS url for which this happens for you?

What if you look at the capabilities of that service and do the
getLegendGrapicRequest by hand. Is it also wrong?

Else: create a good issue, with url's screendumps etc etc

Regards,

Richard Duivenvoorde

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: http://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: http://lists.osgeo.org/mailman/listinfo/qgis-user

[Qgis-user] Wrong retrieving of wms legend

2016-08-31 Thread Andrea Peri
Hi,
I notive that in the qgis 2.14.5 and in the qgis 2.16.1
when adding a layer wms choosing from a list of layers available in
the wms service connected,
qgis retrieve as legend of the layer ALL the legends of all the wms
layer available in the wms service.
Using the 2.8 QGIS version, the legend is retrieve correctly (only the
layer choosed).

Someone can confirm this as an issue ?

thx.

-- 
-
Andrea Peri
. . . . . . . . .
qwerty àèìòù
-
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: http://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: http://lists.osgeo.org/mailman/listinfo/qgis-user