Skip to content

Commit 82f8bee

Browse files
committed
Don't add repeated xlmns:xlink declarations in svg-create
* lisp/svg.el (svg-create): Fix previous unconditional addition of the xmlns:xlink declaration -- callers may already add one, and having it twice is something most svg libraries doesn't like.
1 parent 78f76fe commit 82f8bee

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lisp/svg.el

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,8 @@ any further elements added."
7070
(height . ,height)
7171
(version . "1.1")
7272
(xmlns . "http://www.w3.org/2000/svg")
73-
(xmlns:xlink . "http://www.w3.org/1999/xlink")
73+
,@(unless (plist-get args :xmlns:xlink)
74+
'((xmlns:xlink . "http://www.w3.org/1999/xlink")))
7475
,@(svg--arguments nil args))))
7576

7677
(defun svg-gradient (svg id type stops)

0 commit comments

Comments
 (0)