Public Method Details |
ImlibText |
public void ImlibText( )
|
|
ImlibText constructor
|
Returns |
void |
|
draw |
public bool draw( int $x, int $y, string $str, [ string $dir ] )
|
|
Draw a text string onto the current image
|
Parameter |
|
int |
$x |
|
|
coordinate of the upper left corner of the string |
|
|
int |
$y |
|
|
coordinate of the upper left corner of the string |
|
|
string |
$str |
|
|
string to draw |
|
|
string |
$dir |
= >>IMLIB_TEXT_TO_RIGHT<< |
|
of the text |
|
Returns |
bool False if no font is loaded |
|
free |
public bool free( )
|
|
Free the currently loaded font
|
Returns |
bool False if no font is loaded |
|
get_image |
public integer get_image( )
|
|
Get the current image resource id#
|
Returns |
integer Image resource id# |
|
get_size |
public bool get_size( string $str, int &$w, int &$h, [ string $dir ] )
|
|
Get the width and height of a given string if it were drawn
|
Parameter |
|
|
|
int |
&$w |
|
|
Width the string would be |
|
|
int |
&$h |
|
|
Height the string would be |
|
|
string |
$dir |
= >>IMLIB_TEXT_TO_RIGHT<< |
|
to measure the string |
|
Returns |
bool False if no font is loaded |
|
load |
public bool load( string $path, string $font, int $size )
|
|
Load a font
If the font is in the font path, it can be referred to by font name,and the path does not need to be specified. Otherwise, it must bereferred to by filename.
|
Parameter |
|
string |
$path |
|
|
, or current directory if passed blank |
|
|
|
|
|
Returns |
bool False if no font is loaded |
|
set_image |
public void set_image( int $im )
|
|
Set the image resource id# to draw on
|
Parameter |
|
|
Returns |
void |
|