markers and attribute inheritance

Hello,

I've got a drawing application (Visio like drawings for the Pocket PC,
www.pocketdraw.com) that uses a slightly modified SVG as its native file
format. SVG support has been limited to the stuff which is necessary for
diagramming, with some additional elements and attributes (new
namespace) added to support concepts such as connecting lines between
objects.

While working on the SVG exporter, I was horrified to discover that I
slightly misinterpreted the SVG marker behavior. In my implementation,
markers inherit attributes *after* they're deep cloned into the context
of their reference. This ensures that arrows, for example, take on the
color of the line that they're applied to.  

I see now that this is not how SVG implements markers, leading me to
wonder why. Am I the only one who thinks the current SVG marker behavior
is wrong? I can't help but question the utility of a marker that doesn't
automatically match the line it's applied to. Are all my "red" lines
supposed to use different marker definitions than my "black" ones? It
seems to me that you can always explicitly specify attributes in the
marker definition if you want its appearance fixed. But the SVG behavior
allow for marker reuse among lines with different attributes.  

Any opinions? Am I missing something?

Cheers,

-brian

Received on Thursday, 12 December 2002 17:05:11 UTC