Re: lambda was RE: W3C-transformation language petition

Subject: Re: lambda was RE: W3C-transformation language petition
From: Guy_Murphy@xxxxxxxxxx
Date: Fri, 12 Mar 1999 11:27:17 +0000
Hi Daniel.

An interesting assertion, and I suspect a matter of simple taste in the
simple example you give. Consider however...

<xsl:template match="document">
     <!-- Present TOC -->
     <xsl:for-each select="section/title">
          <table>
               <tr>
                    <td><img src="logo.gif" /></td>
                    <td><xsl:value-of /></td>
               </tr>
          </table>
     </xsl:for-each>

     <div>
          <xsl:attrbibute name="style">
               <!-- decoration here -->
          </xsl:attribute>
          <xsl:apply-templates />
     </div>
</xsl:template>

... and contruction can get a *lot* more complex for a site with a rich
dHTML interface, and CSS syntax without major revamping simply cannot
support it. And bent out of shape to support it, I beleive would not be any
easier to read.

The other thing is, and I realise it's probably just personal taste, but I
spend a lot of time as a Web designer throwing tags around. I'm used to
looking at nested tags, and I'm used to reading nested tags at a glance, so
personaly I prefer the XSL construction syntax.

It might have been nice if the whole world was curly braces, personaly I
have a fondness for them, but HTML and XML have pointy ones, so I guess we
have to live with it.

We might look at the fantasy of a unified syntax....

xsl:template { match: document } {
     xsl:for-each { select: section/title } {
          table {} {
               tr {} {
                    td {} {{h
                         img { src: logo.gif } {}
                    }
                    td {} {
                         xsl:valueOf {} {}
                    }
               }
          }
     }

     div { font-family: Verdana } {
          xsl:applyTemplates {}{}
     }
}

...But I'm really not sure if it's easier to read or not. I think we should
just learn to live with the pointy brackets, I would definately prefer to
not have to intermix braces with brackets.

Cheers
     Guy.





xsl-list@xxxxxxxxxxxxxxxx on 03/12/99 03:11:41 PM

To:   xsl-list@xxxxxxxxxxxxxxxx
cc:    (bcc: Guy Murphy/UK/MAID)
Subject:  Re: lambda was RE: W3C-transformation language petition




Didier PH Martin a ?crit :
>  <element match = "tag">
>         <paragraph
>                 font-size = "10pt">
>         </paragraph>
>  </elemen>
Or a more user- readable
        tag { cast-element : paragraph ;
              font-size : 10pt
            }
based on CSS syntax...
</Daniel>

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list






 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread