|
From: <le...@pr...> - 2005-01-23 11:39:03
|
Update of /cvsroot/meshdb/www/db2 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16195 Modified Files: Tag: leonard-dev map4b.php Log Message: correct string placement to match location plots Index: map4b.php =================================================================== RCS file: /cvsroot/meshdb/www/db2/map4b.php,v retrieving revision 1.4 retrieving revision 1.4.2.1 diff -u -d -r1.4 -r1.4.2.1 --- map4b.php 9 May 2004 03:32:30 -0000 1.4 +++ map4b.php 23 Jan 2005 11:38:55 -0000 1.4.2.1 @@ -53,7 +53,7 @@ ImageLine($im, $x-1, $y-1, $x+1, $y+1, $col); ImageLine($im, $x+1, $y-1, $x-1, $y+1, $col); if ($shownumbers) - ImageString($im, 1, $x+2, $y+2, $name, $namecol); + ImageString($im, 1, $x+4, $y-4, $name, $namecol); } /* Clip x1 to lie between 0 and maxx */ @@ -70,16 +70,18 @@ return array($x1, $y1); } -$im = @ImageCreate($w, $h) - or die("ImageCreate"); +$im = @ImageCreateTrueColor($w, $h) + or die("ImageCreateTrueColor"); +ImageAlphaBlending($im, FALSE); +ImageSaveAlpha($im, TRUE); -$BLACK = ImageColorAllocate($im, 0, 0, 0); -$WHITE = ImageColorAllocate($im, 255, 255, 255); -$BLUE = ImageColorAllocate($im, 64, 64, 255); -$RED = ImageColorAllocate($im, 255, 0, 0); -$GREY = ImageColorAllocate($im, 128, 128, 128); -$LIGHTGREY = ImageColorAllocate($im, 255, 220, 220); -$LIGHTBLUE = ImageColorAllocate($im, 220, 220, 255); +$BLACK = ImageColorAllocateAlpha($im, 0, 0, 0, 128); +$WHITE = ImageColorAllocateAlpha($im, 255, 255, 255, 255); +$BLUE = ImageColorAllocateAlpha($im, 64, 64, 255, 128); +$RED = ImageColorAllocateAlpha($im, 255, 0, 0, 128); +$GREY = ImageColorAllocateAlpha($im, 128, 128, 128, 128); +$LIGHTGREY = ImageColorAllocateAlpha($im, 255, 220, 220, 128); +$LIGHTBLUE = ImageColorAllocateAlpha($im, 220, 220, 255, 128); ImageFilledRectangle($im, 0, 0, $w, $h, $WHITE); |