That is an interesting idea ("apply decorator"), but how could you
would then specify alternate decorators?

Setting alternate decorators was intended to be an uncommon occurence,
but this is another place where experimental code (the whole decorator
concept - only one template was implemented with a real _decorator)
crept into a release without refinement.

I would suggest changing the "default" to be "no decorator" and
reserve $decorator=my_decorator as the advanced (and only) use of
decorators.  This way if $decorator does not have a value there will
be no attempt to apply a decorator.

Lance

On 8/15/05, Allen Gilliland <[EMAIL PROTECTED]> wrote:
> hmmm ... well i've never seen anything like this available on the UI.
> 
> the code suggests that you could set a velocity variable named "decorator" to 
> point to the page template name you want to use as a decorator, but i'm not 
> sure that's really a nice way to do it.
> 
> i am suggesting that the "_decorator" template is a standard part of every 
> weblogs page templates, so a user can't delete it or rename it.  then the 
> user can *apply* it to any other pages they wish.  on the UI this would be 
> indicated somewhere with a checkbox called "apply decorator?", or some other 
> way to toggle it on/off for a given template.
> 
> -- Allen
> 
> 
> On Mon, 2005-08-15 at 10:53, Lance Lavandowska wrote:
> > The decorator is not necessarily an all-or-nothing proposal, you can
> > specify the decorator to be used in each page template (you'll have to
> > find Google's cache of my blog entry - this should be moved into the
> > wiki, or look at the rendering source to see how it identifies the
> > decorator to be used).  Also, the decorator can be a "no op", not
> > writing any content of it's own.
> >
> > Lance
> >
> > On 8/15/05, Allen Gilliland <[EMAIL PROTECTED]> wrote:
> >
> > > I also had a side thought about the decorator template.  Currently I am 
> > > still not a fan of the decorator template mainly because it either has to 
> > > be applied to all page templates or none of them.  This seems 
> > > inconvenient to me.  I think it would be preferable if you could apply 
> > > the decorator to only selected page templates.  This would allow users 
> > > the convenience of using the decorator without requiring that it be used 
> > > for *all* templates.
> > >
> > > I think the best example in this case is a css page template.  I would 
> > > consider using the decorator template, except that I have a css template 
> > > as well and if I use the decorator then my css template won't work.
> 
>

Reply via email to