Ed Singleton wrote:
>
> I guess so, but I really would like to work out how to create my own
> form fields.  Is there no explanation of how the widgets work
> internally?
>

Not much ATM :-(, anyway keep this in mind usually what you need are
more parameters to  customize the widget behavior at display/render
time, to do this *all* that you need is listing an additional parameter
in params, this tells the Widget system that this is attribute is
special and you can update it at construction or render/display and
it's available inside the template or update_params, you don't need to
override init or update_params to manage it.

Example:

class FooBar(Widget):
   template = """<div>${foo}</div>
   params = ["foo"]
   foo = "Hello"

>
> Thanks for this.  It was enough info for me to do a rough draft of
> what I want.  It's untested and needs more stuff adding, but it's
> basically what I want.  (Though I really want to know how I add extra
> parameters and stuff).  It's the RepeatingFieldSet with a different
> template (uses the legend for the header content):
>

Are you sure that what you want is a repeating widget? this widget uses
a repetitions parameter to display one or more repetitions of the same
widget and to validate them.

I think you don't want this in your case...

Ciao
Michele


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" 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
-~----------~----~----~----~------~----~------~--~---

Reply via email to