logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

Text::PDF::SFont - PDF Standard inbuilt font resource object. Inherits from Text::PDF::Dict

Bugs

       Currently no width support for Symbol or ZapfDingbats, I haven't got my head around the AFMs yet.

       MacExpertEncoding not supported yet (I don't have the width info for any of the fonts)

   $f->width($text)
       Returns the width of the text in em.

   $f->trim($text,$len)
       Trims the given text to the given length (in em) returning the trimmed text

   $f->out_text($text)
       Acknowledges the text to be output for subsetting purposes, etc.

perl v5.36.0                                       2022-10-22                              Text::PDF::SFont(3pm)

Methods

Text::PDF::SFont->new($parent,$name,$pdfname)
       Creates a new font object with given parent and name. The name must be from one of the core 14 base fonts
       included with PDF. These are:

           Courier,     Courier-Bold,   Courier-Oblique,   Courier-BoldOblique
           Times-Roman, Times-Bold,     Times-Italic,      Times-BoldItalic
           Helvetica,   Helvetica-Bold, Helvetica-Oblique, Helvetica-BoldOblique
           Symbol,      ZapfDingbats

       The $pdfname is the name that this particular font object will be referenced by throughout the PDF file.
       If you want to play silly games with naming, then you can write the code to do it!

       All fonts in this system are full PDF objects.

Name

       Text::PDF::SFont - PDF Standard inbuilt font resource object. Inherits from Text::PDF::Dict

See Also