[Users] hiding the printExtent... one more question

Marc Jansen jansen at terrestris.de
Wed Jul 21 15:59:20 CEST 2010


Hi Andreas,

find comments inline.


On 21.07.2010 15:40, Andreas Hocevar wrote:
> Hi Marc,
>
> thanks for helping us with the API review (even if you don't know you are doing so :-) ).
>    

You owe me a beer for that one in Barcelona ;-)

> You could try to create the MapPanel without the PrintExtent plugin, and call init() on the PrintExtent plugin when you first need it. This should work, although init() is not an API method, nor is it the standard way to add a plugin.
>
> A better way would indeed be to make the initial state configurable, e.g. by adding a hidden property. If set to true, the plugin would initialize without calling setUp (show). What do you think?
>    

We have been thinking of something similar. I changed our working 
application and extracted a patch that replaces the one attached to #307

> Some background on the history of the PrintExtent plugin:
>
> Initially, the PrintExtent was a component, not a plugin (see http://trac.geoext.org/attachment/ticket/204/geoext-204.3.patch). Eric led the efforts to make it a plugin. See http://atlas.openplans.org/~georj/cgi-bin/log.cgi/geoext/2010/02/08/#T11:13:01Z for the whole conversation between him and myself.
>
> Especially this part is interesting:
>   13:12:04Z elemoine: we're also telling the user PrintExtent is a Component, so he'd assume show/hide could be called
>   13:12:15Z ahocevar: right, but that we could fix. technically.
>   13:12:32Z ahocevar: by overriding hide() and show()
>
> So with #307, we would add hide and show, something that people would expect from a component :-).
>    

This is a little bit confusing, indeed.

> Regards,
> Andreas.
>
> On Jul 21, 2010, at 13:58 , Marc Jansen wrote:
>
>    
>> Hi list,
>>
>> For the record: https://trac.geoext.org/ticket/307 is the ticket with
>> the renamed methods.
>>
>> One additional question came to my mind:
>>
>> If a PrintExtent plugin is added to a mappanel, its setUp()-method is
>> automatically called from the init()-method, which in my case lead to
>> the behaviour, that the PrintExtent was visible on the map, but the
>> accordion element with the print-form was hidden.
>>
>> Should this (the autimatic rendering) be configurable in any way? Or am
>> I doing things the wrong way?
>>
>> Thanks again for your help,
>>
>> Regards,
>> Marc
>>
>>
>>
>>
>> On 21.07.2010 11:32, Antoine Abt wrote:
>>      
>>> Hi,
>>>
>>> On 21 July 2010 11:21, Andreas Hocevar<ahocevar at opengeo.org>   wrote:
>>>
>>>        
>>>> Hi,
>>>>
>>>> I'd say tearDown() is the right thing to do. I would propose to change two method names as part of our API review before the 1.0 release:
>>>>
>>>>          
>>> Yep, you get the example in the simple print widgets, to deal with
>>> accordion (and others):
>>>
>>> http://trac.geoext.org/browser/extensions/geoext.ux/ux/SimplePrint/lib/GeoExt.ux/SimplePrint.js?rev=1877#L133
>>>
>>> Regards,
>>>
>>>
>>>        
>> _______________________________________________
>> Users mailing list
>> Users at geoext.org
>> http://www.geoext.org/cgi-bin/mailman/listinfo/users
>>      
>
>
>    


-- 

   .................................................................
    Karten im (Inter|Intra)net?

    OpenLayers - Webentwicklung mit dynamischen Karten und Geodaten
    von M. Jansen und T. Adams, OpenSourcePress, München.

    ISBN: 978-3-937514-92-5
    URL:  http://openlayers-buch.de
   .................................................................


   Dipl.-Geogr. Marc Jansen
   - Anwendungsentwickler -

   terrestris GmbH&  Co. KG
   Irmintrudisstraße 17
   53111 Bonn

   Tel:    ++49 (0)228 / 96 28 99 -53
   Fax:    ++49 (0)228 / 96 28 99 -57

   Email:  jansen at terrestris.de
   Web:    http://www.terrestris.de

   Amtsgericht Bonn, HRA 6835
   Komplementärin:  terrestris Verwaltungsgesellschaft mbH
   vertreten durch: Hinrich Paulsen, Till Adams




More information about the Users mailing list