PDFlib
class PDFlib (View source)
Methods
Activates a previously created structure element or other content item.
Adds a link to a web resource.
Add a link annotation to a target within the current PDF file.
Creates a named destination on an arbitrary page in the current document.
Sets an annotation for the current page.
Add a file link annotation to a PDF target.
Adds a cell to a new or existing table.
Creates a Textflow object, or adds text and explicit options to an existing Textflow.
Adds an existing image as thumbnail for the current page.
Adds a weblink annotation to a target url on the Web.
Adds a counterclockwise circular arc
Except for the drawing direction, this function behaves exactly like PDF_arc().
Adds a file attachment annotation.
Creates a new PDF file subject to various options.
Starts a Type 3 font definition.
Starts a glyph definition for a Type 3 font.
Opens a structure element or other content item with attributes supplied as options.
Starts a layer for subsequent output on the page.
Adds a new page to the document, and specifies various options. The parameters width and height are the dimensions of the new page in points.
Adds a new page to the document.
Starts a new pattern definition.
Starts a new template definition.
Start template definition [deprecated]
Draw a circle
Clip to current path
Close image
Closes the page handle, and frees all page-related resources
Close the input PDF document [deprecated]
No description
Close pdf resource [deprecated]
Close, fill and stroke current path
Close and stroke path
Close current path
Concatenate a matrix to the CTM
Output text in next line
Create 3D view
Create action for objects or events
Create rectangular annotation
Create bookmark
Create form field
Create form field group
Create graphics state object
Create PDFlib virtual file
Create textflow object
Draw Bezier curve
Create layer definition
Delete PDFlib virtual file
Delete table object
Delete textflow object
Delete PDFlib object
Add glyph name and/or Unicode value
Close PDF file
Terminate Type 3 font definition
Terminate glyph definition for Type 3 font
Close structure element or other content item
Deactivate all active layers
Finish page
Finish page
Finish pattern
Finish template
End current path
Fill image block with variable data
Fill PDF block with variable data
Fill and stroke path
Fill text block with variable data
Fill current path
Prepare font for later use [deprecated]
Place image or template
Place imported PDF page
No description
Format textflow in rectangular area
Place single line of text
Get name of unsuccessfull API function
Get PDF output buffer
Get error text
Get error number
Get major version number [deprecated]
Get minor version number [deprecated]
No description
Get string parameter
Get PDI string parameter [deprecated]
Get PDI numerical parameter [deprecated]
No description
Get numerical parameter
Query detailed information about a loaded font
No description
Query matchbox information
No description
No description
No description
No description
Retrieve table information
Query textflow state
Perform textline formatting and query metrics
Reset graphic state
Draw a line
Load 3D model
Search and prepare font
Search and prepare ICC profile
Open image file
Make spot color
Set current point
Open raw CCITT image [deprecated]
Create PDF file [deprecated]
Read image from file [deprecated]
Use image data [deprecated]
Open image created with PHP's image functions [not supported]
Prepare a pdi document
Prepare a page
Open PDF file [deprecated]
Get value of pCOS path with type number or boolean
Get contents of pCOS path with type stream, fstream, or string
Get value of pCOS path with type name, string, or boolean
Place image on the page [deprecated]
Place PDF page [deprecated]
No description
Process imported PDF document
Draw rectangle
Restore graphics state
Resume page
Rotate coordinate system
Save graphics state
Scale coordinate system
Set border color of annotations [deprecated]
Set border dash style of annotations [deprecated]
Set border style of annotations [deprecated]
Activate graphics state object
Fill document info field
Define relationships among layers
Set string parameter
Set text position
Set numerical parameter
Set fill and stroke color
Set simple dash pattern
Set dash pattern
Set flatness
Set font
Set fill color to gray [deprecated]
Set stroke color to gray [deprecated]
Set color to gray [deprecated]
Set linecap parameter
Set linejoin parameter
Set line width
Set current transformation matrix
Set miter limit
Set fill rgb color values [deprecated]
Set stroke rgb color values [deprecated]
Set fill and stroke rgb color values [deprecated]
Define shading pattern
Define blend
Fill area with shading
Output text in a box [deprecated]
Output text at given position
Output text at current position
Skew the coordinate system
Return width of text
Stroke path
Suspend page
Set origin of coordinate system
Convert string from UTF-16 to UTF-8
Convert string from UTF-32 to UTF-16
Convert string from UTF-8 to UTF-16
Details
bool
activate_item(int $id)
Activates a previously created structure element or other content item.
bool
add_launchlink(float $llx, float $lly, float $urx, float $ury, string $filename)
Adds a link to a web resource.
bool
add_locallink(float $lowerleftx, float $lowerlefty, float $upperrightx, float $upperrighty, int $page, string $dest)
Add a link annotation to a target within the current PDF file.
bool
add_nameddest(string $name, string $optlist)
Creates a named destination on an arbitrary page in the current document.
bool
add_note(float $llx, float $lly, float $urx, float $ury, string $contents, string $title, string $icon, int $open)
Sets an annotation for the current page.
bool
add_pdflink(float $bottom_left_x, float $bottom_left_y, float $up_right_x, float $up_right_y, string $filename, int $page, string $dest)
Add a file link annotation to a PDF target.
int
add_table_cell(int $table, int $column, int $row, string $text, string $optlist)
Adds a cell to a new or existing table.
int
add_textflow(int $textflow, string $text, string $optlist)
Creates a Textflow object, or adds text and explicit options to an existing Textflow.
bool
add_thumbnail(int $image)
Adds an existing image as thumbnail for the current page.
bool
add_weblink(float $lowerleftx, float $lowerlefty, float $upperrightx, float $upperrighty, string $url)
Adds a weblink annotation to a target url on the Web.
bool
arc(float $x, float $y, float $r, float $alpha, float $beta)
Adds a counterclockwise circular arc
bool
arcn(float $x, float $y, float $r, float $alpha, float $beta)
Except for the drawing direction, this function behaves exactly like PDF_arc().
bool
attach_file(float $llx, float $lly, float $urx, float $ury, string $filename, string $description, string $author, string $mimetype, string $icon)
Adds a file attachment annotation.
int
begin_document(string $filename, string $optlist)
Creates a new PDF file subject to various options.
bool
begin_font(string $filename, float $a, float $b, float $c, float $d, float $e, float $f, string $optlist)
Starts a Type 3 font definition.
bool
begin_glyph(string $glyphname, float $wx, float $llx, float $lly, float $urx, float $ury)
Starts a glyph definition for a Type 3 font.
int
begin_item(string $tag, string $optlist)
Opens a structure element or other content item with attributes supplied as options.
bool
begin_layer(int $layer)
Starts a layer for subsequent output on the page.
bool
begin_page_ext(float $width, float $height, string $optlist)
Adds a new page to the document, and specifies various options. The parameters width and height are the dimensions of the new page in points.
bool
begin_page(float $width, float $height)
Adds a new page to the document.
int
begin_pattern(float $width, float $height, float $xstep, float $ystep, int $painttype)
Starts a new pattern definition.
int
begin_template_ext(float $width, float $height, string $optlist)
Starts a new template definition.
int
begin_template(float $width, float $height)
Start template definition [deprecated]
Starts a new template definition. This function is deprecated since PDFlib version 7, use PDF_begin_template_ext() instead.
bool
circle(float $x, float $y, float $r)
Draw a circle
Adds a circle. Returns TRUE on success or FALSE on failure.
bool
clip()
Clip to current path
Uses the current path as clipping path, and terminate the path. Returns TRUE on success or FALSE on failure.
bool
close_image(int $image)
Close image
Closes an image retrieved with the PDF_open_image() function.
bool
close_pdi_page(int $page)
Closes the page handle, and frees all page-related resources
bool
close_pdi(int $doc)
Close the input PDF document [deprecated]
Closes all open page handles, and closes the input PDF document. Returns TRUE on success or FALSE on failure. This function is deprecated since PDFlib version 7, use PDF_close_pdi_document() instead.
bool
close_pdi_document(int $doc)
No description
bool
close()
Close pdf resource [deprecated]
Closes the generated PDF file, and frees all document-related resources. Returns TRUE on success or FALSE on failure. This function is deprecated since PDFlib version 6, use PDF_end_document() instead.
bool
closepath_fill_stroke()
Close, fill and stroke current path
Closes the path, fills, and strokes it. Returns TRUE on success or FALSE on failure.
bool
closepath_stroke()
Close and stroke path
Closes the path, and strokes it. Returns TRUE on success or FALSE on failure.
bool
closepath()
Close current path
Closes the current path. Returns TRUE on success or FALSE on failure.
bool
concat(float $a, float $b, float $c, float $d, float $e, float $f)
Concatenate a matrix to the CTM
Concatenates a matrix to the current transformation matrix (CTM). Returns TRUE on success or FALSE on failure.
bool
continue_text(string $text)
Output text in next line
Prints text at the next line. Returns TRUE on success or FALSE on failure.
int
create_3dview(string $username, string $optlist)
Create 3D view
Creates a 3D view. This function requires PDF 1.6.
int
create_action(string $type, string $optlist)
Create action for objects or events
Creates an action which can be applied to various objects and events.
bool
create_annotation(float $llx, float $lly, float $urx, float $ury, string $type, string $optlist)
Create rectangular annotation
Creates a rectangular annotation on the current page.
int
create_bookmark(string $text, string $optlist)
Create bookmark
Creates a bookmark subject to various options.
bool
create_field(float $llx, float $lly, float $urx, float $ury, string $name, string $type, string $optlist)
Create form field
Creates a form field on the current page subject to various options.
bool
create_fieldgroup(string $name, string $optlist)
Create form field group
Creates a form field group subject to various options.
int
create_gstate(string $optlist)
Create graphics state object
Creates a graphics state object subject to various options.
bool
create_pvf(string $filename, string $data, string $optlist)
Create PDFlib virtual file
Creates a named virtual read-only file from data provided in memory.
int
create_textflow(string $text, string $optlist)
Create textflow object
Preprocesses text for later formatting and creates a textflow object.
bool
curveto(float $x1, float $y1, float $x2, float $y2, float $x3, float $y3)
Draw Bezier curve
Draws a Bezier curve from the current point, using 3 more control points. Returns TRUE on success or FALSE on failure.
int
define_layer(string $name, string $optlist)
Create layer definition
Creates a new layer definition. This function requires PDF 1.5.
int
delete_pvf(string $filename)
Delete PDFlib virtual file
Deletes a named virtual file and frees its data structures (but not the contents).
bool
delete_table(int $table, string $optlist)
Delete table object
Deletes a table and all associated data structures.
bool
delete_textflow(int $textflow)
Delete textflow object
Deletes a textflow and the associated data structures.
bool
delete()
Delete PDFlib object
Deletes a PDFlib object, and frees all internal resources. Returns TRUE on success or FALSE on failure.
bool
encoding_set_char(string $encoding, int $slot, string $glyphname, int $uv)
Add glyph name and/or Unicode value
Adds a glyph name and/or Unicode value to a custom encoding.
bool
end_document(string $optlist)
Close PDF file
Closes the generated PDF file and applies various options.
bool
end_font()
Terminate Type 3 font definition
Terminates a Type 3 font definition.
bool
end_glyph()
Terminate glyph definition for Type 3 font
Terminates a glyph definition for a Type 3 font.
bool
end_item(int $id)
Close structure element or other content item
Closes a structure element or other content item.
bool
end_layer()
Deactivate all active layers
Deactivates all active layers. Returns TRUE on success or FALSE on failure. This function requires PDF 1.5.
bool
end_page_ext(string $optlist)
Finish page
Finishes a page, and applies various options. Returns TRUE on success or FALSE on failure.
bool
end_page()
Finish page
Finishes the page. Returns TRUE on success or FALSE on failure.
bool
end_pattern()
Finish pattern
Finishes the pattern definition. Returns TRUE on success or FALSE on failure.
bool
end_template()
Finish template
Finishes a template definition. Returns TRUE on success or FALSE on failure.
bool
endpath()
End current path
Ends the current path without filling or stroking it.
int
fill_imageblock(int $page, string $blockname, int $image, string $optlist)
Fill image block with variable data
Fills an image block with variable data according to its properties. This function is only available in the PDFlib Personalization Server (PPS).
int
fill_pdfblock(int $page, string $blockname, int $contents, string $optlist)
Fill PDF block with variable data
Fills a PDF block with variable data according to its properties. This function is only available in the PDFlib Personalization Server (PPS).
bool
fill_stroke()
Fill and stroke path
Fills and strokes the current path with the current fill and stroke color. Returns TRUE on success or FALSE on failure.
int
fill_textblock(int $page, string $blockname, string $text, string $optlist)
Fill text block with variable data
Fills a text block with variable data according to its properties. This function is only available in the PDFlib Personalization Server (PPS).
bool
fill()
Fill current path
Fills the interior of the current path with the current fill color. Returns TRUE on success or FALSE on failure.
int
findfont(string $fontname, string $encoding, int $embed)
Prepare font for later use [deprecated]
Search for a font and prepare it for later use with PDF_setfont(). The metrics will be loaded, and if embed is nonzero, the font file will be checked, but not yet used. encoding is one of builtin, macroman, winansi, host, a user-defined encoding name or the name of a CMap. Parameter embed is optional before PHP 4.3.5 or with PDFlib less than 5. This function is deprecated since PDFlib version 5, use PDF_load_font() instead.
bool
fit_image(int $image, float $x, float $y, string $optlist)
Place image or template
Places an image or template on the page, subject to various options. Returns TRUE on success or FALSE on failure.
bool
fit_pdi_page(int $page, float $x, float $y, string $optlist)
Place imported PDF page
Places an imported PDF page on the page, subject to various options. Returns TRUE on success or FALSE on failure.
string
fit_table(int $table, float $llx, float $lly, float $urx, float $ury, string $optlist)
No description
string
fit_textflow(int $textflow, float $llx, float $lly, float $urx, float $ury, string $optlist)
Format textflow in rectangular area
Formats the next portion of a textflow into a rectangular area.
bool
fit_textline(string $text, float $x, float $y, string $optlist)
Place single line of text
Places a single line of text on the page, subject to various options. Returns TRUE on success or FALSE on failure.
string
get_apiname()
Get name of unsuccessfull API function
Gets the name of the API function which threw the last exception or failed.
string
get_buffer()
Get PDF output buffer
Fetches the buffer containing the generated PDF data.
string
get_errmsg()
Get error text
Gets the text of the last thrown exception or the reason for a failed function call.
int
get_errnum()
Get error number
Gets the number of the last thrown exception or the reason for a failed function call.
int
get_majorversion()
Get major version number [deprecated]
This function is deprecated since PDFlib version 5, use PDF_get_value() with the parameter major instead.
int
get_minorversion()
Get minor version number [deprecated]
Returns the minor version number of the PDFlib version. This function is deprecated since PDFlib version 5, use PDF_get_value() with the parameter minor instead.
float
get_option(string $keyword, string $optlist)
No description
string
get_parameter(string $key, float $modifier)
Get string parameter
Gets the contents of some PDFlib parameter with string type.
string
get_pdi_parameter(string $key, int $doc, int $page, int $reserved)
Get PDI string parameter [deprecated]
Gets the contents of a PDI document parameter with string type. This function is deprecated since PDFlib version 7, use PDF_pcos_get_string() instead.
float
get_pdi_value(string $key, int $doc, int $page, int $reserved)
Get PDI numerical parameter [deprecated]
Gets the contents of a PDI document parameter with numerical type. This function is deprecated since PDFlib version 7, use PDF_pcos_get_number() instead.
float
get_string(string $keyword, string $optlist)
No description
float
get_value(string $key, float $modifier)
Get numerical parameter
Gets the value of some PDFlib parameter with numerical type.
float
info_font(int $font, string $keyword, string $optlist)
Query detailed information about a loaded font
Queries detailed information about a loaded font.
float
info_image(int $image, string $keyword, string $optlist)
No description
float
info_matchbox(string $boxname, int $num, string $keyword)
Query matchbox information
Queries information about a matchbox on the current page.
float
info_graphics(int $graphics, string $keyword, string $optlist)
No description
float
info_path(int $path, string $keyword, string $optlist)
No description
float
info_pdi_page($page, string $keyword, string $optlist)
No description
float
info_pvf(string $filename, string $keyword)
No description
float
info_table(int $table, string $keyword)
Retrieve table information
Retrieves table information related to the most recently placed table instance.
float
info_textflow(int $textflow, string $keyword)
Query textflow state
Queries the current state of a textflow.
float
info_textline(string $text, string $keyword, string $optlist)
Perform textline formatting and query metrics
Performs textline formatting and queries the resulting metrics.
bool
initgraphics()
Reset graphic state
Reset all color and graphics state parameters to their defaults. Returns TRUE on success or FALSE on failure.
bool
lineto(float $x, float $y)
Draw a line
Draws a line from the current point to another point. Returns TRUE on success or FALSE on failure.
int
load_3ddata(string $filename, string $optlist)
Load 3D model
Loads a 3D model from a disk-based or virtual file. This function requires PDF 1.6.
int
load_font(string $fontname, string $encoding, string $optlist)
Search and prepare font
Searches for a font and prepares it for later use.
int
load_iccprofile(string $profilename, string $optlist)
Search and prepare ICC profile
Searches for an ICC profile, and prepares it for later use.
int
load_image(string $imagetype, string $filename, string $optlist)
Open image file
Opens a disk-based or virtual image file subject to various options.
int
makespotcolor(string $spotname)
Make spot color
Finds a built-in spot color name, or makes a named spot color from the current fill color. Returns TRUE on success or FALSE on failure.
bool
moveto(float $x, float $y)
Set current point
Sets the current point for graphics output. Returns TRUE on success or FALSE on failure.
int
open_ccitt(string $filename, int $width, int $height, int $BitReverse, int $k, int $Blackls1)
Open raw CCITT image [deprecated]
Opens a raw CCITT image. This function is deprecated since PDFlib version 5, use PDF_load_image() instead.
bool
open_file(string $filename)
Create PDF file [deprecated]
Creates a new PDF file using the supplied file name. Returns TRUE on success or FALSE on failure. This function is deprecated since PDFlib version 6, use PDF_begin_document() instead.
int
open_image_file(string $imagetype, string $filename, string $stringparam, int $intparam)
Read image from file [deprecated]
Opens an image file. This function is deprecated since PDFlib version 5, use PDF_load_image() with the colorize, ignoremask, invert, mask, masked, and page options instead.
int
open_image(string $imagetype, string $source, string $data, int $length, int $width, int $height, int $components, int $bpc, string $params)
Use image data [deprecated]
Uses image data from a variety of data sources. This function is deprecated since PDFlib version 5, use virtual files and PDF_load_image() instead.
int
open_memory_image(resource $image)
Open image created with PHP's image functions [not supported]
This function is not supported by PDFlib GmbH.
int
open_pdi_document(string $filename, string $optlist)
Prepare a pdi document
Open a disk-based or virtual PDF document and prepare it for later use.
int
open_pdi_page(int $doc, int $pagenumber, string $optlist)
Prepare a page
Prepares a page for later use with PDF_fit_pdi_page().
int
open_pdi(string $filename, string $optlist, int $len)
Open PDF file [deprecated]
Opens a disk-based or virtual PDF document and prepares it for later use. This function is deprecated since PDFlib version 7, use PDF_open_pdi_document() instead.
float
pcos_get_number(int $doc, string $path)
Get value of pCOS path with type number or boolean
Gets the value of a pCOS path with type number or boolean.
string
pcos_get_stream(int $doc, string $optlist, string $path)
Get contents of pCOS path with type stream, fstream, or string
Gets the contents of a pCOS path with type stream, fstream, or string.
string
pcos_get_string(int $doc, string $path)
Get value of pCOS path with type name, string, or boolean
Gets the value of a pCOS path with type name, string, or boolean.
bool
place_image(int $image, float $x, float $y, float $scale)
Place image on the page [deprecated]
Places an image and scales it. Returns TRUE on success or FALSE on failure. This function is deprecated since PDFlib version 5, use PDF_fit_image() instead.
bool
place_pdi_page(int $page, float $x, float $y, float $sx, float $sy)
Place PDF page [deprecated]
Places a PDF page and scales it. Returns TRUE on success or FALSE on failure. This function is deprecated since PDFlib version 5, use PDF_fit_pdi_page() instead.
bool
set_option(string $optlist)
No description
int
process_pdi(int $doc, int $page, string $optlist)
Process imported PDF document
Processes certain elements of an imported PDF document.
bool
rect(float $x, float $y, float $width, float $height)
Draw rectangle
Draws a rectangle. Returns TRUE on success or FALSE on failure.
bool
restore()
Restore graphics state
Restores the most recently saved graphics state. Returns TRUE on success or FALSE on failure.
bool
resume_page(string $optlist)
Resume page
Resumes a page to add more content to it.
bool
rotate(float $phi)
Rotate coordinate system
Rotates the coordinate system. Returns TRUE on success or FALSE on failure.
bool
save()
Save graphics state
Saves the current graphics state. Returns TRUE on success or FALSE on failure.
bool
scale(float $sx, float $sy)
Scale coordinate system
Scales the coordinate system. Returns TRUE on success or FALSE on failure.
bool
set_border_color(float $red, float $green, float $blue)
Set border color of annotations [deprecated]
Sets the border color for all kinds of annotations. Returns TRUE on success or FALSE on failure. This function is deprecated since PDFlib version 6, use the option annotcolor in PDF_create_annotation() instead.
bool
set_border_dash(float $black, float $white)
Set border dash style of annotations [deprecated]
Sets the border dash style for all kinds of annotations. Returns TRUE on success or FALSE on failure. This function is deprecated since PDFlib version 6, use the option dasharray in PDF_create_annotation() instead.
bool
set_border_style(string $style, float $width)
Set border style of annotations [deprecated]
Sets the border style for all kinds of annotations. Returns TRUE on success or FALSE on failure. This function is deprecated since PDFlib version 6, use the options borderstyle and linewidth in PDF_create_annotation() instead.
bool
set_gstate(int $gstate)
Activate graphics state object
Activates a graphics state object.
bool
set_info(string $key, string $value)
Fill document info field
Fill document information field key with value. Returns TRUE on success or FALSE on failure.
bool
set_layer_dependency(string $type, string $optlist)
Define relationships among layers
Defines hierarchical and group relationships among layers. Returns TRUE on success or FALSE on failure. This function requires PDF 1.5.
bool
set_parameter(string $key, string $value)
Set string parameter
Sets some PDFlib parameter with string type. Returns TRUE on success or FALSE on failure.
bool
set_text_pos(float $x, float $y)
Set text position
Sets the position for text output on the page. Returns TRUE on success or FALSE on failure.
bool
set_value(string $key, float $value)
Set numerical parameter
Sets the value of some PDFlib parameter with numerical type. Returns TRUE on success or FALSE on failure.
bool
setcolor(string $fstype, string $colorspace, float $c1, float $c2, float $c3, float $c4)
Set fill and stroke color
Sets the current color space and color. Returns TRUE on success or FALSE on failure.
bool
setdash(float $b, float $w)
Set simple dash pattern
Sets the current dash pattern to b black and w white units. Returns TRUE on success or FALSE on failure.
bool
setdashpattern(string $optlist)
Set dash pattern
Sets a dash pattern defined by an option list. Returns TRUE on success or FALSE on failure.
bool
setflat(float $flatness)
Set flatness
Sets the flatness parameter. Returns TRUE on success or FALSE on failure.
bool
setfont(int $font, float $fontsize)
Set font
Sets the current font in the specified fontsize, using a font handle returned by PDF_load_font(). Returns TRUE on success or FALSE on failure.
bool
setgray_fill(float $g)
Set fill color to gray [deprecated]
Sets the current fill color to a gray value between 0 and 1 inclusive. Returns TRUE on success or FALSE on failure. This function is deprecated since PDFlib version 4, use PDF_setcolor() instead.
bool
setgray_stroke(float $g)
Set stroke color to gray [deprecated]
Sets the current stroke color to a gray value between 0 and 1 inclusive. Returns TRUE on success or FALSE on failure. This function is deprecated since PDFlib version 4, use PDF_setcolor() instead.
bool
setgray(float $g)
Set color to gray [deprecated]
Sets the current fill and stroke color to a gray value between 0 and 1 inclusive. Returns TRUE on success or FALSE on failure. This function is deprecated since PDFlib version 4, use PDF_setcolor() instead.
bool
setlinecap(int $linecap)
Set linecap parameter
Sets the linecap parameter to control the shape at the end of a path with respect to stroking.
bool
setlinejoin(int $value)
Set linejoin parameter
Sets the linejoin parameter to specify the shape at the corners of paths that are stroked. Returns TRUE on success or FALSE on failure.
bool
setlinewidth(float $width)
Set line width
Sets the current line width. Returns TRUE on success or FALSE on failure.
bool
setmatrix(float $a, float $b, float $c, float $d, float $e, float $f)
Set current transformation matrix
Explicitly sets the current transformation matrix. Returns TRUE on success or FALSE on failure.
bool
setmiterlimit(float $miter)
Set miter limit
Sets the miter limit.Returns TRUE on success or FALSE on failure.
bool
setrgbcolor_fill(float $red, float $green, float $blue)
Set fill rgb color values [deprecated]
Sets the current fill color to the supplied RGB values. Returns TRUE on success or FALSE on failure. This function is deprecated since PDFlib version 4, use PDF_setcolor() instead.
bool
setrgbcolor_stroke(float $red, float $green, float $blue)
Set stroke rgb color values [deprecated]
Sets the current stroke color to the supplied RGB values. Returns TRUE on success or FALSE on failure. This function is deprecated since PDFlib version 4, use PDF_setcolor() instead.
bool
setrgbcolor(float $red, float $green, float $blue)
Set fill and stroke rgb color values [deprecated]
Sets the current fill and stroke color to the supplied RGB values. Returns TRUE on success or FALSE on failure. This function is deprecated since PDFlib version 4, use PDF_setcolor() instead.
int
shading_pattern(int $shading, string $optlist)
Define shading pattern
Defines a shading pattern using a shading object. This function requires PDF 1.4 or above.
int
shading(string $shtype, float $x0, float $y0, float $x1, float $y1, float $c1, float $c2, float $c3, float $c4, string $optlist)
Define blend
Defines a blend from the current fill color to another color. This function requires PDF 1.4 or above.
bool
shfill(int $shading)
Fill area with shading
Fills an area with a shading, based on a shading object. This function requires PDF 1.4 or above.
int
show_boxed(string $text, float $left, float $top, float $width, float $height, string $mode, string $feature)
Output text in a box [deprecated]
This function is deprecated since PDFlib version 6, use PDF_fittextline() for single lines, or the PDF*_textflow() functions for multi-line formatting instead.
bool
show_xy(string $text, float $x, float $y)
Output text at given position
Prints text in the current font. Returns TRUE on success or FALSE on failure.
bool
show(string $text)
Output text at current position
Prints text in the current font and size at the current position. Returns TRUE on success or FALSE on failure.
bool
skew(float $alpha, float $beta)
Skew the coordinate system
Skews the coordinate system in x and y direction by alpha and beta degrees, respectively. Returns TRUE on success or FALSE on failure.
float
stringwidth(string $text, int $font, float $fontsize)
Return width of text
Returns the width of text in an arbitrary font.
bool
stroke()
Stroke path
Strokes the path with the current color and line width, and clear it. Returns TRUE on success or FALSE on failure.
bool
suspend_page(string $optlist)
Suspend page
Suspends the current page so that it can later be resumed with PDF_resume_page().
bool
translate(float $tx, float $ty)
Set origin of coordinate system
Translates the origin of the coordinate system.
string
utf16_to_utf8(string $utf16string)
Convert string from UTF-16 to UTF-8
Converts a string from UTF-16 format to UTF-8.
string
utf32_to_utf16(string $utf32string, string $ordering)
Convert string from UTF-32 to UTF-16
Converts a string from UTF-32 format to UTF-16.
string
utf8_to_utf16(string $utf8string, string $ordering)
Convert string from UTF-8 to UTF-16
Converts a string from UTF-8 format to UTF-16.