\BCGFontPhp

Summary

Methods
Properties
Constants
__construct()
getText()
setText()
getRotationAngle()
setRotationAngle()
getBackgroundColor()
setBackgroundColor()
getForegroundColor()
setForegroundColor()
getDimension()
draw()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
$font
$text
$rotationAngle
$backgroundColor
$foregroundColor
N/A

Properties

$font

$font : 

Type

$text

$text : 

Type

$rotationAngle

$rotationAngle : 

Type

$backgroundColor

$backgroundColor : 

Type

$foregroundColor

$foregroundColor : 

Type

Methods

__construct()

__construct(integer  $font) 

Constructor.

Parameters

integer $font

getText()

getText() : string

Gets the text associated to the font.

Returns

string

setText()

setText(  $text) 

Sets the text associated to the font.

Parameters

$text

getRotationAngle()

getRotationAngle() : integer

Gets the rotation in degree.

Returns

integer

setRotationAngle()

setRotationAngle(  $rotationAngle) 

Sets the rotation in degree.

Parameters

$rotationAngle

getBackgroundColor()

getBackgroundColor() : \BCGColor

Gets the background color.

Returns

\BCGColor

setBackgroundColor()

setBackgroundColor(\BCGColor  $backgroundColor) 

Sets the background color.

Parameters

\BCGColor $backgroundColor

getForegroundColor()

getForegroundColor() : \BCGColor

Gets the foreground color.

Returns

\BCGColor

setForegroundColor()

setForegroundColor(\BCGColor  $foregroundColor) 

Sets the foreground color.

Parameters

\BCGColor $foregroundColor

getDimension()

getDimension() : array<mixed,integer>

Returns the width and height that the text takes to be written.

Returns

array<mixed,integer>

draw()

draw(resource  $im, integer  $x, integer  $y) 

Draws the text on the image at a specific position.

$x and $y represent the left bottom corner.

Parameters

resource $im
integer $x
integer $y