# File lib/png/font.rb, line 53
  def annotate(string, x, y,
               font = PNG::Font.default, align = :left, style = :overwrite)
    case align
    when :left then
      # do nothing
    when :center then
      x -= string.length * font.width / 2
    when :right then
      x -= string.length * font.width
    else
      raise ArgumentError, "Unknown align: #{align.inspect}"
    end

    x_offset, width = 0, font.width

    string.split(//).each do |char|
      self.composite font[char], x + x_offset, y
      x_offset += width
    end
  end