Packageindex Classtrees Modulegroups Elementlist Report XML Files

File: /data/customers/alex/htdocs/include/pc4p_page.inc
PC4P - pc4p

pc4p_page

pc4p_page

Supplies pagehandling ability

 

private class pc4p_page

Supplies pagehandling ability

AuthorsAlexander Wirtz <wirtz@web-active.com>

 

Public Method Summary

void

pc4p_page(object pc4p_page &$parent, string $format, string $dimensions)

Constructor
void

pc4p_set_margin(array $margin)

Sets the margins for the page
void

pc4p_set_bgimage(string $imgfile, string $imgtype, integer $xoffset, integer $yoffset, [ float $scale ])

Sets a background image for this page
void

pc4p_draw(object pc4p_main &$parent)

Begins the page with the dimensions, calls the draw for each child

Private Method Summary

void

pc4p_draw_children()

Calls the draw function for each child in the children-array
void

pc4p_calc_offset(object pc4p_page &$parent)

Calls the calc_offset function in all children. Checks, if the current object

Private Field Summary

array

$children

Array of all children of this object
integer

$pdfp

PDF-Pointer used for all pdf_*
integer

$width

Width of the page
integer

$height

Height of the page
array

$margin

Margins for the page
integer

$act_width

x-Pos where the page really starts placing objects
integer

$act_height

y-Pos where the page really starts placing objects
integer

$draw_height

y-Pos used when calculating the positions for the objects
string

$bg_image

Name of the background image
string

$bgi_type

Type of the background image
integer

$bgi_xoff

x-Pos for the background image
integer

$bgi_yoff

y-Pos for the background image
float

$bgi_scale

Scale for the background image

Public Method Details

pc4p_page

public void pc4p_page( object pc4p_page &$parent, string $format, string $dimensions )

  Constructor

Parameter
object pc4p_page &$parent
string $format
string $dimensions
Returns void

Author(s) Alexander Wirtz <wirtz@web-active.com>

pc4p_set_margin

public void pc4p_set_margin( array $margin )

  Sets the margins for the page

Parameter
array $margin
Returns void

Author(s) Alexander Wirtz <wirtz@web-active.com>

pc4p_set_bgimage

public void pc4p_set_bgimage( string $imgfile, string $imgtype, integer $xoffset, integer $yoffset, [ float $scale ] )

  Sets a background image for this page

Parameter
string $imgfile
string $imgtype
integer $xoffset
integer $yoffset
float $scale = >>1<<
Returns void

Author(s) Alexander Wirtz <wirtz@web-active.com>

pc4p_draw

public void pc4p_draw( object pc4p_main &$parent )

  Begins the page with the dimensions, calls the draw for each child
and closes the page.Called as last function in the class.

Parameter
object pc4p_main &$parent
Returns void

Author(s) Alexander Wirtz <wirtz@web-active.com>

Private Method Details

pc4p_draw_children

private void pc4p_draw_children( )

  Calls the draw function for each child in the children-array

Returns void

Author(s) Alexander Wirtz <wirtz@web-active.com>

pc4p_calc_offset

private void pc4p_calc_offset( object pc4p_page &$parent )

  Calls the calc_offset function in all children. Checks, if the current object
still fits onto the page. If not, it checks if there's a following page; ifnot, it creates one, if yes it uses the existing. Moves the overlappingobjects to the new page. In one word: Here's the pagebreak function!!!

Parameter
object pc4p_page &$parent
Returns void

Author(s) Alexander Wirtz <wirtz@web-active.com>

Private Field Details

$children

private array $children

>>array()<<

Array of all children of this object


$pdfp

private integer $pdfp

>><<

PDF-Pointer used for all pdf_*


$width

private integer $width

>><<

Width of the page


$height

private integer $height

>><<

Height of the page


$margin

private array $margin

>>array( "top" => 5, "bottom" => 5, "left" => 5, "right" => 5 )<<

Margins for the page


$act_width

private integer $act_width

>><<

x-Pos where the page really starts placing objects


$act_height

private integer $act_height

>><<

y-Pos where the page really starts placing objects


$draw_height

private integer $draw_height

>><<

y-Pos used when calculating the positions for the objects


$bg_image

private string $bg_image

>><<

Name of the background image


$bgi_type

private string $bgi_type

>><<

Type of the background image


$bgi_xoff

private integer $bgi_xoff

>><<

x-Pos for the background image


$bgi_yoff

private integer $bgi_yoff

>><<

y-Pos for the background image


$bgi_scale

private float $bgi_scale

>><<

Scale for the background image



Packageindex Classtrees Modulegroups Elementlist Report XML Files
PHPDoc 1.0beta