Em Quarta 26 Abril 2006 07:43, Kevin Dangoor escreveu:
> On 4/26/06, Michele Cella <[EMAIL PROTECTED]> wrote:
> > IMHO member_widgets should just act as a special classifier for a
> > params.
>
> To me, the entire reason params exists is to denote values that can be
> passed at __init__ and updated at display time. If this was not the
> point of params, we'd just be putting the params as arguments to
> __init__.

But we can override those widgets at __init__.  I believe we can't do that at 
display time, but I haven't tried it.

> member_widgets are listed as they are because they need some special
> treatment. They aren't in params, because they don't share the same
> trait that is the entire reason params exist.

But if they can be overriden at __init__, shouldn't they be there?  One 
example where *I* do it is this one:

===============================================================================
            widgets.AutoCompleteField(
                name = 'endereco',
                search_controller="/%s/search_endereco" % tipo,
                search_param="endereco",
                result_name="enderecos",
                text_field = widgets.TextField(
                    name = 'endereco_text',
                    attrs = {'size':51},
                    label = _(u'Endereço'),
                    validator = validators.UnicodeString(if_empty = None)),),
===============================================================================

"text_field" needed a label, a bigger size and a validator to me and I haven't 
seen how to say that in __init__ without recreating this "subwidget". 

> No... it's actually saying, my __init__ has 5 arguments, 2 of which
> have member widgets and 3 of which need to be overrideable at display
> time.

Or, in some cases, all 5 of them...

-- 
Jorge Godoy      <[EMAIL PROTECTED]>


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears Trunk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/turbogears-trunk
-~----------~----~----~----~------~----~------~--~---

Reply via email to