# File lib/png/font.rb, line 26 def coordinates c i = LETTERS.index c raise ArgumentError, "Can't find #{c.inspect}" unless i x = (i % 26) * width y = (3 - (i / 26)) * height # start from the top (3rd row) return x, y, x+width-1, y+height-1 end