On Fri, Jul 13, 2007 at 12:42:55PM -0400, Stephan Richter wrote: > > So, in my snippet-way, it looks like that for every widget: > > > > <span replace="structure view/widgets/mywidget/snippets/foo" />
Too many slashes! My brain is exploding. > > And in the macro-style? Perhaps like that? > > > > <span metal:use-macro="snippets/foo"> > > <span metal:fill-slot="snippet"> > > <span replace="structure view/widgets/mywidget/render /> > > </span> > > </span > > This is overcomplicated. If I remember correctly, you can do: > > <tal:block define="widget view/widgets/mywidget"> Almost. You need a nocall: there <tal:block define="widget nocall:view/widgets/mywidget"> > <span metal:use-macro="macro:snippet" /> It's the first time I see 'macro:' in TALES expressions. Interesting. > </tal:block> > > Also, if you do not like macros, you can register simple views to have: > > <span replace="structure view/widgets/mywidget/foo" /> > > For me the cost of the snippet is too high: > > 1. It introduces a new pattern for cases that are well-covered otherwise. > 2. It requires a new directive. > > But as I said before, you should publish your work and see how people like it. FWIW I'm with Stephan on this one. Too many new concepts. Marius Gedminas -- A computer without Windows 9x is like a fish without a bicycle. -- With apologies to Gloria Steinem
signature.asc
Description: Digital signature
_______________________________________________ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users