[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/svg-clock d1aeadd 11/18: There's no longer an svg-def f
From: |
Stefan Monnier |
Subject: |
[elpa] externals/svg-clock d1aeadd 11/18: There's no longer an svg-def function in svg.el |
Date: |
Tue, 1 Dec 2020 17:26:03 -0500 (EST) |
branch: externals/svg-clock
commit d1aeadd9f4621afa4db9fe5cacafa9569f4f6d8d
Author: Lars Ingebrigtsen <larsi@gnus.org>
Commit: Lars Ingebrigtsen <larsi@gnus.org>
There's no longer an svg-def function in svg.el
---
svg-clock.el | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/svg-clock.el b/svg-clock.el
index bf0147c..a42e0af 100644
--- a/svg-clock.el
+++ b/svg-clock.el
@@ -140,8 +140,8 @@ its colors are FOREGROUND and BACKGROUND."
(svg-clock-transform
'rotate
(+ (* hours 30) (/ minutes 2.0)) .5 .5)))))
- (dolist (def defs) (svg-def svg def))
- (svg-def svg clock)
+ (dolist (def defs) (svg-clock-def svg def))
+ (svg-clock-def svg clock)
(dom-append-child svg
(svg-clock-use 'clock
(svg-clock-transform 'scale size size)))
@@ -257,6 +257,13 @@ Optional argument ATTRIBUTES contain conses with SVG
attributes."
(r . ,radius)
,@attributes)))
+(defun svg-clock-def (svg def)
+ (dom-append-child (or (dom-by-tag svg 'defs)
+ (let ((node (dom-node 'defs)))
+ (dom-add-child-before svg node) node))
+ def)
+ svg)
+
(defun svg-clock-line (x1 y1 x2 y2 &rest attributes)
"Create an SVG line element starting at (X1, Y1), ending at (X2, Y2).
Optional argument ATTRIBUTES contain conses with SVG attributes."
- [elpa] branch externals/svg-clock created (now 039aac6), Stefan Monnier, 2020/12/01
- [elpa] externals/svg-clock ba6878a 03/18: Added Version to svg-clock.el, Stefan Monnier, 2020/12/01
- [elpa] externals/svg-clock 039aac6 18/18: * .gitignore: New file, Stefan Monnier, 2020/12/01
- [elpa] externals/svg-clock d1aeadd 11/18: There's no longer an svg-def function in svg.el,
Stefan Monnier <=
- [elpa] externals/svg-clock ba28d97 09/18: Bump version number to 1.0 and make changes public, Stefan Monnier, 2020/12/01
- [elpa] externals/svg-clock 284d123 14/18: Fix requirements and version numbers, Stefan Monnier, 2020/12/01
- [elpa] externals/svg-clock ea9302b 07/18: * packages/svg-clock/svg-clock.el (svg-clock-do-update, svg-clock-start): Don't, Stefan Monnier, 2020/12/01
- [elpa] externals/svg-clock 3d9cd0e 15/18: Copy svg--def to manipulate the DOM directly from svg-clock.el, Stefan Monnier, 2020/12/01
- [elpa] externals/svg-clock 534946a 06/18: Fixed image-mode issue. Changed version to 0.5., Stefan Monnier, 2020/12/01
- [elpa] externals/svg-clock 03ea7e3 01/18: New package svg-clock., Stefan Monnier, 2020/12/01
- [elpa] externals/svg-clock 48454df 04/18: svg-clock: Disable buffer undo, Stefan Monnier, 2020/12/01
- [elpa] externals/svg-clock dc73e08 13/18: Allow controlling whether to show the seconds and the face, Stefan Monnier, 2020/12/01
- [elpa] externals/svg-clock 99c291f 02/18: 2011-09-26 Ulf Jasper <address@hidden>, Stefan Monnier, 2020/12/01
- [elpa] externals/svg-clock 5e4e62e 08/18: svg-clock.el: Refactoring. Use 'svg.el' and 'dom.el'., Stefan Monnier, 2020/12/01