2 $sur = new CairoImageSurface(FORMAT_ARGB32
, 8, 8);
3 $con = new CairoContext($sur);
5 $con->setSourceRgb(0,0,1);
8 $con->rectangle(2,2,4,4);
10 $con->setSourceRgb(1,0,0);
14 $s = $con->getGroupTarget();
16 $con->setSourceRgb(0,1,0);
18 $off = $s->getDeviceOffset();
21 $con->rectangle(2, 2, 4, 4);
23 $con->popGroupToSource();
26 $sur->writeToPng("get-group-target-php.png");