all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#26953: [PATCH] 26.0.50; svg-line uses incorrect parameters
@ 2017-05-16 15:02 Ari Roponen
  2017-05-21  0:15 ` Glenn Morris
  0 siblings, 1 reply; 2+ messages in thread
From: Ari Roponen @ 2017-05-16 15:02 UTC (permalink / raw)
  To: 26953

This code should draw a horizontal line:

  (require 'svg)
  (let ((svg (svg-create 50 50 :stroke-color "black")))
    (svg-line svg 0 25 50 25)
    (svg-insert-image svg))

but it draws a diagonal one instead. The following patch fixes the
problem.

* lisp/svg.el (svg-line): Use correct parameters.

diff --git a/lisp/svg.el b/lisp/svg.el
index cb924f8163..fc1a6d60e1 100644
--- a/lisp/svg.el
+++ b/lisp/svg.el
@@ -107,8 +107,8 @@ svg-line
    svg
    (dom-node 'line
 	     `((x1 . ,x1)
-	       (x2 . ,y1)
-	       (y1 . ,x2)
+	       (x2 . ,x2)
+	       (y1 . ,y1)
 	       (y2 . ,y2)
 	       ,@(svg--arguments svg args)))))
 





^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-05-21  0:15 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-05-16 15:02 bug#26953: [PATCH] 26.0.50; svg-line uses incorrect parameters Ari Roponen
2017-05-21  0:15 ` Glenn Morris

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.