In general, it doesn't make any sense to me at all. Is there some sort
of coherent principal thinking behind how it works now, and if so
where is it documented? As a starting question:
All formatters implement IFormatItem, but then they are registered in
ZCML as IFullFormatters. Then all items are wrapped in
FullFormatterWrappers. It seems to me that we can remove the
FullFormatterWrapper and the registering of formatters as
IFullFormatters, and exactly the same thing would happen.
So what is the purpose of the FullFormatter thingy at all? I can't
find any explanation of what "full" formatting is as opposed to not
full formatting.
Also, there seem to be no way to actually format the whole newsletter
as such. Just items. And I need to format the full newsletter.
Should I rip it all out and make something else, because as it is now
there seems very little chance of actually styling newsletters in some
sort of sensible way. Because that's what I feel like, but I'm
slightly annoyed, so that may be the reason. :)
2009/12/29 Lennart Regebro <lreg...@jarn.com>:
> --
> To post to the "Singing & Dancing" group, send email to singing...@googlegroups.com
> To unsubscribe from this group, send email to
> singing-danci...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/singing-dancing
--
Rok Garbas, Python.Zope.Plone consulting
web: http://garbas.si
phone(si): +386 70 707 300
phone(es): +34 68 941 79 62
email: r...@garbas.si
Yes, it did, I should in fact override the composer.
It's not a question of "Generic" vs "Easy", in fact to be able to
format things reasonably you must do both.
Funny that everything uses the ZCA except selecting composers. We'll
have to fix that so you can change composer. Users will want to create
new newsletters, and select the custom composer manually.
--
Lennart Regebro
www.jarn.com/lregebro
--
It might be possible to extend the composer with a "Template" drop
down, to use instead of the default template file, but I'm not sure
how to best register the available templates.
--
Lennart Regebro: Python, Zope, Plone, Grok
http://regebro.wordpress.com/
+33 661 58 14 64
I had exactly this idea a while ago but never got around to implementing it.
Daniel
OK, done and checked in.
Next step: I need to improve the rendering of content. This is already
overrideable, and I can just add custom item formatters for the
content, but that would mean one formatter per content type, more or
less. Naybe we can do something more generic? Any ideas?
Awesome, thanks! I think this change warrants a bump of version
numbers to 0.9. Since, from what I understand, there's a chance that
people will get newsletters with different HTML. Is that so?
> Next step: I need to improve the rendering of content. This is already
> overrideable, and I can just add custom item formatters for the
> content, but that would mean one formatter per content type, more or
> less. Naybe we can do something more generic? Any ideas?
I can't think of a more generic way. Except for the "crazy render and
strip solution". ;-)
Daniel
Nah, it should use the old template by default.
> I can't think of a more generic way. Except for the "crazy render and
> strip solution". ;-)
OK. Well keep that as a fallback. :)