function pacman() { $chart = new GooglePieChart('p', 130, 100); $data = new GoogleChartData(array(80, -20)); $data->setColor('f9f900'); $chart->addData($data); $chart->setFill('73A2BD'); // I pass null to enable the "legend" trick $data = new GoogleChartData(null); $data->setColor('73A2BD'); $data->setLegend('O O O'); $chart->addData($data); $chart->setLegendPosition('r'); $chart->setRotation(0.628); return $chart->getUrl(); }