[Seaside] It is possible an html more readable?
Sebastian Sastre
ssastre at seaswork.com
Sun Mar 9 17:01:38 UTC 2008
SUScript>>printContentOn: aStream
"Renders the receiver in aStream.
The cr message at end of statements aims to
be nice to javascript tools in UA's for develpment mode"
statements
do: [ :each | aStream javascript: each ]
separatedBy: [
WACurrentSession value application deploymentMode
ifTrue: [aStream nextPut: $; ]
ifFalse: [aStream nextPut: $; ; cr]]
is my current version,
cheers,
Sebastian Sastre
> -----Mensaje original-----
> De: seaside-bounces at lists.squeakfoundation.org
> [mailto:seaside-bounces at lists.squeakfoundation.org] En nombre
> de Sebastian Sastre
> Enviado el: Domingo, 09 de Marzo de 2008 13:54
> Para: 'Seaside - general discussion'
> Asunto: RE: [Seaside] It is possible an html more readable?
>
> Understood. Anyway I've found that:
>
> SUScript>>printContentOn: aStream
> statements
> do: [ :each | aStream javascript: each ]
> separatedBy: [ aStream nextPut: $; ; cr]
>
> do the trick. Is not needed to mess the html, just
> facilitate a cr at
> the endo of line of js sentences in scripts. I'll set it in a
> loose method to
> add the cr or not depending on the deployment mode setting. I
> suggest it for
> official release.
>
> Thank you for the more general reference,
>
> cheers!
>
> Sebastian Sastre
>
>
> > -----Mensaje original-----
> > De: seaside-bounces at lists.squeakfoundation.org
> > [mailto:seaside-bounces at lists.squeakfoundation.org] En nombre
> > de Lukas Renggli
> > Enviado el: Domingo, 09 de Marzo de 2008 13:00
> > Para: Seaside - general discussion
> > Asunto: Re: [Seaside] It is possible an html more readable?
> >
> > > If not available, what is needed to make Seaside to
> > be able to do this
> > > "development html"?
> >
> > You can have a look how the pretty printer in the halos
> > displays the XHTML.
> >
> > Generally adding spaces or newlines to the XHTML changes the layout,
> > therefor Seaside does not offer this possibility. You can
> have a look
> > at the documentation of tidy, a famous open-source HTML pretty
> > printer: this is a pretty complex piece of software and in the
> > documentation there are several warnings that it might screw up your
> > layout. I prefer to use FireBug or the Safari Inspector to
> explore the
> > generated XHTML.
> >
> > Lukas
> >
> > --
> > Lukas Renggli
> > http://www.lukas-renggli.ch
> > _______________________________________________
> > seaside mailing list
> > seaside at lists.squeakfoundation.org
> > http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>
> _______________________________________________
> seaside mailing list
> seaside at lists.squeakfoundation.org
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
More information about the seaside
mailing list