how to change font size when write picture
| From: | liu zhen | Date: | Mon, 20 Nov 2000 03:23:09 +0000 |
| Subject: | how to change font size when write picture | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-26187@lists.php.net to get a copy of this message | ||
hi:
I am a new user. I want to make a program which will make a button.
I draw the button but when I write text at it, I have meet some question.
First , I do not know how to change the text size.The system give 5 font
size, but I want define the size by myself.Please help me , thank you .
the source is under here.
$im = imagecreate($width,$height);
$imagebackcolor = ImageColorAllocate($im,
intval("0x".substr($backcolor,0,2),16),intval("0x".substr($backcolor,2,2),16),intval("0x".substr($backcolor,4,2),16));
$imagetextcolor = ImageColorAllocate($im,
intval("0x".substr($textcolor,0,2),16),intval("0x".substr($textcolor,2,2),16),intval("0x".substr($textcolor,4,2),16));
imagestring($im, $textfont,$textplacex, $textplacey, $text, $imagetextcolor);
Imagejpeg($im);
ImageDestroy($im);