tried this during the weekend. In general I got it running OK. There's
a traceback that comes when you want to use the layout preview
feature. This is because on this file:
ptah/ptah/manage/layout.py
Line 5 is currently commented out and that defines PyramidView, which
is expected to be there on line 32.
Carlos de la Guardia
we removed pview, so layout preview doesnt work yet.
The reason for me to look at Ptah, is to have some kind of framework
to create a decent UI on top of pyramid (think main_template, reusable
code-snippets, macro's, layouts)
Yesterday I noticed bottle_cap
https://github.com/pauleveritt/pyramid_bottlecap
So now we have two layout-implementations?
Is there any duplicated effort here regarding the layout-system?
Are there synergies possible?
Just asking.
Greets
WouterVH
There probably are. Up to now it has been premature for us to try. Both KARL and Ptah have been iterating through changes in what they're trying to do on layouts and how they are trying to do it.
Yesterday we got the +1 from OSF (the customer) to put a bunch of resources into Bottlecap-ifying KARL. At the same time, Chris Rossi is finishing a big refactoring this week. We can then write up Bottlecap's layout approach and let Ptah see if it overlaps.
I know Alan had some ideas for layouts (e.g. placeful overrides) that we didn't have. We likely have some things that don't fit his ideas as well.
--Paul
I agree with Wouter. I want Ptah to share a UI layer so programmers can make something reasonably nice looking without much thought. This has not been accomplished.
I will document Ptah layouts before Xmas. The main features of Ptah layouts:
Ptah.layout does not depend on zpt, mako, jinja
The resulting value of a layout call is (HTML) which is included by the next outer layout.
The inner-most layout is computed and it's HTML passed to next outer layout
The inner to outer passing HTML string from layout/view to the next is simple and fast.
A nice side effect is by the time you compute HEAD you know all requirements to satisfy (js, CSS, etc) which need inclusion to make page work (reason ptah.library works naturally using this approach)
Also need to give credit to Nikolay. This layout system was done in previous project he worked on.
Wouter it is useful to get feedback. What fits your brain? ptah.layout? Bottlecap?
Cheers
Alan