RE: dnd [was: Re: export patches]
On Mo, Dez 22, 2003 at 09:15:50 +0000, bulia byak wrote:
Hi,
I tested your dnd patch but I don't seem to be able to make it work. If
I
type in some SVG in your test program and drag it into inkscape, no
object
appears on the canvas, but there is a new empty <g> in the XML editor.
If I
type <text>abc</text>, after dragging it becomed <g id="123">abc</g>.
Try typing/pasting a whole svg document, that's what The Gimp will send, when their path dnd support is ready :)
Still does not work. Now the problem is namespaces. If I drag a document containing one <rect>, it appears as svg:rect within inkscape and is not displayed. (Even though in original SVG, there was no prefix.) This is because internally inkscape, simplistically, stores names with prefixes, so a mismatch in a prefix makes an element unrecognizable.
I'm not sure what is the best/simplest to fix this: make it so that dragged SVG is inserted without namespace prefixes, or make it so that Inkscape can handle full qualified names (with namespace URI and prefix for each name). I guess the first way is simpler. Mental, can you comment?
_________________________________________________________________ Help STOP SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=dept/bcomm&pgmarket=en-ca&RU=http%3a%2f%2f...
Hi
On Mo, Dez 22, 2003 at 11:55:15 +0000, bulia byak wrote:
Still does not work. Now the problem is namespaces. If I drag a document containing one <rect>, it appears as svg:rect within inkscape and is not displayed. (Even though in original SVG, there was no prefix.) This is because internally inkscape, simplistically, stores names with prefixes, so a mismatch in a prefix makes an element unrecognizable.
I'm not sure what is the best/simplest to fix this: make it so that dragged SVG is inserted without namespace prefixes, or make it so that Inkscape can handle full qualified names (with namespace URI and prefix for each name). I guess the first way is simpler. Mental, can you comment?
Hm. My code does almost the same as the svg import code does (well, i copied from there ;)), so if you import you should get the same symptops, right?
Alex
participants (2)
-
Alexander Clausen
-
bulia byak