note 16678 added to function.imagearc

From: Date: Thu, 08 Nov 2001 18:04:58 +0000
Subject: note 16678 added to function.imagearc
Groups: php.notes 
Request: Send a blank email to php-notes+get-20613@lists.php.net to get a copy of this message
Round cornered anti-aliased dynamically sized button. $w=40; $h=20; $im = ImageCreate($w,$h); $white=ImageColorAllocate($im,255,255,255); ImageFilledRectangle($im,0,0,$w,$h,$white); imagecolortransparent ($im, $white); ImageTTFText ($im, $h+ceil($h/3)+1, 0, -1, $h-1, $col1, "arialbd.ttf", "O"); ImageTTFText ($im, $h+ceil($h/3)+1, 0, $w-$h, $h-1, $col1, "arialbd.ttf", "O"); ImageTTFText ($im, $h+ceil($h/3)+1, 0, 1, $h-1, $col1, "arialbd.ttf", "O"); ImageTTFText ($im, $h+ceil($h/3)+1, 0, $w-$h-2, $h-1, $col1, "arialbd.ttf", "O"); $points=array( 1,round($h/2), round($h/4),$h-round($h/4), round($h/2),$h, $w-(round($h/2)),$h, $w-(round($h/4)),$h-round($h/4), $w-2,round($h/2), $w-round($h/4),round($h/4), $w-round($h/2),0, round($h/2),0, round($h/4),round($h/4) ); imagefilledpolygon ($im, $points, 10, $col1); header("content-type: image/gif"); header("Content-Disposition: filename=name.gif"); ImageGif($im); ImageDestroy($im); -- http://www.php.net/manual/en/function.imagearc.php http://master.php.net/manage/user-notes.php?action=edit+16678 http://master.php.net/manage/user-notes.php?action=delete+16678 http://master.php.net/manage/user-notes.php?action=reject+16678

« previous php.notes (#20613) next »