module SVGen::Nestable

Public Instance Methods

circle(attrs = {}) click to toggle source
# File lib/svgen/nestable.rb, line 7
def circle(attrs = {})
  @children << Element::Circle.new(attrs)
end
g(attrs = {}, &block)
Alias for: group
group(attrs = {}, &block) click to toggle source
# File lib/svgen/nestable.rb, line 23
def group(attrs = {}, &block)
  @children << Element::Group.new(attrs, &block)
end
Also aliased as: g
line(attrs = {}) click to toggle source
# File lib/svgen/nestable.rb, line 15
def line(attrs = {})
  @children << Element::Line.new(attrs)
end
path(attrs = {}) click to toggle source
# File lib/svgen/nestable.rb, line 19
def path(attrs = {})
  @children << Element::Path.new(attrs)
end
rect(attrs = {}) click to toggle source
# File lib/svgen/nestable.rb, line 3
def rect(attrs = {})
  @children << Element::Rect.new(attrs)
end
text(text, attrs = {}) click to toggle source
# File lib/svgen/nestable.rb, line 11
def text(text, attrs = {})
  @children << Element::Text.new(text, attrs)
end