Cliff Wells wrote:
> On Sat, 2006-01-21 at 18:42 +0100, Dirk Meyer wrote:
>> "Daniel C. Casimiro" wrote:
>> > Next, a "view" is defined in a file "music_view.pyxml."  This would be
>> > the tricky implementation part...
>> >     
>> > <canvas style="video menu">
>> >   <image name="background" width="100%" height="100%"/>       
>> >   <container x="overscan_x1" y="overscan_y1" width="complete width 
>> >    overscan_x1 - overscan_x2" height="...">
>> >    <% for item in music_library: %>        // Python code...
>> >    <text> <% item.name %> </text>  
>> >    ...
>> 
>> By playing with a webserver (see kaa.cherrypy) I found Kid
>> (http://kid.lesscode.org/). Maybe we can use that.
>> 
>
> I'd recommend taking a look *inside* kid before you do that.  It's not
> pretty. User defined variables clash with class attributes, so you can't
> use certain variables in your templates (the docs mention 3 or 4 of
> them, but there's actually around twice that many).

So it is 6-8. Depending of the name, it does not seems to be a
problem. 

> Also, fwiw, XML sucks.  

I know.

> Have you considered using one of the Python templating/XHTML
> generation libs like Nevow's Stan or XIST?  Much better.  Terse,
> clean syntax, less typing, more power.

Why is XHTML better than XML? XHTML has the problem that it is based
on a specfic DTD (HTML) where XML is free.

The reason for XML (and maybe Kid) is that theme designers don't know
Python, they don't want to know. But many can 'code' HTML pages, know
php and stuff like that. I would prefer a Python based skin code, but
we would never find any skin designers using that. So XML is our onlt
choice because people know it (and they don't know it sucks)


Dischi

-- 
"Software is like sex: it's better when it's free.", Linus Torvalds

Attachment: pgp2TfEh0UfbA.pgp
Description: PGP signature

Reply via email to