svgle 0.4.5 → 0.4.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data.tar.gz.sig +0 -0
- data/lib/svgle.rb +24 -10
- metadata +25 -25
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0fb055aaee37ccc0fa5120270db02d20c030e42585c5734b9eb5e9016ec68a09
|
4
|
+
data.tar.gz: c628f66d2b9f4dbb4450cd4d39c187dac14083c89c77f6af3b5283f6c6b2ae18
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1d6e8ef0ad700fbfc9aa946d329b63c33145ddbda57f1b15a29ed5ebd32653ecdc8bbbbd253ca8fe4ff26a3744f2dd965f1ebb95ab7148150b3d0d8228ee6b39
|
7
|
+
data.tar.gz: 4cb552836d8ad8094dda484df33d111643a80fbe9b553f0a609b4681172e45ffa8046c03fb0406214f000bbffc47b9abbba366591f32c3eb52457be5f7cfbd8f
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data.tar.gz.sig
CHANGED
Binary file
|
data/lib/svgle.rb
CHANGED
@@ -28,7 +28,15 @@ CSS
|
|
28
28
|
|
29
29
|
|
30
30
|
class Svgle < Domle
|
31
|
+
|
32
|
+
|
33
|
+
class SvgElement < Element
|
34
|
+
attr2_accessor *%i(stroke stroke-width)
|
35
|
+
end
|
31
36
|
|
37
|
+
class Shape < SvgElement
|
38
|
+
attr2_accessor *%i(fill)
|
39
|
+
end
|
32
40
|
|
33
41
|
class A < Element
|
34
42
|
# undecided how to implement this
|
@@ -36,14 +44,14 @@ class Svgle < Domle
|
|
36
44
|
#attr2_accessor *%i(href)
|
37
45
|
end
|
38
46
|
|
39
|
-
class Circle <
|
40
|
-
attr2_accessor *%i(cx cy r
|
47
|
+
class Circle < Shape
|
48
|
+
attr2_accessor *%i(cx cy r)
|
41
49
|
def boundary()
|
42
50
|
[0,0,0,0]
|
43
51
|
end
|
44
52
|
end
|
45
53
|
|
46
|
-
class Ellipse <
|
54
|
+
class Ellipse < Shape
|
47
55
|
attr2_accessor *%i(cx cy rx ry)
|
48
56
|
def boundary()
|
49
57
|
[0,0,0,0]
|
@@ -57,7 +65,7 @@ class Svgle < Domle
|
|
57
65
|
end
|
58
66
|
end
|
59
67
|
|
60
|
-
class Line <
|
68
|
+
class Line < SvgElement
|
61
69
|
attr2_accessor *%i(x1 y1 x2 y2)
|
62
70
|
|
63
71
|
def boundary()
|
@@ -93,30 +101,30 @@ class Svgle < Domle
|
|
93
101
|
|
94
102
|
end
|
95
103
|
|
96
|
-
class Path <
|
97
|
-
attr2_accessor *%i(d
|
104
|
+
class Path < Shape
|
105
|
+
attr2_accessor *%i(d)
|
98
106
|
def boundary()
|
99
107
|
[0,0,0,0]
|
100
108
|
end
|
101
109
|
end
|
102
110
|
|
103
|
-
class Polygon <
|
111
|
+
class Polygon < Shape
|
104
112
|
attr2_accessor *%i(points)
|
105
113
|
def boundary()
|
106
114
|
[0,0,0,0]
|
107
115
|
end
|
108
116
|
end
|
109
117
|
|
110
|
-
class Polyline <
|
118
|
+
class Polyline < Shape
|
111
119
|
attr2_accessor *%i(points)
|
112
120
|
def boundary()
|
113
121
|
[0,0,0,0]
|
114
122
|
end
|
115
123
|
end
|
116
124
|
|
117
|
-
class Rect <
|
125
|
+
class Rect < Shape
|
118
126
|
|
119
|
-
attr2_accessor *%i(x y
|
127
|
+
attr2_accessor *%i(x y rx ry)
|
120
128
|
|
121
129
|
def boundary()
|
122
130
|
x1, y1, w, h = [x, y, width, height].map(&:to_i)
|
@@ -131,6 +139,7 @@ class Svgle < Domle
|
|
131
139
|
[0,0,0,0]
|
132
140
|
end
|
133
141
|
end
|
142
|
+
|
134
143
|
|
135
144
|
class Text < Element
|
136
145
|
attr2_accessor *%i(x y fill)
|
@@ -139,6 +148,10 @@ class Svgle < Domle
|
|
139
148
|
end
|
140
149
|
end
|
141
150
|
|
151
|
+
def initialize(src='<svg/>', callback: nil, rexle: self, debug: false)
|
152
|
+
super(src, callback: callback, rexle: rexle, debug: debug)
|
153
|
+
end
|
154
|
+
|
142
155
|
def inspect()
|
143
156
|
"#<Svgle:%s>" % [self.object_id]
|
144
157
|
end
|
@@ -148,6 +161,7 @@ class Svgle < Domle
|
|
148
161
|
|
149
162
|
def add_default_css()
|
150
163
|
add_css DEFAULT_CSS
|
164
|
+
add_inline_css()
|
151
165
|
end
|
152
166
|
|
153
167
|
private
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: svgle
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- James Robertson
|
@@ -11,31 +11,31 @@ cert_chain:
|
|
11
11
|
- |
|
12
12
|
-----BEGIN CERTIFICATE-----
|
13
13
|
MIIEXjCCAsagAwIBAgIBATANBgkqhkiG9w0BAQsFADAsMSowKAYDVQQDDCFnZW1t
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
/
|
14
|
+
YXN0ZXIvREM9amFtZXNyb2JlcnRzb24vREM9ZXUwHhcNMjAwNTEyMDczMTQ5WhcN
|
15
|
+
MjEwNTEyMDczMTQ5WjAsMSowKAYDVQQDDCFnZW1tYXN0ZXIvREM9amFtZXNyb2Jl
|
16
|
+
cnRzb24vREM9ZXUwggGiMA0GCSqGSIb3DQEBAQUAA4IBjwAwggGKAoIBgQDL0+Nu
|
17
|
+
UR8FU++JIrWuTr2nTuzgVgUA+x+TmpVuVOnh9Tl9hvNi/P8/KXarLZhIVE5Avl07
|
18
|
+
y+5JpR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DCe21kMITmMu0QbFj2QicSwfEBHDO2gy0
|
32
|
+
mRj4WgPd7nCIjy81BtItELhQzoAtxoBgahAlX8V0yPo5eHCzJP/oXucrkP7i6IC7
|
33
|
+
4D9+g3UMzF8+t+yKNgkJuE76azBKyfEKJnhYGnEOI9nIVfmxc65CBjzi13D1pLr1
|
34
|
+
gmp68bAqiT60sJfRlJtEtTKkdcQtPVKj4NPYAt+QItdUKNx9xuBmIZpYmpQnbdrN
|
35
|
+
NIUWaOW01S4o47sU3I51CSMWxo0LvDUyjQ5BahXzrnkaUCAZxlAAIqXum9zvCr5K
|
36
|
+
qG+QACUIuvQdA+C3SKv19pE2
|
37
37
|
-----END CERTIFICATE-----
|
38
|
-
date:
|
38
|
+
date: 2020-05-12 00:00:00.000000000 Z
|
39
39
|
dependencies:
|
40
40
|
- !ruby/object:Gem::Dependency
|
41
41
|
name: domle
|
@@ -83,7 +83,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
83
83
|
- !ruby/object:Gem::Version
|
84
84
|
version: '0'
|
85
85
|
requirements: []
|
86
|
-
rubygems_version: 3.0.
|
86
|
+
rubygems_version: 3.0.3
|
87
87
|
signing_key:
|
88
88
|
specification_version: 4
|
89
89
|
summary: Svgle (SVG + Domle) generates an SVG Document Object Model from the given
|
metadata.gz.sig
CHANGED
Binary file
|