Module: SVGen::Nestable
- Included in:
- Element::Group, SVG
- Defined in:
- lib/svgen/nestable.rb
Instance Method Summary collapse
- #circle(attrs = {}) ⇒ Object
- #group(attrs = {}, &block) ⇒ Object (also: #g)
- #line(attrs = {}) ⇒ Object
- #path(attrs = {}) ⇒ Object
- #rect(attrs = {}) ⇒ Object
- #text(text, attrs = {}) ⇒ Object
Instance Method Details
#circle(attrs = {}) ⇒ Object
7 8 9 |
# File 'lib/svgen/nestable.rb', line 7 def circle(attrs = {}) @children << Element::Circle.new(attrs) end |
#group(attrs = {}, &block) ⇒ Object Also known as: g
23 24 25 |
# File 'lib/svgen/nestable.rb', line 23 def group(attrs = {}, &block) @children << Element::Group.new(attrs, &block) end |
#line(attrs = {}) ⇒ Object
15 16 17 |
# File 'lib/svgen/nestable.rb', line 15 def line(attrs = {}) @children << Element::Line.new(attrs) end |
#path(attrs = {}) ⇒ Object
19 20 21 |
# File 'lib/svgen/nestable.rb', line 19 def path(attrs = {}) @children << Element::Path.new(attrs) end |