W3C home > Mailing lists > Public > www-style@w3.org > June 2007

Re: attributes as virtual tags

From: Rikkert Koppes <rikkert@finalist.com>
Date: Thu, 21 Jun 2007 09:56:53 +0200
Message-ID: <467A2F45.6010007@finalist.com>
To: Dmitry Turin <sql40@narod.ru>
CC: www-style@w3.org

As attributes are considered child nodes of an element, this kinda makes 
sense.

This also makes some sense in a rdf framework where

<rdf:Description rdf:about="http://www.w3.org/TR/rdf-syntax-grammar">
  <ex:editor>
    <rdf:Description>
      <ex:homePage rdf:resource="http://purl.org/net/dajobe/"/>
      <ex:fullName>Dave Beckett</ex:fullName>
    </rdf:Description>
  </ex:editor>
  <dc:title>RDF/XML Syntax Specification (Revised)</dc:title>
</rdf:Description>

is the same as

<rdf:Description rdf:about="http://www.w3.org/TR/rdf-syntax-grammar"
                 dc:title="RDF/XML Syntax Specification (Revised)">
  <ex:editor>
    <rdf:Description ex:fullName="Dave Beckett">
      <ex:homePage rdf:resource="http://purl.org/net/dajobe/"/>
    </rdf:Description>
  </ex:editor>
</rdf:Description>

[http://www.w3.org/TR/rdf-syntax-grammar/#section-Syntax-property-attributes]

Regards,
Rikkert Koppes (mophor)


Dmitry Turin wrote:
> Good day.
>
> Today HTML-element is so, that applied information is between openning and closing tags.
> All attributes of openning tags are service attributes.
> At the same time, data are saved in database as records,
> which is extracted as tags, several attributes of which contains applied information.
>
> But even visualization of attributes by pseudo-element '::before' or '::after'
> don't allow to specify _style for attributes_.
>
> I offer to specify attributes in css-file with sign "ž" before their names,
> that withdraw attribute from tag and transform it into enclosed tag.
> Let's name these tags as virtual tags.
>
> Thus the following construction
>
> <style>
>   žname    {color: red  }
>   žsurname {color: gray }
> </style>
> <body>
>   <record name="a" surname="b">
>   <record name="c" surname="d">
> </body>
>
> will means the same, as
>
> <style>
>   name     {color: red  }
>   surname  {color: gray }
> </style>
> <body>
>   <record>
>     <name>   a</name>
>     <surname>b</surname>
>   </record>
>   <record>
>     <name>   c</name>
>     <surname>d</surname>
>   </record>
> </body>
>
>   So we see, that michanism of property "content" is _essentially narrower_,
> than michanism of virtual tags.
>   I don't want to reduce importance of property "content":
> it is necessary to change already existing content of html-element,
> or to specify content of pseudo-element.
> But when you try to reduce all cases to property "content", property acts as limiter,
> and thus data are subdivided into two groups depending on their forms:
> if data is between an open and close tags, it is data _of full value_ (it may has style);
> if data is in an attribute, it is _inferior_.
>
> P.S.
> Other example: next construction
>
> <style>
>   tab         { display: table      }
>   a           { display: table-row  }
>   ža1,ža2,ža3 { display: table-cell }
> </style>
> <body>
>   <tab>
>     <a a1="v11" a2="v12" a3="v13">
>     <a a1="v21" a2="v22" a3="v23">
>     <a a1="v31" a2="v32" a3="v33">
>   </tab>
> </body>
>
> will be understanded as
>
> <style>
>   tab        { display: table      }
>   a          { display: table-row  }
>   a1,a2,a3   { display: table-cell }
> </style>
> <body>
>   <tab>
>     <a>
>       <a1>v11</a1>
>       <a2>v12</a1>
>       <a3>v13</a1>
>     </a>
>     <a>
>       <a1>v21</a1>
>       <a2>v22</a1>
>       <a3>v23</a1>
>     </a>
>     <a>
>       <a1>v31</a1>
>       <a2>v32</a1>
>       <a3>v33</a1>
>     </a>
>   </tab>
> </body>
>
>
> Dmitry Turin
> HTML6     (6.1.0)  http://html60.chat.ru
> SQL4      (4.0.5)  http://sql40.chat.ru
> Computer2 (2.0.2)  http://computer20.chat.ru
>
>
>   
Received on Thursday, 21 June 2007 07:57:07 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:54:51 GMT