Seeing in #71 that <tspan> isn't properly implemented I have taken the liberty to do this.
Previously spans were using the attributes of the parent
tag. They also couldn't be children of other tags.
The element now stores a list of text segments which are rendered in order to ensure correct z-ordering.
This allows elements to contain other spans itself.
The element now simply inherits from and performs the additional transformation defined by 'text-anchor'.
The Text element should be API compatible with previous versions. Fot the Tspan tag however I wasn't sure how to deal with
the setText method. If there is no child then it can behave as before and simply overwrite the contained text.
If child spans exists I'm not so sure what should happen. For now I have removed the method, though intend to add it back in
once it is clear how it should behave.
Seeing in #71 that
<tspan>
isn't properly implemented I have taken the liberty to do this.Previously spans were using the attributes of the parent
tag. They also couldn't be children of other tags.
The element now stores a list of text segments which are rendered in order to ensure correct z-ordering.
This allows elements to contain other spans itself.
The element now simply inherits from and performs the additional transformation defined by 'text-anchor'.
The then it can behave as before and simply overwrite the contained text.
If child spans exists I'm not so sure what should happen. For now I have removed the method, though intend to add it back in
once it is clear how it should behave.
Text
element should be API compatible with previous versions. Fot theTspan
tag however I wasn't sure how to deal with thesetText
method. If there is no child