# File lib/compass/sass_extensions/sprites/engines/chunky_png_engine.rb, line 12 def construct_sprite @canvas = ChunkyPNG::Image.new(width, height, ChunkyPNG::Color::TRANSPARENT) images.each do |image| input_png = begin ChunkyPNG::Image.from_file(image.file) rescue ChunkyPNG::SignatureMismatch raise Compass::SpriteException, "You have provided a file that does not have a PNG signature. Only PNG files are supported by the default sprite engine" end canvas.replace! input_png, image.left, image.top end end
Generated with the Darkfish Rdoc Generator 2.