On 12/9/05, aw <[EMAIL PROTECTED]> wrote:
>
> I could not find any documentation on how to write a widget but I took
> a stab at it by reading the code.  Sorry, I am not an expert Python
> programmer.  About 1 week worth of coding so far.  This grid took about
> 3 hours.  Mainly playing around.  Thanks for help on getattr.

Yes, there aren't any docs on writing a widget. There will be soon!

We should fix the grid widget that's in there, because there's a part
it's not doing "correctly". Widgets are designed to be stateless and
reusable. In other words, the data is passed in at insert/render time.

I put together a quick grid widget here:
http://www.turbogears.org/svn/turbogears/trunk/turbogears/widgets/formmaker.py

(Note that this file is going to move as soon as I can figure out why
the tests are failing on my computer. It's going to move to this
non-existent location:
http://www.turbogears.org/svn/turbogears/trunk/turbogears/fastdata/formmaker.py
)

The grid that I'm pointing to there takes in a SelectResults object
and creates a grid from it.

Kevin

Reply via email to