Packageindex Classtrees Modulegroups Elementlist Report XML Files

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

pc4p_text

pc4p_object
   |
  +-- pc4p_text

Text object provides text-funktionality

 

private class pc4p_text extends pc4p_object

Text object provides text-funktionality

AuthorsAlexander Wirtz <wirtz@web-active.com>

 

Methods inherited from pc4p_object

pc4p_object, pc4p_set_margin, pc4p_set_width, pc4p_set_alignment, pc4p_set_textleading, pc4p_draw_children

Public Method Summary

void

pc4p_text(object pc4p_page &$parent)

Constructor
void

pc4p_set_font(string $fontname, [ integer $fontsize, string $encoding ])

Sets the font for this object.
void

pc4p_set_text(string $text)

Sets the text which the object shall print later on
void

pc4p_set_underline()

Shall the text have an underline?
void

pc4p_draw()

Draws the text for the set fontoptions.Warning: documentation is missing.

Private Method Summary

integer

pc4p_linefeed(string &$text)

Formats the text for the actual width and inserts | where a newline
integer

pc4p_calc_alignment(string $text)

Calculates the position of the text according to the set alignment
int

pc4p_calc_offset(object pc4p_page &$parent)

Calculates the stringwidth for the current text and font in theWarning: documentation is missing.

Fields inherited from pc4p_object

$children, $pdfp, $width, $height, $act_width, $act_height, $draw_height, $alignment, $leading

Private Field Summary

array

$margin

Margins for this text
string

$fontname

Fontname for this text
integer

$fontsize

Fontsize for this text
string

$encoding

Encoding used for this text
integer

$underline

Underline for this text
string

$text

Text for this text...haha

Public Method Details

pc4p_text

public void pc4p_text( object pc4p_page &$parent )

  Constructor

Parameter
object pc4p_page &$parent
Returns void

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

pc4p_set_font

public void pc4p_set_font( string $fontname, [ integer $fontsize, string $encoding ] )

  Sets the font for this object.

Parameter
string $fontname
integer $fontsize = >>10<<
string $encoding = >>"host"<<
Returns void

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

pc4p_set_text

public void pc4p_set_text( string $text )

  Sets the text which the object shall print later on

Parameter
string $text
Returns void

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

pc4p_set_underline

public void pc4p_set_underline( )

  Shall the text have an underline?

Returns void

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

pc4p_draw

public void pc4p_draw( )

  Draws the text for the set fontoptions.

Warning: documentation is missing.

Returns void

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

Private Method Details

pc4p_linefeed

private integer pc4p_linefeed( string &$text )

  Formats the text for the actual width and inserts | where a newline
shall occur during print out. Returns the rows which the text needs.

Parameter
string &$text
Returns integer $rowcount

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

pc4p_calc_alignment

private integer pc4p_calc_alignment( string $text )

  Calculates the position of the text according to the set alignment

Parameter
string $text
Returns integer $act_width

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

pc4p_calc_offset

private int pc4p_calc_offset( object pc4p_page &$parent )

  Calculates the stringwidth for the current text and font in the
object and applies linefeed where necessary. Returns the sizefor the complete object.

Warning: documentation is missing.

Parameter
object pc4p_page &$parent
Returns int $this

->height

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

Private Field Details

$margin

private array $margin

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

Margins for this text


$fontname

private string $fontname

>>"Times-Roman"<<

Fontname for this text


$fontsize

private integer $fontsize

>>10<<

Fontsize for this text


$encoding

private string $encoding

>>"host"<<

Encoding used for this text


$underline

private integer $underline

>><<

Underline for this text


$text

private string $text

>><<

Text for this text...haha



Packageindex Classtrees Modulegroups Elementlist Report XML Files
PHPDoc 1.0beta