On Jul 22, 2010, at 10:39 , Ivan Grcic wrote:

> Hi Andreas,
> 
> sure thing Ill contribute the patch right away.
> 
> A question, is it OK to use Ext.urlEncode?
> 
> url = Ext.urlEncode(baseParams, url);

I'd say go with OpenLayers.Util.urlEncode for now, unless you also want to 
change the examples that use WMSLegend to use Ext 3.2.1. Whatever works best 
for you.

Thanks,
Andreas.

> 
> 
> 
> On Thu, Jul 22, 2010 at 8:37 AM, Andreas Hocevar <[email protected]> wrote:
>> Hi Ivan,
>> 
>> I like your idea, with one minor change. What about:
>> 
>> defaults: {
>>    imageFormat: 'image/png',
>>    baseParams: {
>>        'legendOptions': 'forceLabels:on'
>>    }
>> }
>> 
>> baseParams is a common property in Ext, so I'd be in favor of this (and not 
>> vendorParameters).
>> 
>> It would be great if you could open a ticket for this, and a patch would be 
>> greatly appreciated.
>> 
>> Regards,
>> Andreas.
>> 
>> 
>> On Jul 21, 2010, at 20:38 , Ivan Grcic wrote:
>> 
>>> Hi devs (Andrea ;)
>>> 
>>> since http://trac.geoext.org/ticket/153 we can set default options by
>>> using Ext's default mechanism.
>>> So we can use something like:
>>> 
>>> defaults: {
>>>        imageFormat: 'image/png'
>>> }
>>> 
>>> But except those standard getLegendGraphic parameters, Geoserver (and
>>> probably other wms servers) have other useful vendor options to
>>> control legend graphics appearance.
>>> One of them is controlling to show or to hide legend title, which is
>>> by default turned off (if thers one rule visible)
>>> 
>>> http://geoserver.org/display/GEOSDOC/GetLegendGraphic+Improvements says:
>>> Support for another key in the LEGEND_OPTIONS parameter would allow
>>> legend labels to be forced on or off. Currently the following logic is
>>> implemented:
>>>    * If there's just one Rule for a legend, no label is supplied
>>>    * If there is more than one Rule for a legend, labels are supplied
>>> 
>>> 
>>> I allready created patch for widget\WMSLegend.js where I added
>>> LEGEND_OPTIONS  parameter, but as other WMS server maybe have other
>>> vendor parameter names, im in favour of creating one unique parameter,
>>> similar to this:
>>> 
>>> defaults: {
>>>        imageFormat: 'image/png',
>>>        vendorParameters: {
>>>            legendOptions: 'forceLabels:on'
>>>        }
>>> }
>>> 
>>> Please let me know what do you think so I can open a ticket for it.
>>> 
>>> Regards,
>>> 
>>> 
>>> --
>>> Ivan Grcic
>>> _______________________________________________
>>> Dev mailing list
>>> [email protected]
>>> http://www.geoext.org/cgi-bin/mailman/listinfo/dev
>> 
>> 
>> 
>> --
>> Andreas Hocevar
>> OpenGeo - http://opengeo.org/
>> Expert service straight from the developers.
>> 
>> 
> 
> 
> 
> -- 
> Ivan Grcic
> _______________________________________________
> Dev mailing list
> [email protected]
> http://www.geoext.org/cgi-bin/mailman/listinfo/dev

-- 
Andreas Hocevar
OpenGeo - http://opengeo.org/
Expert service straight from the developers.

_______________________________________________
Dev mailing list
[email protected]
http://www.geoext.org/cgi-bin/mailman/listinfo/dev

Reply via email to