On Sat, May 24, 2008 at 4:25 AM, Christopher Arndt <[EMAIL PROTECTED]> wrote: > > Mark Ramm schrieb: >>> - Would one still be able to have templates with the same base name? >>> - Does this work with all template engines supported by TG2? >> >> Well, this will work with Mako, Genshi, and Jinja at the moment. The >> only thing nessisary to make it work with a new template system is a >> render_whatever() function which takes a template name and a dict, and >> returns the rendered string. >> >> Pylons has render_genshi, render_mako, and render_jinja functions, and >> it would be trivial to add new ones. We will also put a dictionary >> of renderers into the config in environment.py, so tg2 users should be >> easily able to define and use custom renderers. > > Do I understand correctly then, that you want to move away from using > Buffet plugins for template rendering? > yes this is what pylons 0.9.7 did. see http://pylonshq.com/project/pylonshq/browser/pylons/templating.py
> If so, this would mean that template engines would have to provide > special code for Pylons/TG2, which defeats the idea of having a > standardized plugin interface accross frameworks. > yes for pylons not yet true for tg2. > I know that the Bufet API has its limitations*, but as TurboGears > provides a good part of the actual implementataions it would be in a > good position to introduce enhancements to it. > Agreed, now the question is. should it still live? > I may have got this all wrong, I don't know much about the way Pylons > handles templates, so please correct me, if this is the case. > > > * For example, there is currently no stndard way for a template engine, > to influence response headers, e.g. to set the content type of the response. > > > Chris > > > > --~--~---------~--~----~------------~-------~--~----~ 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?hl=en -~----------~----~----~----~------~----~------~--~---
