Re: Node interface extension for DOM3

I think you'll better look at the spec yourself.
http://www.w3.org/TR/SVG/struct.html#Head said : <<


SVG makes extensive use of URI references [URI] to other objects. For
example, to fill a rectangle with a linear gradient, you first define a
'linearGradient' element and give it an ID, as in:
<linearGradient id="MyGradient">...</linearGradient>

You then reference the linear gradient as the value of the 'fill' property
for the rectangle, as in:
<rect style="fill:url(#MyGradient)"/>

>>

The second example on which I can explain what I want is below :

<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20000802//EN"
  "http://www.w3.org/TR/2000/CR-SVG-20000802/DTD/svg-20000802.dtd">
<svg width="10cm" height="5cm">
  <desc>Example Use01 - Simple case of 'use' on a 'rect'</desc>
  <defs>
    <rect id="MyRect" width="6cm" height="1cm"/>
  </defs>
  <use x="2cm" y="1cm" xlink:href="#MyRect" />
  <use x="2cm" y="2.5cm" xlink:href="#MyRect" />
</svg>

I want the following : I have the reference to "MyRect" element (or Node). I
want to get all referencers to this object. In the above example there are
two "referencers" - second and third line in the source from the end.

I think I'm not wrong with the mailing-list (I guess this topic is not for
www-svg@w3.org). I'm not an expert with all XML-based applications, but I've
heard smth about XLink. If we use this application, possibly, we do need the
same feature. Finally, in the spec example I've quoted in the beginning,
this feature (again possibly) will be useful for CSS (styling in SVG is
inherited from CSS).



----- Original Message -----
From: "Joseph Kesselman/Watson/IBM" <keshlam@us.ibm.com>
To: "Anton Shevchenko" <sanc0der@mail.ru>
Cc: <www-dom@w3.org>
Sent: Tuesday, September 05, 2000 5:24 PM
Subject: Re: Node interface extension for DOM3


>
> >In SVG, we can use the <use> tag to
> >reference other elements, defined somewhere. I understand that as node or
> >element referencing (in the DOM-style)
>
> How is that reference declared in SVG's DTD or Schema? I would expect it's
> either an ID/IDREF pair, or uses the Schema's new Key capabilites, or is
an
> XPath. The first can be supported via DOM Level 2's getElementByID()
> method. The second is reasonably likely to be supported by DOM Level 3's
> Content Model chapter. The third might be a middleware issue rather than a
> DOM issue per se.
>
> ______________________________________
> Joe Kesselman  / IBM Research
>
>

Received on Tuesday, 5 September 2000 09:58:56 UTC