# File lib/png.rb, line 573 def to_s image = [] scale = (@width / 39) + 1 @data.each_with_index do |row, x| next if x % scale != 0 row.each_with_index do |color, y| next if y % scale != 0 image << color.to_ascii end image << "\n" end return image.join end