CTS logo
hazy blue Catskill Mountains in distance

News:

PDF::Builder v3.027 Released, 18 April 2025
   Please also see the CPAN listing, the GitHub entry, and the latest changes list.


A Thought…

If winter comes, can spring be far behind?

   — Percy Bysshe Shelley, Ode to the West Wind

NAME

PDF::Builder::Basic::PDF::Utils - Utility functions for PDF library

DESCRIPTION

A set of utility functions to save the fingers of the PDF library users!

METHODS

PDFBool

    PDFBool()
Creates a Bool via PDF::Builder::Basic::PDF::Bool->new()

PDFArray

    PDFArray()
Creates an array via PDF::Builder::Basic::PDF::Array->new()

PDFDict

    PDFDict()
Creates a dict via PDF::Builder::Basic::PDF::Dict->new()

PDFName

    PDFName()
Creates a name via PDF::Builder::Basic::PDF::Name->new()

PDFNull

    PDFNull()
Creates a null via PDF::Builder::Basic::PDF::Null->new()

PDFNum

    PDFNum()
Creates a number via PDF::Builder::Basic::PDF::Number->new()

PDFString

    PDFString($text, $usage)
Returns either PDFStr($text) or PDFUtf($text), depending on whether $text is already in UTF-8 and whether the $usage permits UTF-8. If UTF-8 is not permitted, downgrade will be called on a UTF-8 formatted $text.
$usage is a single character string indicating the use for which $text is to be applied. Some uses permit UTF-8, while others (currently) forbid it:
's'
An ordinary string, where UTF-8 text is permitted.
'n'
A named destination, where UTF-8 text is permitted.
'o'
An outline title, where UTF-8 text is permitted.
'p'
A popup title, where UTF-8 text is permitted.
'm'
metadata, where UTF-8 text is permitted.
'f'
A file path and/or name, where UTF-8 text is currently not permitted.
'u'
A URL, where UTF-8 text is currently not permitted.
'x'
Any other usage where UTF-8 text is not permitted.

PDFStr

    PDFStr()
Creates a string via PDF::Builder::Basic::PDF::String->new()
DEPRECATED. It is preferable that you use PDFString instead.

PDFStrHex

    PDFStrHex()
Creates a hex-string via PDF::Builder::Basic::PDF::String->new()

PDFUtf

    PDFUtf()
Creates a utf8-string via PDF::Builder::Basic::PDF::String->new()
DEPRECATED. It is preferable that you use PDFString instead.

NAVIGATION LINKS

Up (Parents)

Master Index
PDF::Builder -- Facilitates the creation and modification of PDF files
PDF::Builder::Basic::PDF -- Various utilities and support routines

Siblings

PDF::Builder::Basic::PDF::Array -- Corresponds to a PDF array
PDF::Builder::Basic::PDF::Bool -- Holds the strings true or false
PDF::Builder::Basic::PDF::Dict -- PDF Dictionaries and Streams
PDF::Builder::Basic::PDF::File -- Holds the trailers and cross-reference tables for a PDF file
PDF::Builder::Basic::PDF::Filter -- Abstract superclass for PDF stream filters
PDF::Builder::Basic::PDF::Literal -- Literal PDF Object
PDF::Builder::Basic::PDF::Name -- Stores PDF names (things beginning with /)
PDF::Builder::Basic::PDF::Null -- PDF Null type object
PDF::Builder::Basic::PDF::Number -- Numbers in PDF
PDF::Builder::Basic::PDF::Objind -- PDF indirect object reference
PDF::Builder::Basic::PDF::Page -- Represents a PDF page
PDF::Builder::Basic::PDF::Pages -- PDF pages hierarchical element
PDF::Builder::Basic::PDF::String -- PDF String type objects

 

All content © copyright 2005 – 2025 by Catskill Technology Services, LLC.
All rights reserved.
Note that Third Party software (whether Open Source or proprietary) on this site remains under the copyright and license of its owners. Catskill Technology Services, LLC does not claim copyright over such software.

 

This page is https://www.catskilltech.com/Documentation/PDF/Builder/Basic/PDF/Utils.html

Search Quotations database.

Last updated Sat, 19 Apr 2025 at 8:15 PM

Valid HTML 5

Tue, 11 Nov 2025 at 4:39 AM EST