[Grok-dev] Re: Portlets (and maybe other skinning).
Philipp von Weitershausen
philipp at weitershausen.de
Tue Mar 20 21:40:16 EDT 2007
On 20 Mar 2007, at 11:44 , Lennart Regebro wrote:
> On 3/20/07, Philipp von Weitershausen <philipp at weitershausen.de>
>> Well, of course you register it for an interface or a class. But you
>> don't get to choose it. The developer writing viewlets does by saying
>> something like this:
>> class MyViewlet(Viewlet):
>> This can be left out if ClassOrInterface can be assumed, like with
>> views and adapters.
> Eh, but if you don't get to choose it, which ClassOrInterface
> should it be?
grok.context(Mammoth) # this view is for mammoth objects (which
In this case, the view grokker would receive the Mammoth class as its
context, even if the grok.context() line weren't there. grok.context
() is the adapts() for views in grok, if you will.
>> > I have no idea of how to do layers and skinning in a way that is
>> > and fast, and does not involve changing all templates.
>> I do. http://openplans.org/projects/deliverance :)
> Well, it is possible if we do one separate request per viewlet. But I
> don't like that.
Deliverance doesn't work that way, at least it doesn't have to use
> And I don't like make Deliverance required for Grok.
Who says it has to be required.
>> > Which is why we need to decide on a way of doing this pretty soon.
>> Why is there a rush? It's obviously good to be thinking about stuff
>> and to move forward, but why do we have to decide on something? And
>> why soon? I think Grok provides us with an excellent platform to do
>> some experiments that have not been possible in the grown Zope
>> platform for a long time.
> Because until we have done this decision, Grok is useless.
Sorry, but that's bullshit. You can use ZPT macros, you can use other
forms of skinning and theming (e.g. Deliverance), you can use
whatever you've created. How does that make Grok useless?
Obviously Grok should come with some manner of creating common themes
for application (and it already does, ZPT macros) and I agree we
should be looking for alternatives. I simply object to the rush.
More information about the Grok-dev