A bunch of toscawidget questions:

1) I'm having no luck getting a toscawidgets.form.DataGrid to work  
using much the same mechanism I would use with  
turbogears.widgets.DataGrids:

I'm using the latest toscawidgets* from the Python cheese shop.

Simple code like:

@expose(template="cocoahaus.templates.test")
def index(self, *args, **kwargs):
     theFields = [('Key', 'Value'),]
     theGrid = toscawidgets.form.DataGrid(name = 'grid', fields =  
theFields)
     return dict(grid = theGrid, data = gridData)

Will consistently give me this error:

Page handler: <bound method Test.index of  
<cocoahaus.controllers.Test.Test object at 0x25a60b0>>
Traceback (most recent call last):
...
File "build/bdist.darwin-8.8.1-i386/egg/genshi/core.py", line 202, in  
_ensure
File "build/bdist.darwin-8.8.1-i386/egg/genshi/plugin.py", line 29,  
in ET
AttributeError: 'str' object has no attribute 'tag'

2) If I want to modify a widget to use my own genshi template is it  
merely a case of something like this:

class MyDataGrid(toscawidgets.forms.DataGrid):
     template = "genshi:cocoahaus.templates.widgets.MyDataGrid"

3) Are toscawidgets going to replace the turbogear's widgets - and if  
so, in what time frame?

Cheers.

        Jon.

--~--~---------~--~----~------------~-------~--~----~
 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?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to