def set_font(font = :Helvetica)
      # if the font exists, return it's name
      resources[:Font] ||= {}
      fonts_res = resources[:Font][:referenced_object] || resources[:Font]
      fonts_res.each do |k, v|
        return k if v.is_a?(Fonts::Font) && v.name && v.name == font
      end
      # set a secure name for the font
      name = (base_font_name + (fonts_res.length + 1).to_s).to_sym
      # get font object
      font_object = Fonts.get_font(font)
      # return false if the font wan't found in the library.
      return false unless font_object
      # add object to reasource
      fonts_res[name] = font_object
      # return name
      name
    end
def set_font(font = :Helvetica)
      # if the font exists, return it's name
      resources[:Font] ||= {}
      fonts_res = resources[:Font][:referenced_object] || resources[:Font]
      fonts_res.each do |k, v|
        return k if v.is_a?(Fonts::Font) && v.name && v.name == font
      end
      # set a secure name for the font
      name = (base_font_name + (fonts_res.length + 1).to_s).to_sym
      # get font object
      font_object = Fonts.get_font(font)
      # return false if the font wan't found in the library.
      return false unless font_object
      # add object to reasource
      fonts_res[name] = font_object
      # return name
      name
    end
creates a font object and adds the font to the resources dictionary
 returns the name of the font for the content stream.
 font:: a Symbol of one of the fonts registered in the library, or:
 - :"Times-Roman"
 - :"Times-Bold"
 - :"Times-Italic"
 - :"Times-BoldItalic"
 - :Helvetica
 - :"Helvetica-Bold"
 - :"Helvetica-BoldOblique"
 - :"Helvetica- Oblique"
 - :Courier
 - :"Courier-Bold"
 - :"Courier-Oblique"
 - :"Courier-BoldOblique"
 - :Symbol
 - :ZapfDingbats