Class: Svg::Feature

Inherits:
Object
  • Object
show all
Defined in:
lib/svg.rb

Direct Known Subclasses

Circle, Rectangle

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#fillObject

Returns the value of attribute fill.



48
49
50
# File 'lib/svg.rb', line 48

def fill
  @fill
end

#fill_opacityObject

Returns the value of attribute fill_opacity.



48
49
50
# File 'lib/svg.rb', line 48

def fill_opacity
  @fill_opacity
end

#strokeObject

Returns the value of attribute stroke.



48
49
50
# File 'lib/svg.rb', line 48

def stroke
  @stroke
end

#stroke_opacityObject

Returns the value of attribute stroke_opacity.



48
49
50
# File 'lib/svg.rb', line 48

def stroke_opacity
  @stroke_opacity
end

#stroke_widthObject

Returns the value of attribute stroke_width.



48
49
50
# File 'lib/svg.rb', line 48

def stroke_width
  @stroke_width
end

#styleObject

Returns the value of attribute style.



48
49
50
# File 'lib/svg.rb', line 48

def style
  @style
end

Instance Method Details

#attr_to_s(attr_name, attr_val) ⇒ Object



53
54
55
56
# File 'lib/svg.rb', line 53

def attr_to_s (attr_name, attr_val)
  return '' if attr_val.nil? 
  " #{attr_name}=\"#{attr_val}\"" if not attr_val.to_s.empty?
end

#to_svgObject



49
50
51
# File 'lib/svg.rb', line 49

def to_svg
  '<overrideme/>'
end