prawn-svg 0.23.1 → 0.24.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. checksums.yaml +4 -4
  2. data/.travis.yml +3 -3
  3. data/README.md +15 -9
  4. data/lib/prawn-svg.rb +3 -0
  5. data/lib/prawn/svg/attributes.rb +1 -1
  6. data/lib/prawn/svg/attributes/clip_path.rb +6 -7
  7. data/lib/prawn/svg/attributes/opacity.rb +3 -3
  8. data/lib/prawn/svg/attributes/stroke.rb +6 -4
  9. data/lib/prawn/svg/calculators/arc_to_bezier_curve.rb +114 -0
  10. data/lib/prawn/svg/elements.rb +4 -1
  11. data/lib/prawn/svg/elements/base.rb +76 -69
  12. data/lib/prawn/svg/elements/container.rb +5 -6
  13. data/lib/prawn/svg/elements/gradient.rb +4 -4
  14. data/lib/prawn/svg/elements/image.rb +1 -1
  15. data/lib/prawn/svg/elements/line.rb +15 -7
  16. data/lib/prawn/svg/elements/marker.rb +72 -0
  17. data/lib/prawn/svg/elements/path.rb +23 -147
  18. data/lib/prawn/svg/elements/polygon.rb +14 -6
  19. data/lib/prawn/svg/elements/polyline.rb +12 -11
  20. data/lib/prawn/svg/elements/root.rb +3 -1
  21. data/lib/prawn/svg/elements/text.rb +38 -17
  22. data/lib/prawn/svg/font.rb +6 -6
  23. data/lib/prawn/svg/interface.rb +3 -0
  24. data/lib/prawn/svg/pathable.rb +130 -0
  25. data/lib/prawn/svg/properties.rb +122 -0
  26. data/lib/prawn/svg/state.rb +7 -29
  27. data/lib/prawn/svg/version.rb +1 -1
  28. data/spec/prawn/svg/elements/base_spec.rb +19 -32
  29. data/spec/prawn/svg/elements/line_spec.rb +37 -0
  30. data/spec/prawn/svg/elements/marker_spec.rb +90 -0
  31. data/spec/prawn/svg/elements/path_spec.rb +10 -10
  32. data/spec/prawn/svg/elements/polygon_spec.rb +49 -0
  33. data/spec/prawn/svg/elements/polyline_spec.rb +47 -0
  34. data/spec/prawn/svg/elements/style_spec.rb +1 -1
  35. data/spec/prawn/svg/elements/text_spec.rb +37 -5
  36. data/spec/prawn/svg/pathable_spec.rb +92 -0
  37. data/spec/prawn/svg/properties_spec.rb +186 -0
  38. data/spec/sample_svg/arrows.svg +73 -0
  39. data/spec/sample_svg/marker.svg +32 -0
  40. data/spec/sample_svg/polygon01.svg +25 -5
  41. metadata +23 -8
  42. data/lib/prawn/svg/attributes/color.rb +0 -5
  43. data/lib/prawn/svg/attributes/display.rb +0 -5
  44. data/lib/prawn/svg/attributes/font.rb +0 -38
  45. data/spec/prawn/svg/attributes/font_spec.rb +0 -52
@@ -0,0 +1,92 @@
1
+ require 'spec_helper'
2
+
3
+ RSpec.describe Prawn::SVG::Pathable do
4
+ class FakeElement < Prawn::SVG::Elements::Base
5
+ include Prawn::SVG::Pathable
6
+
7
+ def initialize(*args)
8
+ super
9
+ @properties = Struct.new(:marker_start, :marker_mid, :marker_end).new
10
+ end
11
+
12
+ public :apply_commands
13
+ public :apply_markers
14
+
15
+ def commands
16
+ @commands ||= [
17
+ Prawn::SVG::Pathable::Move.new([10, 10]),
18
+ Prawn::SVG::Pathable::Line.new([20, 20]),
19
+ Prawn::SVG::Pathable::Curve.new([30, 30], [25, 20], [25, 25]),
20
+ Prawn::SVG::Pathable::Close.new([10, 10])
21
+ ]
22
+ end
23
+ end
24
+
25
+ let(:document) { Prawn::SVG::Document.new("<svg></svg>", [800, 600], {width: 800, height: 600}) }
26
+ let(:state) { Prawn::SVG::State.new }
27
+
28
+ subject do
29
+ FakeElement.new(document, document.root, [], state)
30
+ end
31
+
32
+ describe "#bounding_box" do
33
+ it "determines the bounding box using the translated commands" do
34
+ expect(subject.bounding_box).to eq [10, 590, 30, 570]
35
+ end
36
+ end
37
+
38
+ describe "#apply_commands" do
39
+ it "applies the commands to the call stack" do
40
+ subject.apply_commands
41
+
42
+ expect(subject.base_calls).to eq [
43
+ ["move_to", [[10.0, 590.0]], []],
44
+ ["line_to", [[20.0, 580.0]], []],
45
+ ["curve_to", [[30.0, 570.0], {bounds: [[25.0, 580.0], [25.0, 575.0]]}], []],
46
+ ["close_path", [], []]
47
+ ]
48
+ end
49
+ end
50
+
51
+ describe "#apply_markers" do
52
+ let(:marker) { instance_double(Prawn::SVG::Elements::Marker, name: "marker") }
53
+
54
+ before do
55
+ document.elements_by_id["triangle"] = marker
56
+ end
57
+
58
+ context "with marker-start attribute specified" do
59
+ before do
60
+ subject.properties.marker_start = "url(#triangle)"
61
+ end
62
+
63
+ it "calls apply_marker on the marker" do
64
+ expect(marker).to receive(:apply_marker).with(subject, point: [10, 10], angle: 45)
65
+ subject.apply_markers
66
+ end
67
+ end
68
+
69
+ context "with marker-mid attribute specified" do
70
+ before do
71
+ subject.properties.marker_mid = "url(#triangle)"
72
+ end
73
+
74
+ it "calls apply_marker on the marker" do
75
+ expect(marker).to receive(:apply_marker).with(subject, point: [20, 20], angle: 45)
76
+ expect(marker).to receive(:apply_marker).with(subject, point: [30, 30], angle: -45)
77
+ subject.apply_markers
78
+ end
79
+ end
80
+
81
+ context "with marker-end attribute specified" do
82
+ before do
83
+ subject.properties.marker_end = "url(#triangle)"
84
+ end
85
+
86
+ it "calls apply_marker on the marker" do
87
+ expect(marker).to receive(:apply_marker).with(subject, point: [10, 10], angle: -45)
88
+ subject.apply_markers
89
+ end
90
+ end
91
+ end
92
+ end
@@ -0,0 +1,186 @@
1
+ require 'spec_helper'
2
+
3
+ RSpec.describe Prawn::SVG::Properties do
4
+ subject { Prawn::SVG::Properties.new }
5
+
6
+ describe "#load_default_stylesheet" do
7
+ it "loads in the defaults and returns self" do
8
+ expect(subject.load_default_stylesheet).to eq subject
9
+ expect(subject.font_family).to eq 'sans-serif'
10
+ end
11
+ end
12
+
13
+ describe "#set" do
14
+ it "sets a property" do
15
+ result = subject.set('color', 'red')
16
+ expect(result).to be
17
+ expect(subject.color).to eq 'red'
18
+ end
19
+
20
+ it "handles property names that are not lower case" do
21
+ result = subject.set('COLor', 'red')
22
+ expect(result).to be
23
+ expect(subject.color).to eq 'red'
24
+ end
25
+
26
+ it "right-cases and strips keywords" do
27
+ subject.set('stroke-linecap', ' Round ')
28
+ expect(subject.stroke_linecap).to eq 'round'
29
+ end
30
+
31
+ it "doesn't right-case values that aren't recognised as keywords" do
32
+ subject.set('color', 'Red')
33
+ expect(subject.color).to eq 'Red'
34
+ end
35
+
36
+ it "sets a 'keyword restricted' property to its default if the value doesn't match a keyword" do
37
+ subject.set('stroke-linecap', 'invalid')
38
+ expect(subject.stroke_linecap).to eq 'butt'
39
+ end
40
+ end
41
+
42
+ describe "#load_hash" do
43
+ it "uses #set to load in a hash of properties" do
44
+ subject.load_hash("stroke" => "blue", "fill" => "green", 'stroke-linecap' => "Round")
45
+ expect(subject.stroke).to eq 'blue'
46
+ expect(subject.fill).to eq 'green'
47
+ expect(subject.stroke_linecap).to eq 'round'
48
+ end
49
+ end
50
+
51
+ describe "#compute_properties" do
52
+ let(:other) { Prawn::SVG::Properties.new }
53
+
54
+ it "auto-inherits inheritable properties when the property is not supplied" do
55
+ subject.set('color', 'green')
56
+ subject.compute_properties(other)
57
+ expect(subject.color).to eq 'green'
58
+ end
59
+
60
+ it "doesn't auto-inherit non-inheritable properties" do
61
+ subject.set('display', 'none')
62
+ subject.compute_properties(other)
63
+ expect(subject.display).to eq 'inline'
64
+ end
65
+
66
+ it "inherits non-inheritable properties when specifically asked to" do
67
+ subject.set('display', 'none')
68
+ other.set('display', 'inherit')
69
+ subject.compute_properties(other)
70
+ expect(subject.display).to eq 'none'
71
+ end
72
+
73
+ it "uses the new property value" do
74
+ subject.set('color', 'green')
75
+ other.set('color', 'red')
76
+ subject.compute_properties(other)
77
+ expect(subject.color).to eq 'red'
78
+ end
79
+
80
+ describe "font size" do
81
+ before do
82
+ subject.font_size = "15"
83
+ other.font_size = font_size
84
+ end
85
+
86
+ context "when given a % as a font-size" do
87
+ let(:font_size) { "120%" }
88
+
89
+ it "calculates the new font size" do
90
+ subject.compute_properties(other)
91
+ expect(subject.font_size).to eq "18.0"
92
+ end
93
+ end
94
+
95
+ context "when given 'larger' as a font-size" do
96
+ let(:font_size) { "larger" }
97
+
98
+ it "calculates the new font size" do
99
+ subject.compute_properties(other)
100
+ expect(subject.font_size).to eq "19.0"
101
+ end
102
+ end
103
+
104
+ context "when given 'smaller' as a font-size" do
105
+ let(:font_size) { "smaller" }
106
+
107
+ it "calculates the new font size" do
108
+ subject.compute_properties(other)
109
+ expect(subject.font_size).to eq "11.0"
110
+ end
111
+ end
112
+
113
+ context "when given a value in 'em' as a font-size" do
114
+ let(:font_size) { "2.5em" }
115
+
116
+ it "calculates the new font size" do
117
+ subject.compute_properties(other)
118
+ expect(subject.font_size).to eq "37.5"
119
+ end
120
+ end
121
+
122
+ context "when given a value in 'rem' as a font-size" do
123
+ let(:font_size) { "2.5rem" }
124
+
125
+ it "calculates the new font size" do
126
+ subject.compute_properties(other)
127
+ expect(subject.font_size).to eq "40.0"
128
+ end
129
+ end
130
+
131
+ context "when given a value in 'px' as a font-size" do
132
+ let(:font_size) { "19.5px" }
133
+
134
+ it "uses the font size specified" do
135
+ subject.compute_properties(other)
136
+ expect(subject.font_size).to eq "19.5"
137
+ end
138
+ end
139
+
140
+ context "when given a value in 'pt' as a font-size" do
141
+ let(:font_size) { "19.5pt" }
142
+
143
+ it "uses the font size specified" do
144
+ subject.compute_properties(other)
145
+ expect(subject.font_size).to eq "19.5"
146
+ end
147
+ end
148
+
149
+ context "when given a value without units as a font-size" do
150
+ let(:font_size) { "19.5" }
151
+
152
+ it "uses the font size specified" do
153
+ subject.compute_properties(other)
154
+ expect(subject.font_size).to eq "19.5"
155
+ end
156
+ end
157
+
158
+ context "when given the keyword 'inherit' as a font-size" do
159
+ let(:font_size) { "inherit" }
160
+
161
+ it "uses the font size specified by the parent" do
162
+ subject.compute_properties(other)
163
+ expect(subject.font_size).to eq "15"
164
+ end
165
+ end
166
+ end
167
+ end
168
+
169
+ describe "#numerical_font_size" do
170
+ context "when the font size is a number" do
171
+ before { subject.font_size = "16.5" }
172
+
173
+ it "returns the number as a float" do
174
+ expect(subject.numerical_font_size).to eq 16.5
175
+ end
176
+ end
177
+
178
+ context "when the font size is one of the keyword size specifiers" do
179
+ before { subject.font_size = "x-large" }
180
+
181
+ it "returns the font size number corresponding with the keyword" do
182
+ expect(subject.numerical_font_size).to eq 24
183
+ end
184
+ end
185
+ end
186
+ end
@@ -0,0 +1,73 @@
1
+ <?xml version="1.0" encoding="UTF-8" standalone="no"?>
2
+ <!-- Created with Inkscape (http://www.inkscape.org/) -->
3
+
4
+ <svg
5
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
6
+ xmlns:cc="http://creativecommons.org/ns#"
7
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
8
+ xmlns:svg="http://www.w3.org/2000/svg"
9
+ xmlns="http://www.w3.org/2000/svg"
10
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
11
+ width="200"
12
+ height="200"
13
+ id="svg2"
14
+ version="1.1">
15
+ <defs
16
+ id="defs4">
17
+ <marker
18
+ style="overflow:visible;"
19
+ id="Arrow1Lend"
20
+ refX="0.0"
21
+ refY="0.0"
22
+ orient="auto"
23
+ inkscape:stockid="Arrow1Lend">
24
+ <path
25
+ transform="scale(0.8) rotate(180) translate(12.5,0)"
26
+ style="fill-rule:evenodd;stroke:#000000;stroke-width:1.0pt;"
27
+ d="M 0.0,0.0 L 5.0,-5.0 L -12.5,0.0 L 5.0,5.0 L 0.0,0.0 z "
28
+ id="path3762" />
29
+ </marker>
30
+ <marker
31
+ style="overflow:visible;"
32
+ id="Arrow1LendK"
33
+ refX="0.0"
34
+ refY="0.0"
35
+ orient="auto"
36
+ inkscape:stockid="Arrow1LendK">
37
+ <path
38
+ transform="scale(0.8) rotate(180) translate(12.5,0)"
39
+ style="stroke:#ff0000;stroke-width:1.0pt;fill:#ff0000;fill-rule:evenodd"
40
+ d="M 0.0,0.0 L 5.0,-5.0 L -12.5,0.0 L 5.0,5.0 L 0.0,0.0 z "
41
+ id="path4230" />
42
+ </marker>
43
+ </defs>
44
+ <metadata
45
+ id="metadata7">
46
+ <rdf:RDF>
47
+ <cc:Work
48
+ rdf:about="">
49
+ <dc:format>image/svg+xml</dc:format>
50
+ <dc:type
51
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
52
+ <dc:title></dc:title>
53
+ </cc:Work>
54
+ </rdf:RDF>
55
+ </metadata>
56
+ <g
57
+ transform="translate(0,-852.36218)"
58
+ id="layer1"
59
+ inkscape:groupmode="layer"
60
+ inkscape:label="Layer 1">
61
+ <path
62
+ transform="translate(0,852.36218)"
63
+ inkscape:connector-curvature="0"
64
+ id="path2985"
65
+ d="M 26.263966,144.94669 122.22846,94.439059"
66
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow1Lend)" />
67
+ <path
68
+ inkscape:connector-curvature="0"
69
+ id="path2985-7"
70
+ d="M 40.406101,953.8723 136.3706,903.36467"
71
+ style="stroke-linejoin:miter;marker-end:url(#Arrow1LendK);stroke-opacity:1;stroke:#ff0000;stroke-linecap:butt;stroke-width:1px;fill:#ff0000" />
72
+ </g>
73
+ </svg>
@@ -0,0 +1,32 @@
1
+ <?xml version="1.0" standalone="no"?>
2
+ <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
3
+ "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
4
+ <svg width="4in" height="2in"
5
+ viewBox="0 0 4000 2000" version="1.1"
6
+ xmlns="http://www.w3.org/2000/svg">
7
+ <defs>
8
+ <g stroke="red" fill="cyan" stroke-dasharray="3 3" stroke-opacity="0.5">
9
+ <marker id="Triangle"
10
+ viewBox="0 0 20 20" refX="0" refY="5"
11
+ markerUnits="strokeWidth"
12
+ markerWidth="4" markerHeight="3"
13
+ stroke-width="4"
14
+ fill="blue"
15
+ orient="auto">
16
+ <path d="M 0 0 L 20 5 L 0 10 z" />
17
+ </marker>
18
+ </g>
19
+ </defs>
20
+ <rect x="10" y="10" width="3980" height="1980" fill="none" stroke="blue" stroke-width="10" />
21
+ <path d="M 1000 750 L 2000 750 L 2500 1250"
22
+ fill="none" stroke="green" stroke-width="100"
23
+ marker-mid="url(#Triangle)" />
24
+
25
+ <g transform="scale(12) translate(50 40)">
26
+ <path d="M10 80 Q 52.5 10, 95 80 L 115 80 T 180 80" stroke="yellow" fill="none" stroke-width="8"
27
+ marker-start="url(#Triangle)"
28
+ marker-mid="url(#Triangle)"
29
+ marker-end="url(#Triangle)" />
30
+ </g>
31
+
32
+ </svg>
@@ -1,17 +1,37 @@
1
1
  <?xml version="1.0" standalone="no"?>
2
- <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
2
+ <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
3
3
  "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
4
4
  <svg width="12cm" height="4cm" viewBox="0 0 1200 400"
5
5
  xmlns="http://www.w3.org/2000/svg" version="1.1">
6
+ <defs>
7
+ <marker id="a"
8
+ viewBox="0 0 20 20" refX="0" refY="5"
9
+ markerUnits="strokeWidth"
10
+ markerWidth="4" markerHeight="3"
11
+ orient="auto">
12
+ <path d="M 0 0 L 20 5 L 0 10 z" fill="yellow" />
13
+ </marker>
14
+ <marker id="Triangle"
15
+ viewBox="0 0 20 20" refX="0" refY="5"
16
+ markerUnits="strokeWidth"
17
+ markerWidth="4" markerHeight="3"
18
+ orient="auto">
19
+ <path d="M 0 0 L 20 5 L 0 10 z" />
20
+ </marker>
21
+ <g stroke="red" fill="none" stroke-dasharray="3 3" stroke-opacity="0.3">
22
+ </g>
23
+ </defs>
6
24
  <desc>Example polygon01 - star and hexagon</desc>
7
25
  <!-- Show outline of canvas using 'rect' element -->
8
26
  <rect x="1" y="1" width="1198" height="398"
9
27
  fill="none" stroke="blue" stroke-width="2" />
10
- <polygon fill="red" stroke="blue" stroke-width="10"
28
+ <polygon fill="red" stroke="blue" stroke-width="10"
11
29
  points="350,75 379,161 469,161 397,215
12
30
  423,301 350,250 277,301 303,215
13
- 231,161 321,161" />
14
- <polygon fill="lime" stroke="blue" stroke-width="10"
31
+ 231,161 321,161"
32
+ marker-mid="url(#Triangle)" marker-start="url(#a)" marker-end="url(#a)" />
33
+ <polygon fill="lime" stroke="blue" stroke-width="10"
15
34
  points="850,75 958,137.5 958,262.5
16
- 850,325 742,262.6 742,137.5" />
35
+ 850,325 742,262.6 742,137.5"
36
+ marker-mid="url(#Triangle)" marker-start="url(#a)" marker-end="url(#a)" />
17
37
  </svg>
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: prawn-svg
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.23.1
4
+ version: 0.24.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Roger Nesbitt
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-04-02 00:00:00.000000000 Z
11
+ date: 2016-04-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: prawn
@@ -90,12 +90,10 @@ files:
90
90
  - lib/prawn-svg.rb
91
91
  - lib/prawn/svg/attributes.rb
92
92
  - lib/prawn/svg/attributes/clip_path.rb
93
- - lib/prawn/svg/attributes/color.rb
94
- - lib/prawn/svg/attributes/display.rb
95
- - lib/prawn/svg/attributes/font.rb
96
93
  - lib/prawn/svg/attributes/opacity.rb
97
94
  - lib/prawn/svg/attributes/stroke.rb
98
95
  - lib/prawn/svg/attributes/transform.rb
96
+ - lib/prawn/svg/calculators/arc_to_bezier_curve.rb
99
97
  - lib/prawn/svg/calculators/aspect_ratio.rb
100
98
  - lib/prawn/svg/calculators/document_sizing.rb
101
99
  - lib/prawn/svg/calculators/pixels.rb
@@ -111,6 +109,7 @@ files:
111
109
  - lib/prawn/svg/elements/ignored.rb
112
110
  - lib/prawn/svg/elements/image.rb
113
111
  - lib/prawn/svg/elements/line.rb
112
+ - lib/prawn/svg/elements/marker.rb
114
113
  - lib/prawn/svg/elements/path.rb
115
114
  - lib/prawn/svg/elements/polygon.rb
116
115
  - lib/prawn/svg/elements/polyline.rb
@@ -126,13 +125,14 @@ files:
126
125
  - lib/prawn/svg/loaders/data.rb
127
126
  - lib/prawn/svg/loaders/file.rb
128
127
  - lib/prawn/svg/loaders/web.rb
128
+ - lib/prawn/svg/pathable.rb
129
+ - lib/prawn/svg/properties.rb
129
130
  - lib/prawn/svg/state.rb
130
131
  - lib/prawn/svg/ttf.rb
131
132
  - lib/prawn/svg/url_loader.rb
132
133
  - lib/prawn/svg/version.rb
133
134
  - prawn-svg.gemspec
134
135
  - spec/integration_spec.rb
135
- - spec/prawn/svg/attributes/font_spec.rb
136
136
  - spec/prawn/svg/attributes/transform_spec.rb
137
137
  - spec/prawn/svg/calculators/aspect_ratio_spec.rb
138
138
  - spec/prawn/svg/calculators/document_sizing_spec.rb
@@ -141,7 +141,11 @@ files:
141
141
  - spec/prawn/svg/document_spec.rb
142
142
  - spec/prawn/svg/elements/base_spec.rb
143
143
  - spec/prawn/svg/elements/gradient_spec.rb
144
+ - spec/prawn/svg/elements/line_spec.rb
145
+ - spec/prawn/svg/elements/marker_spec.rb
144
146
  - spec/prawn/svg/elements/path_spec.rb
147
+ - spec/prawn/svg/elements/polygon_spec.rb
148
+ - spec/prawn/svg/elements/polyline_spec.rb
145
149
  - spec/prawn/svg/elements/style_spec.rb
146
150
  - spec/prawn/svg/elements/text_spec.rb
147
151
  - spec/prawn/svg/font_registry_spec.rb
@@ -150,12 +154,15 @@ files:
150
154
  - spec/prawn/svg/loaders/data_spec.rb
151
155
  - spec/prawn/svg/loaders/file_spec.rb
152
156
  - spec/prawn/svg/loaders/web_spec.rb
157
+ - spec/prawn/svg/pathable_spec.rb
158
+ - spec/prawn/svg/properties_spec.rb
153
159
  - spec/prawn/svg/ttf_spec.rb
154
160
  - spec/prawn/svg/url_loader_spec.rb
155
161
  - spec/sample_images/mushroom-long.jpg
156
162
  - spec/sample_images/mushroom-wide.jpg
157
163
  - spec/sample_output/directory
158
164
  - spec/sample_svg/arcs01.svg
165
+ - spec/sample_svg/arrows.svg
159
166
  - spec/sample_svg/cap_styles.svg
160
167
  - spec/sample_svg/circle01.svg
161
168
  - spec/sample_svg/clip_path.svg
@@ -174,6 +181,7 @@ files:
174
181
  - spec/sample_svg/image02_base64.svg
175
182
  - spec/sample_svg/image03.svg
176
183
  - spec/sample_svg/line01.svg
184
+ - spec/sample_svg/marker.svg
177
185
  - spec/sample_svg/maths.svg
178
186
  - spec/sample_svg/matrix_transform.svg
179
187
  - spec/sample_svg/matrix_transform_3.svg
@@ -225,13 +233,12 @@ required_rubygems_version: !ruby/object:Gem::Requirement
225
233
  version: '0'
226
234
  requirements: []
227
235
  rubyforge_project:
228
- rubygems_version: 2.2.2
236
+ rubygems_version: 2.5.1
229
237
  signing_key:
230
238
  specification_version: 4
231
239
  summary: SVG renderer for Prawn PDF library
232
240
  test_files:
233
241
  - spec/integration_spec.rb
234
- - spec/prawn/svg/attributes/font_spec.rb
235
242
  - spec/prawn/svg/attributes/transform_spec.rb
236
243
  - spec/prawn/svg/calculators/aspect_ratio_spec.rb
237
244
  - spec/prawn/svg/calculators/document_sizing_spec.rb
@@ -240,7 +247,11 @@ test_files:
240
247
  - spec/prawn/svg/document_spec.rb
241
248
  - spec/prawn/svg/elements/base_spec.rb
242
249
  - spec/prawn/svg/elements/gradient_spec.rb
250
+ - spec/prawn/svg/elements/line_spec.rb
251
+ - spec/prawn/svg/elements/marker_spec.rb
243
252
  - spec/prawn/svg/elements/path_spec.rb
253
+ - spec/prawn/svg/elements/polygon_spec.rb
254
+ - spec/prawn/svg/elements/polyline_spec.rb
244
255
  - spec/prawn/svg/elements/style_spec.rb
245
256
  - spec/prawn/svg/elements/text_spec.rb
246
257
  - spec/prawn/svg/font_registry_spec.rb
@@ -249,12 +260,15 @@ test_files:
249
260
  - spec/prawn/svg/loaders/data_spec.rb
250
261
  - spec/prawn/svg/loaders/file_spec.rb
251
262
  - spec/prawn/svg/loaders/web_spec.rb
263
+ - spec/prawn/svg/pathable_spec.rb
264
+ - spec/prawn/svg/properties_spec.rb
252
265
  - spec/prawn/svg/ttf_spec.rb
253
266
  - spec/prawn/svg/url_loader_spec.rb
254
267
  - spec/sample_images/mushroom-long.jpg
255
268
  - spec/sample_images/mushroom-wide.jpg
256
269
  - spec/sample_output/directory
257
270
  - spec/sample_svg/arcs01.svg
271
+ - spec/sample_svg/arrows.svg
258
272
  - spec/sample_svg/cap_styles.svg
259
273
  - spec/sample_svg/circle01.svg
260
274
  - spec/sample_svg/clip_path.svg
@@ -273,6 +287,7 @@ test_files:
273
287
  - spec/sample_svg/image02_base64.svg
274
288
  - spec/sample_svg/image03.svg
275
289
  - spec/sample_svg/line01.svg
290
+ - spec/sample_svg/marker.svg
276
291
  - spec/sample_svg/maths.svg
277
292
  - spec/sample_svg/matrix_transform.svg
278
293
  - spec/sample_svg/matrix_transform_3.svg