note 92241 modified in function.imagickdraw-setfontsize by danbrown

From: Date: Wed, 15 Jul 2009 13:26:40 +0000
Subject: note 92241 modified in function.imagickdraw-setfontsize by danbrown
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-158340@lists.php.net to get a copy of this message
<?php $sourceFile='in.jpg'; $textWrite='God is Great'; $x=50; $y=50; $fontColor='#000000'; $fontSize=34; $colorPix=new ImagickPixel ($fontColor); $image=new Imagick ($sourceFile); $draw=new ImagickDraw(); $draw->setFontSize($fontSize);//Sets the font pointsize to use when annotating with text $draw->setFillColor($colorPix);//Sets the fill color to be used for drawing filled objects $image->annotateImage($draw,$x,$y,0,$textWrite);//Annotates an image with text $image->writeImage('out.jpg');//Writes an image to the specified filename ?> --was-- $sourceFile='in.jpg'; $textWrite='God is Great'; $x=50; $y=50; $fontColor='#000000'; $fontSize=34; $colorPix=new ImagickPixel ($fontColor); $image=new Imagick ($sourceFile); $draw=new ImagickDraw(); $draw->setFontSize($fontSize);//Sets the font pointsize to use when annotating with text $draw->setFillColor($colorPix);//Sets the fill color to be used for drawing filled objects $image->annotateImage($draw,$x,$y,0,$textWrite);//Annotates an image with text $image->writeImage('out.jpg');//Writes an image to the specified filename http://php.net/manual/en/function.imagickdraw-setfontsize.php

« previous php.notes (#158340) next »