Starting with PHP 4.0.5, the PHP extension for PDFlib is officially supported by PDFlib GmbH. This means that all the functions described in the PDFlib Reference Manual are supported by PHP 4 with exactly the same meaning and the same parameters. However, with PDFlib Version 5.0.4 or higher all parameters have to be specified. For compatibility reasons, this binding for PDFlib still supports most of the deprecated functions, but they should be replaced by their new versions. PDFlib GmbH will not support any problems arising from the use of these deprecated functions. The documentation in this section indicates old functions as "Deprecated" and gives the replacement function to be used instead.

PDF_activate_item

Activate structure element or other content item

说明

bool PDF_activate_item ( resource $pdfdoc , int $id )

Activates a previously created structure element or other content item. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_add_annotation

Add annotation [deprecated]

说明

This function is deprecated, use PDF_create_annotation with type=Text instead.

PDF_add_bookmark

Add bookmark for current page [deprecated]

说明

This function is deprecated since PDFlib version 6, use PDF_create_bookmark instead.

PDF_add_launchlink

Add launch annotation for current page [deprecated]

说明

bool PDF_add_launchlink ( resource $pdfdoc , float $llx , float $lly , float $urx , float $ury , string $filename )

Adds a link to a web resource.

This function is deprecated since PDFlib version 6, use PDF_create_action with type=Launch and PDF_create_annotation with type=Link instead.

PDF_add_locallink

Add link annotation for current page [deprecated]

说明

bool PDF_add_locallink ( resource $pdfdoc , float $lowerleftx , float $lowerlefty , float $upperrightx , float $upperrighty , int $page , string $dest )

Add a link annotation to a target within the current PDF file. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 6, use PDF_create_action with type=GoTo and PDF_create_annotation with type=Link instead.

PDF_add_nameddest

Create named destination

说明

bool PDF_add_nameddest ( resource $pdfdoc , string $name , string $optlist )

Creates a named destination on an arbitrary page in the current document. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_add_note

Set annotation for current page [deprecated]

说明

bool PDF_add_note ( resource $pdfdoc , float $llx , float $lly , float $urx , float $ury , string $contents , string $title , string $icon , int $open )

Sets an annotation for the current page. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 6, use PDF_create_annotation with type=Text instead.

PDF_add_outline

Add bookmark for current page [deprecated]

说明

This function is deprecated, use PDF_create_bookmark instead.

PDF_add_pdflink

Add file link annotation for current page [deprecated]

说明

bool PDF_add_pdflink ( resource $pdfdoc , 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. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 6, use PDF_create_action with type=GoToR and PDF_create_annotation with type=Link instead.

PDF_add_table_cell

Add a cell to a new or existing table

说明

int PDF_add_table_cell ( resource $pdfdoc , int $table , int $column , int $row , string $text , string $optlist )

Adds a cell to a new or existing table.

PDF_add_textflow

Create Textflow or add text to existing Textflow

说明

int PDF_add_textflow ( resource $pdfdoc , int $textflow , string $text , string $optlist )

Creates a Textflow object, or adds text and explicit options to an existing Textflow.

PDF_add_thumbnail

Add thumbnail for current page

说明

bool PDF_add_thumbnail ( resource $pdfdoc , int $image )

Adds an existing image as thumbnail for the current page. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_add_weblink

Add weblink for current page [deprecated]

说明

bool PDF_add_weblink ( resource $pdfdoc , float $lowerleftx , float $lowerlefty , float $upperrightx , float $upperrighty , string $url )

Adds a weblink annotation to a target url on the Web. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 6, use PDF_create_action with type=URI and PDF_create_annotation with type=Link instead.

PDF_arc

Draw a counterclockwise circular arc segment

说明

bool PDF_arc ( resource $p , float $x , float $y , float $r , float $alpha , float $beta )

Adds a counterclockwise circular arc.

PDF_arcn

Draw a clockwise circular arc segment

说明

bool PDF_arcn ( resource $p , float $x , float $y , float $r , float $alpha , float $beta )

Except for the drawing direction, this function behaves exactly like PDF_arc.

PDF_attach_file

Add file attachment for current page [deprecated]

说明

bool PDF_attach_file ( resource $pdfdoc , float $llx , float $lly , float $urx , float $ury , string $filename , string $description , string $author , string $mimetype , string $icon )

Adds a file attachment annotation. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 6, use PDF_create_annotation with type=FileAttachment instead.

PDF_begin_document

Create new PDF file

说明

int PDF_begin_document ( resource $pdfdoc , string $filename , string $optlist )

Creates a new PDF file subject to various options.

PDF_begin_font

Start a Type 3 font definition

说明

bool PDF_begin_font ( resource $pdfdoc , string $filename , float $a , float $b , float $c , float $d , float $e , float $f , string $optlist )

Starts a Type 3 font definition.

PDF_begin_glyph

Start glyph definition for Type 3 font

说明

bool PDF_begin_glyph ( resource $pdfdoc , string $glyphname , float $wx , float $llx , float $lly , float $urx , float $ury )

Starts a glyph definition for a Type 3 font.

PDF_begin_item

Open structure element or other content item

说明

int PDF_begin_item ( resource $pdfdoc , string $tag , string $optlist )

Opens a structure element or other content item with attributes supplied as options.

PDF_begin_layer

Start layer

说明

bool PDF_begin_layer ( resource $pdfdoc , int $layer )

Starts a layer for subsequent output on the page. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function requires PDF 1.5.

PDF_begin_page_ext

Start new page

说明

bool PDF_begin_page_ext ( resource $pdfdoc , 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. 成功时返回 TRUE, 或者在失败时返回 FALSE

namesize
A02380 x 3368
A11684 x 2380
A21190 x 1684
A3842 x 1190
A4595 x 842
A5421 x 595
A6297 x 421
B5501 x 709
letter (8.5" x 11")612 x 792
legal (8.5" x 14")612 x 1008
ledger (17" x 11")1224 x 792
11" x 17"792 x 1224

PDF_begin_page

Start new page [deprecated]

说明

bool PDF_begin_page ( resource $pdfdoc , float $width , float $height )

Adds a new page to the document. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 6, use PDF_begin_page_ext instead.

PDF_begin_pattern

Start pattern definition

说明

int PDF_begin_pattern ( resource $pdfdoc , float $width , float $height , float $xstep , float $ystep , int $painttype )

Starts a new pattern definition.

PDF_begin_template_ext

Start template definition

说明

int PDF_begin_template_ext ( resource $pdfdoc , float $width , float $height , string $optlist )

Starts a new template definition.

PDF_begin_template

Start template definition [deprecated]

说明

int PDF_begin_template ( resource $pdfdoc , float $width , float $height )

Starts a new template definition.

This function is deprecated since PDFlib version 7, use PDF_begin_template_ext instead.

PDF_circle

Draw a circle

说明

bool PDF_circle ( resource $pdfdoc , float $x , float $y , float $r )

Adds a circle. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_clip

Clip to current path

说明

bool PDF_clip ( resource $p )

Uses the current path as clipping path, and terminate the path. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_close_image

Close image

说明

bool PDF_close_image ( resource $p , int $image )

Closes an image retrieved with the PDF_open_image function.

PDF_close_pdi_page

Close the page handle

说明

bool PDF_close_pdi_page ( resource $p , int $page )

Closes the page handle, and frees all page-related resources. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_close_pdi

Close the input PDF document [deprecated]

说明

bool PDF_close_pdi ( resource $p , int $doc )

Closes all open page handles, and closes the input PDF document. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 7, use PDF_close_pdi_document instead.

PDF_close

Close pdf resource [deprecated]

说明

bool PDF_close ( resource $p )

Closes the generated PDF file, and frees all document-related resources. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 6, use PDF_end_document instead.

PDF_closepath_fill_stroke

Close, fill and stroke current path

说明

bool PDF_closepath_fill_stroke ( resource $p )

Closes the path, fills, and strokes it. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_closepath_stroke

Close and stroke path

说明

bool PDF_closepath_stroke ( resource $p )

Closes the path, and strokes it. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_closepath

Close current path

说明

bool PDF_closepath ( resource $p )

Closes the current path. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_concat

Concatenate a matrix to the CTM

说明

bool PDF_concat ( resource $p , float $a , float $b , float $c , float $d , float $e , float $f )

Concatenates a matrix to the current transformation matrix (CTM). 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_continue_text

Output text in next line

说明

bool PDF_continue_text ( resource $p , string $text )

Prints text at the next line. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_create_3dview

Create 3D view

说明

int PDF_create_3dview ( resource $pdfdoc , string $username , string $optlist )

Creates a 3D view.

This function requires PDF 1.6.

PDF_create_action

Create action for objects or events

说明

int PDF_create_action ( resource $pdfdoc , string $type , string $optlist )

Creates an action which can be applied to various objects and events.

PDF_create_annotation

Create rectangular annotation

说明

bool PDF_create_annotation ( resource $pdfdoc , float $llx , float $lly , float $urx , float $ury , string $type , string $optlist )

Creates a rectangular annotation on the current page.

PDF_create_bookmark

Create bookmark

说明

int PDF_create_bookmark ( resource $pdfdoc , string $text , string $optlist )

Creates a bookmark subject to various options.

PDF_create_field

Create form field

说明

bool PDF_create_field ( resource $pdfdoc , float $llx , float $lly , float $urx , float $ury , string $name , string $type , string $optlist )

Creates a form field on the current page subject to various options.

PDF_create_fieldgroup

Create form field group

说明

bool PDF_create_fieldgroup ( resource $pdfdoc , string $name , string $optlist )

Creates a form field group subject to various options.

PDF_create_gstate

Create graphics state object

说明

int PDF_create_gstate ( resource $pdfdoc , string $optlist )

Creates a graphics state object subject to various options.

PDF_create_pvf

Create PDFlib virtual file

说明

bool PDF_create_pvf ( resource $pdfdoc , string $filename , string $data , string $optlist )

Creates a named virtual read-only file from data provided in memory.

PDF_create_textflow

Create textflow object

说明

int PDF_create_textflow ( resource $pdfdoc , string $text , string $optlist )

Preprocesses text for later formatting and creates a textflow object.

PDF_curveto

Draw Bezier curve

说明

bool PDF_curveto ( resource $p , float $x1 , float $y1 , float $x2 , float $y2 , float $x3 , float $y3 )

Draws a Bezier curve from the current point, using 3 more control points. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_define_layer

Create layer definition

说明

int PDF_define_layer ( resource $pdfdoc , string $name , string $optlist )

Creates a new layer definition.

This function requires PDF 1.5.

PDF_delete_pvf

Delete PDFlib virtual file

说明

int PDF_delete_pvf ( resource $pdfdoc , string $filename )

Deletes a named virtual file and frees its data structures (but not the contents).

PDF_delete_table

Delete table object

说明

bool PDF_delete_table ( resource $pdfdoc , int $table , string $optlist )

Deletes a table and all associated data structures.

PDF_delete_textflow

Delete textflow object

说明

bool PDF_delete_textflow ( resource $pdfdoc , int $textflow )

Deletes a textflow and the associated data structures.

PDF_delete

Delete PDFlib object

说明

bool PDF_delete ( resource $pdfdoc )

Deletes a PDFlib object, and frees all internal resources. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_encoding_set_char

Add glyph name and/or Unicode value

说明

bool PDF_encoding_set_char ( resource $pdfdoc , string $encoding , int $slot , string $glyphname , int $uv )

Adds a glyph name and/or Unicode value to a custom encoding.

PDF_end_document

关闭 PDF 文件

说明

bool PDF_end_document ( resource $pdfdoc , string $optlist )

使用指定的选项,关闭生成的 PDF 文件。

PDF_end_font

Terminate Type 3 font definition

说明

bool PDF_end_font ( resource $pdfdoc )

Terminates a Type 3 font definition.

PDF_end_glyph

Terminate glyph definition for Type 3 font

说明

bool PDF_end_glyph ( resource $pdfdoc )

Terminates a glyph definition for a Type 3 font.

PDF_end_item

Close structure element or other content item

说明

bool PDF_end_item ( resource $pdfdoc , int $id )

Closes a structure element or other content item.

PDF_end_layer

Deactivate all active layers

说明

bool PDF_end_layer ( resource $pdfdoc )

Deactivates all active layers. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function requires PDF 1.5.

PDF_end_page_ext

Finish page

说明

bool PDF_end_page_ext ( resource $pdfdoc , string $optlist )

Finishes a page, and applies various options. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_end_page

Finish page

说明

bool PDF_end_page ( resource $p )

Finishes the page. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_end_pattern

Finish pattern

说明

bool PDF_end_pattern ( resource $p )

Finishes the pattern definition. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_end_template

Finish template

说明

bool PDF_end_template ( resource $p )

Finishes a template definition. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_endpath

End current path

说明

bool PDF_endpath ( resource $p )

Ends the current path without filling or stroking it.

PDF_fill_imageblock

Fill image block with variable data

说明

int PDF_fill_imageblock ( resource $pdfdoc , int $page , string $blockname , int $image , string $optlist )

Fills an image block with variable data according to its properties.

This function is only available in the PDFlib Personalization Server (PPS).

PDF_fill_pdfblock

Fill PDF block with variable data

说明

int PDF_fill_pdfblock ( resource $pdfdoc , int $page , string $blockname , int $contents , string $optlist )

Fills a PDF block with variable data according to its properties.

This function is only available in the PDFlib Personalization Server (PPS).

PDF_fill_stroke

Fill and stroke path

说明

bool PDF_fill_stroke ( resource $p )

Fills and strokes the current path with the current fill and stroke color. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_fill_textblock

Fill text block with variable data

说明

int PDF_fill_textblock ( resource $pdfdoc , int $page , string $blockname , string $text , string $optlist )

Fills a text block with variable data according to its properties.

This function is only available in the PDFlib Personalization Server (PPS).

PDF_fill

Fill current path

说明

bool PDF_fill ( resource $p )

Fills the interior of the current path with the current fill color. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_findfont

Prepare font for later use [deprecated]

说明

int PDF_findfont ( resource $p , string $fontname , string $encoding , int $embed )

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.

PDF_fit_image

Place image or template

说明

bool PDF_fit_image ( resource $pdfdoc , int $image , float $x , float $y , string $optlist )

Places an image or template on the page, subject to various options. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_fit_pdi_page

Place imported PDF page

说明

bool PDF_fit_pdi_page ( resource $pdfdoc , int $page , float $x , float $y , string $optlist )

Places an imported PDF page on the page, subject to various options. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_fit_table

Place table on page

说明

string PDF_fit_table ( resource $pdfdoc , int $table , float $llx , float $lly , float $urx , float $ury , string $optlist )

Places a table on the page fully or partially.

PDF_fit_textflow

Format textflow in rectangular area

说明

string PDF_fit_textflow ( resource $pdfdoc , int $textflow , float $llx , float $lly , float $urx , float $ury , string $optlist )

Formats the next portion of a textflow into a rectangular area.

PDF_fit_textline

Place single line of text

说明

bool PDF_fit_textline ( resource $pdfdoc , string $text , float $x , float $y , string $optlist )

Places a single line of text on the page, subject to various options. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_get_apiname

Get name of unsuccessfull API function

说明

string PDF_get_apiname ( resource $pdfdoc )

Gets the name of the API function which threw the last exception or failed.

PDF_get_buffer

Get PDF output buffer

说明

string PDF_get_buffer ( resource $p )

Fetches the buffer containing the generated PDF data.

PDF_get_errmsg

Get error text

说明

string PDF_get_errmsg ( resource $pdfdoc )

Gets the text of the last thrown exception or the reason for a failed function call.

PDF_get_errnum

Get error number

说明

int PDF_get_errnum ( resource $pdfdoc )

Gets the number of the last thrown exception or the reason for a failed function call.

PDF_get_font

Get font [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_get_value with the parameter font instead.

PDF_get_fontname

Get font name [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_get_parameter with the parameter fontname instead.

PDF_get_fontsize

Font handling [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_get_value with the parameter fontsizeinstead.

PDF_get_image_height

Get image height [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_get_value with the parameter imageheight instead.

PDF_get_image_width

Get image width [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_get_value with the parameter imagewidth instead.

PDF_get_majorversion

Get major version number [deprecated]

说明

int PDF_get_majorversion ( void )

This function is deprecated since PDFlib version 5, use PDF_get_value with the parameter major instead.

PDF_get_minorversion

Get minor version number [deprecated]

说明

int PDF_get_minorversion ( void )

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.

PDF_get_parameter

Get string parameter

说明

string PDF_get_parameter ( resource $p , string $key , float $modifier )

Gets the contents of some PDFlib parameter with string type.

PDF_get_pdi_parameter

Get PDI string parameter [deprecated]

说明

string PDF_get_pdi_parameter ( resource $p , string $key , int $doc , int $page , int $reserved )

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.

PDF_get_pdi_value

Get PDI numerical parameter [deprecated]

说明

float PDF_get_pdi_value ( resource $p , string $key , int $doc , int $page , int $reserved )

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.

PDF_get_value

Get numerical parameter

说明

float PDF_get_value ( resource $p , string $key , float $modifier )

Gets the value of some PDFlib parameter with numerical type.

PDF_info_font

Query detailed information about a loaded font

说明

float PDF_info_font ( resource $pdfdoc , int $font , string $keyword , string $optlist )

Queries detailed information about a loaded font.

PDF_info_matchbox

Query matchbox information

说明

float PDF_info_matchbox ( resource $pdfdoc , string $boxname , int $num , string $keyword )

Queries information about a matchbox on the current page.

PDF_info_table

Retrieve table information

说明

float PDF_info_table ( resource $pdfdoc , int $table , string $keyword )

Retrieves table information related to the most recently placed table instance.

PDF_info_textflow

Query textflow state

说明

float PDF_info_textflow ( resource $pdfdoc , int $textflow , string $keyword )

Queries the current state of a textflow.

PDF_info_textline

Perform textline formatting and query metrics

说明

float PDF_info_textline ( resource $pdfdoc , string $text , string $keyword , string $optlist )

Performs textline formatting and queries the resulting metrics.

PDF_initgraphics

Reset graphic state

说明

bool PDF_initgraphics ( resource $p )

Reset all color and graphics state parameters to their defaults. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_lineto

Draw a line

说明

bool PDF_lineto ( resource $p , float $x , float $y )

Draws a line from the current point to another point. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_load_3ddata

Load 3D model

说明

int PDF_load_3ddata ( resource $pdfdoc , string $filename , string $optlist )

Loads a 3D model from a disk-based or virtual file.

This function requires PDF 1.6.

PDF_load_font

Search and prepare font

说明

int PDF_load_font ( resource $pdfdoc , string $fontname , string $encoding , string $optlist )

Searches for a font and prepares it for later use.

PDF_load_iccprofile

Search and prepare ICC profile

说明

int PDF_load_iccprofile ( resource $pdfdoc , string $profilename , string $optlist )

Searches for an ICC profile, and prepares it for later use.

PDF_load_image

打开一个图像文件

说明

int PDF_load_image ( resource $pdfdoc , string $imagetype , string $filename , string $optlist )

使用指定选项,打开一个基于磁盘的或虚拟的图像文件。

PDF_makespotcolor

Make spot color

说明

int PDF_makespotcolor ( resource $p , string $spotname )

Finds a built-in spot color name, or makes a named spot color from the current fill color. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_moveto

Set current point

说明

bool PDF_moveto ( resource $p , float $x , float $y )

Sets the current point for graphics output. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_new

Create PDFlib object

说明

resource PDF_new ( void )

Creates a new PDFlib object with default settings.

PDF_open_ccitt

Open raw CCITT image [deprecated]

说明

int PDF_open_ccitt ( resource $pdfdoc , string $filename , int $width , int $height , int $BitReverse , int $k , int $Blackls1 )

Opens a raw CCITT image.

This function is deprecated since PDFlib version 5, use PDF_load_image instead.

PDF_open_file

Create PDF file [deprecated]

说明

bool PDF_open_file ( resource $p , string $filename )

Creates a new PDF file using the supplied file name. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 6, use PDF_begin_document instead.

PDF_open_gif

Open GIF image [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_load_image instead.

PDF_open_image_file

Read image from file [deprecated]

说明

int PDF_open_image_file ( resource $p , string $imagetype , string $filename , string $stringparam , int $intparam )

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.

PDF_open_image

Use image data [deprecated]

说明

int PDF_open_image ( resource $p , string $imagetype , string $source , string $data , int $length , int $width , int $height , int $components , int $bpc , string $params )

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.

PDF_open_jpeg

Open JPEG image [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_load_image instead.

PDF_open_memory_image

Open image created with PHP's image functions [not supported]

说明

int PDF_open_memory_image ( resource $p , resource $image )

This function is not supported by PDFlib GmbH.

PDF_open_pdi_document

Prepare a pdi document

说明

int PDF_open_pdi_document ( resource $p , string $filename , string $optlist )

Open a disk-based or virtual PDF document and prepare it for later use.

PDF_open_pdi_page

Prepare a page

说明

int PDF_open_pdi_page ( resource $p , int $doc , int $pagenumber , string $optlist )

Prepares a page for later use with PDF_fit_pdi_page.

PDF_open_pdi

Open PDF file [deprecated]

说明

int PDF_open_pdi ( resource $pdfdoc , string $filename , string $optlist , int $len )

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.

PDF_open_tiff

Open TIFF image [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_load_image instead.

PDF_pcos_get_number

Get value of pCOS path with type number or boolean

说明

float PDF_pcos_get_number ( resource $p , int $doc , string $path )

Gets the value of a pCOS path with type number or boolean.

PDF_pcos_get_stream

Get contents of pCOS path with type stream, fstream, or string

说明

string PDF_pcos_get_stream ( resource $p , int $doc , string $optlist , string $path )

Gets the contents of a pCOS path with type stream, fstream, or string.

PDF_pcos_get_string

Get value of pCOS path with type name, string, or boolean

说明

string PDF_pcos_get_string ( resource $p , int $doc , string $path )

Gets the value of a pCOS path with type name, string, or boolean.

PDF_place_image

Place image on the page [deprecated]

说明

bool PDF_place_image ( resource $pdfdoc , int $image , float $x , float $y , float $scale )

Places an image and scales it. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 5, use PDF_fit_image instead.

PDF_place_pdi_page

Place PDF page [deprecated]

说明

bool PDF_place_pdi_page ( resource $pdfdoc , int $page , float $x , float $y , float $sx , float $sy )

Places a PDF page and scales it. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 5, use PDF_fit_pdi_page instead.

PDF_process_pdi

Process imported PDF document

说明

int PDF_process_pdi ( resource $pdfdoc , int $doc , int $page , string $optlist )

Processes certain elements of an imported PDF document.

PDF_rect

Draw rectangle

说明

bool PDF_rect ( resource $p , float $x , float $y , float $width , float $height )

Draws a rectangle. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_restore

Restore graphics state

说明

bool PDF_restore ( resource $p )

Restores the most recently saved graphics state. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_resume_page

Resume page

说明

bool PDF_resume_page ( resource $pdfdoc , string $optlist )

Resumes a page to add more content to it.

PDF_rotate

Rotate coordinate system

说明

bool PDF_rotate ( resource $p , float $phi )

Rotates the coordinate system. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_save

Save graphics state

说明

bool PDF_save ( resource $p )

Saves the current graphics state. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_scale

Scale coordinate system

说明

bool PDF_scale ( resource $p , float $sx , float $sy )

Scales the coordinate system. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_set_border_color

Set border color of annotations [deprecated]

说明

bool PDF_set_border_color ( resource $p , float $red , float $green , float $blue )

Sets the border color for all kinds of annotations. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 6, use the option annotcolor in PDF_create_annotation instead.

PDF_set_border_dash

Set border dash style of annotations [deprecated]

说明

bool PDF_set_border_dash ( resource $pdfdoc , float $black , float $white )

Sets the border dash style for all kinds of annotations. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 6, use the option dasharray in PDF_create_annotation instead.

PDF_set_border_style

Set border style of annotations [deprecated]

说明

bool PDF_set_border_style ( resource $pdfdoc , string $style , float $width )

Sets the border style for all kinds of annotations. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 6, use the options borderstyle and linewidth in PDF_create_annotation instead.

PDF_set_char_spacing

Set character spacing [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_set_value with parameter charspacing instead.

PDF_set_duration

Set duration between pages [deprecated]

说明

This function is deprecated since PDFlib version 3, use the duration option in PDF_begin_page_ext or PDF_end_page_ext instead.

PDF_set_gstate

Activate graphics state object

说明

bool PDF_set_gstate ( resource $pdfdoc , int $gstate )

Activates a graphics state object.

PDF_set_horiz_scaling

Set horizontal text scaling [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_set_value with parameter horizscaling instead.

PDF_set_info_author

Fill the author document info field [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_set_info instead.

PDF_set_info_creator

Fill the creator document info field [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_set_info instead.

PDF_set_info_keywords

Fill the keywords document info field [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_set_info instead.

PDF_set_info_subject

Fill the subject document info field [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_set_info instead.

PDF_set_info_title

Fill the title document info field [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_set_info instead.

PDF_set_info

Fill document info field

说明

bool PDF_set_info ( resource $p , string $key , string $value )

Fill document information field key with value. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_set_layer_dependency

Define relationships among layers

说明

bool PDF_set_layer_dependency ( resource $pdfdoc , string $type , string $optlist )

Defines hierarchical and group relationships among layers. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function requires PDF 1.5.

PDF_set_leading

Set distance between text lines [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_set_value with the parameter leading instead.

PDF_set_parameter

Set string parameter

说明

bool PDF_set_parameter ( resource $p , string $key , string $value )

Sets some PDFlib parameter with string type. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_set_text_matrix

Set text matrix [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_scale, PDF_translate, PDF_rotate, or PDF_skew instead.

PDF_set_text_pos

Set text position

说明

bool PDF_set_text_pos ( resource $p , float $x , float $y )

Sets the position for text output on the page. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_set_text_rendering

Determine text rendering [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_set_value with the textrendering parameter instead.

PDF_set_text_rise

Set text rise [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_set_value with the textrise parameter instead.

PDF_set_value

Set numerical parameter

说明

bool PDF_set_value ( resource $p , string $key , float $value )

Sets the value of some PDFlib parameter with numerical type. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_set_word_spacing

Set spacing between words [deprecated]

说明

This function is deprecated since PDFlib version 3, use PDF_set_value with the wordspacing parameter instead.

PDF_setcolor

Set fill and stroke color

说明

bool PDF_setcolor ( resource $p , string $fstype , string $colorspace , float $c1 , float $c2 , float $c3 , float $c4 )

Sets the current color space and color. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_setdash

Set simple dash pattern

说明

bool PDF_setdash ( resource $pdfdoc , float $b , float $w )

Sets the current dash pattern to b black and w white units. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_setdashpattern

Set dash pattern

说明

bool PDF_setdashpattern ( resource $pdfdoc , string $optlist )

Sets a dash pattern defined by an option list. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_setflat

Set flatness

说明

bool PDF_setflat ( resource $pdfdoc , float $flatness )

Sets the flatness parameter. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_setfont

Set font

说明

bool PDF_setfont ( resource $pdfdoc , int $font , float $fontsize )

Sets the current font in the specified fontsize, using a font handle returned by PDF_load_font. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_setgray_fill

Set fill color to gray [deprecated]

说明

bool PDF_setgray_fill ( resource $p , float $g )

Sets the current fill color to a gray value between 0 and 1 inclusive. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 4, use PDF_setcolor instead.

PDF_setgray_stroke

Set stroke color to gray [deprecated]

说明

bool PDF_setgray_stroke ( resource $p , float $g )

Sets the current stroke color to a gray value between 0 and 1 inclusive. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 4, use PDF_setcolor instead.

PDF_setgray

Set color to gray [deprecated]

说明

bool PDF_setgray ( resource $p , float $g )

Sets the current fill and stroke color to a gray value between 0 and 1 inclusive. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 4, use PDF_setcolor instead.

PDF_setlinecap

Set linecap parameter

说明

bool PDF_setlinecap ( resource $p , int $linecap )

Sets the linecap parameter to control the shape at the end of a path with respect to stroking.

PDF_setlinejoin

Set linejoin parameter

说明

bool PDF_setlinejoin ( resource $p , int $value )

Sets the linejoin parameter to specify the shape at the corners of paths that are stroked. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_setlinewidth

Set line width

说明

bool PDF_setlinewidth ( resource $p , float $width )

Sets the current line width. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_setmatrix

Set current transformation matrix

说明

bool PDF_setmatrix ( resource $p , float $a , float $b , float $c , float $d , float $e , float $f )

Explicitly sets the current transformation matrix. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_setmiterlimit

Set miter limit

说明

bool PDF_setmiterlimit ( resource $pdfdoc , float $miter )

Sets the miter limit.成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_setpolydash

Set complicated dash pattern [deprecated]

说明

This function is deprecated since PDFlib version 5, use PDF_setdashpattern instead.

PDF_setrgbcolor_fill

Set fill rgb color values [deprecated]

说明

bool PDF_setrgbcolor_fill ( resource $p , float $red , float $green , float $blue )

Sets the current fill color to the supplied RGB values. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 4, use PDF_setcolor instead.

PDF_setrgbcolor_stroke

Set stroke rgb color values [deprecated]

说明

bool PDF_setrgbcolor_stroke ( resource $p , float $red , float $green , float $blue )

Sets the current stroke color to the supplied RGB values. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 4, use PDF_setcolor instead.

PDF_setrgbcolor

Set fill and stroke rgb color values [deprecated]

说明

bool PDF_setrgbcolor ( resource $p , float $red , float $green , float $blue )

Sets the current fill and stroke color to the supplied RGB values. 成功时返回 TRUE, 或者在失败时返回 FALSE

This function is deprecated since PDFlib version 4, use PDF_setcolor instead.

PDF_shading_pattern

Define shading pattern

说明

int PDF_shading_pattern ( resource $pdfdoc , int $shading , string $optlist )

Defines a shading pattern using a shading object.

This function requires PDF 1.4 or above.

PDF_shading

Define blend

说明

int PDF_shading ( resource $pdfdoc , string $shtype , float $x0 , float $y0 , float $x1 , float $y1 , float $c1 , float $c2 , float $c3 , float $c4 , string $optlist )

Defines a blend from the current fill color to another color.

This function requires PDF 1.4 or above.

PDF_shfill

Fill area with shading

说明

bool PDF_shfill ( resource $pdfdoc , int $shading )

Fills an area with a shading, based on a shading object.

This function requires PDF 1.4 or above.

PDF_show_boxed

Output text in a box [deprecated]

说明

int PDF_show_boxed ( resource $p , string $text , float $left , float $top , float $width , float $height , string $mode , string $feature )

This function is deprecated since PDFlib version 6, use PDF_fit_textline for single lines, or the PDF_*_textflow functions for multi-line formatting instead.

PDF_show_xy

Output text at given position

说明

bool PDF_show_xy ( resource $p , string $text , float $x , float $y )

Prints text in the current font. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_show

Output text at current position

说明

bool PDF_show ( resource $pdfdoc , string $text )

Prints text in the current font and size at the current position. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_skew

Skew the coordinate system

说明

bool PDF_skew ( resource $p , float $alpha , float $beta )

Skews the coordinate system in x and y direction by alpha and beta degrees, respectively. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_stringwidth

Return width of text

说明

float PDF_stringwidth ( resource $p , string $text , int $font , float $fontsize )

Returns the width of text in an arbitrary font.

PDF_stroke

Stroke path

说明

bool PDF_stroke ( resource $p )

Strokes the path with the current color and line width, and clear it. 成功时返回 TRUE, 或者在失败时返回 FALSE

PDF_suspend_page

Suspend page

说明

bool PDF_suspend_page ( resource $pdfdoc , string $optlist )

Suspends the current page so that it can later be resumed with PDF_resume_page.

PDF_translate

Set origin of coordinate system

说明

bool PDF_translate ( resource $p , float $tx , float $ty )

Translates the origin of the coordinate system.

PDF_utf16_to_utf8

Convert string from UTF-16 to UTF-8

说明

string PDF_utf16_to_utf8 ( resource $pdfdoc , string $utf16string )

Converts a string from UTF-16 format to UTF-8.

PDF_utf32_to_utf16

Convert string from UTF-32 to UTF-16

说明

string PDF_utf32_to_utf16 ( resource $pdfdoc , string $utf32string , string $ordering )

Converts a string from UTF-32 format to UTF-16.

PDF_utf8_to_utf16

Convert string from UTF-8 to UTF-16

说明

string PDF_utf8_to_utf16 ( resource $pdfdoc , string $utf8string , string $ordering )

Converts a string from UTF-8 format to UTF-16.

目录