victor 0.2.2 → 0.2.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8084c65a136f58070a350341405ef047bc7b3dfd282fec474223598ee7889f12
4
- data.tar.gz: 2112d671dadbe7c6e7f1f4a78adad9c6cd24512ba3bdddcd641574e2fd218ad4
3
+ metadata.gz: f0a520dfbed8f1278e8bcf7656ff0afabb7b6568c3ac3d5a5ce08c356b187c4d
4
+ data.tar.gz: 61e89f8a1da9d831bf158333f7136c1c4b6faccf937daa8d8971d908f6731fd3
5
5
  SHA512:
6
- metadata.gz: 7c3dc90b9f50060eeb447d1bbe5d54badcf5fff046ee91cea74cc487e0c58f37420e208d1d41b307bc80c4b67a3719f490012417a2deef76d02ba71f144599ab
7
- data.tar.gz: 6665e0d722a7c4ffb70497ea884cf83223a5327fe3e68b498b1ea086b0fd9145377f41f7584a62c351886a6e2dfd4c1e834b68cc0243e5af71c24fbca7037318
6
+ metadata.gz: 651b37bf06b3d54b5f8528620821cd48fc81ea86d8fab7f9ab5391ad0d2f441c2dacc21d56edbd4f259c759aaf2224c29852516c31fff840e99f66855080c545
7
+ data.tar.gz: 122c24b8734c02b21351a06da76373c9b899bda89f738d04613f6d4c5267fc62d8b583bf9afaa127d2b1b793583610e5e660930261a0375f51f97c53ef0cc5c7
data/README.md CHANGED
@@ -174,8 +174,9 @@ svg.text "Victor", x: 40, y: 50, font_family: 'arial', font_weight: 'bold', font
174
174
  Composite SVG
175
175
  --------------------------------------------------
176
176
  Victor also supports the abiliy to combine several smaller SVG objects into
177
- one using the `<<` operator. This operator expects to receive any object
178
- that responds to `#to_s` (can be another `SVG` object).
177
+ one using the `<<` operator or the `#append` method.
178
+
179
+ This operator expects to receive any object that responds to `#to_s` (can be another `SVG` object).
179
180
 
180
181
  ```ruby
181
182
  require 'victor'
@@ -204,6 +205,13 @@ Output:
204
205
 
205
206
  [![troll](https://cdn.rawgit.com/DannyBen/victor/master/examples/13_composite_svg.svg)](https://cdn.rawgit.com/DannyBen/victor/master/examples/13_composite_svg.svg)
206
207
 
208
+ These two calls are identical:
209
+
210
+ ```ruby
211
+ svg << other
212
+ svg.append other
213
+ ```
214
+
207
215
  Another approach to a more modular SVG composition, would be to subclass
208
216
  `Victor::SVG`.
209
217
 
@@ -22,6 +22,7 @@ module Victor
22
22
  def <<(additional_content)
23
23
  content.push additional_content.to_s
24
24
  end
25
+ alias append <<
25
26
 
26
27
  def build(&block)
27
28
  self.instance_eval(&block)
@@ -1,3 +1,3 @@
1
1
  module Victor
2
- VERSION = "0.2.2"
2
+ VERSION = "0.2.3"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: victor
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Danny Ben Shitrit
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-07-31 00:00:00.000000000 Z
11
+ date: 2018-08-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: runfile