[Seaside-dev] WACurrentSession users

Lukas Renggli renggli at gmail.com
Tue Jul 15 08:48:03 UTC 2008


> Ah ok, good to know it's being used. And yes, when I wrote the
>  original pretty printer I has to quickly unlearn the credo that
>  whitespace isn't relevant in XML. :)

Yes, and worst of all, the whitespace handling it is even coupled with
the applied CSS ;-)

>  So I can see a desire to have other subclasses of Document, but it
>  still doesn't answer my question which is: If you do have subclasses,
>  is it useful to be able to select the one you want in the
>  configuration or would you want it hard coded to a particular
>  component or handler or what-not? Is it beneficial to have a config
>  option for this or should everywhere in the code just use the
>  hardcoded document class they want?

The responsibility of the Document is to generate the tags, as well as
the preamble and postamble of the XHTML. So the subclass SUDocument is
only there to avoid generating <html><head>.

The current situation where the class is hardcoded at several places
seems to be undesirable. The document class is an application wide
setting. Maybe we can add an accessor to the WAApplication that
returns the document class to avoid having to hard-code the class
everywhere? If needed we can always turn that into a setting.

Cheers,
Lukas

-- 
Lukas Renggli
http://www.lukas-renggli.ch


More information about the seaside-dev mailing list