Component used for adding CSS styling to SVG graphs.
In hindsight, ImageMagick and Mozilla SVG's handling of CSS styling is extremely inconsistant, so use this at your own risk.
# File lib/scruffy/components/style_info.rb, line 8 def initialize(*args) super @visible = false end
# File lib/scruffy/components/style_info.rb, line 13 def process(svg, options={}) svg.defs { svg.style(:type => "text/css") { svg.cdata!("\n#{options[:selector]} {\n #{options[:style]}\n}\n") } } end