How many fonts are available in Prawn?

Ray301 picture Ray301 · Apr 8, 2011 · Viewed 9k times · Source

I've been randomly trying fonts in Prawn, for Ruby.

For Example: Times New Roman - Yes Palatino Linotype - No

Is there a list of which fonts are available and which aren't?

Answer

sockmonk picture sockmonk · Feb 1, 2013

There's a list of default fonts in the code, at lib/prawn/font/afm.rb (version 1.0.0.rc1):

module Prawn
  class Font
    class AFM < Font
      BUILT_INS = %w[ Courier Helvetica Times-Roman Symbol ZapfDingbats
                      Courier-Bold Courier-Oblique Courier-BoldOblique
                      Times-Bold Times-Italic Times-BoldItalic
                      Helvetica-Bold Helvetica-Oblique Helvetica-BoldOblique ]