diff --git a/library/Icinga/Chart/PieChart.php b/library/Icinga/Chart/PieChart.php index 7e80738ac..ac3772428 100644 --- a/library/Icinga/Chart/PieChart.php +++ b/library/Icinga/Chart/PieChart.php @@ -122,7 +122,7 @@ class PieChart extends Chart */ public function toSvg(RenderContext $ctx) { - $outerBox = new Canvas('outerGraph', new LayoutBox(0, 0, 100, 100)); + $outerBox = new Canvas('outerGraph', new LayoutBox(33, -5, 40, 40)); $innerBox = new Canvas('graph', new LayoutBox(0, 0, 100, 100)); $labelBox = $ctx->getDocument()->createElement('g'); if (!$this->noCaption) { diff --git a/library/Icinga/Chart/Primitive/PieSlice.php b/library/Icinga/Chart/Primitive/PieSlice.php index 631013d69..33f3cbee7 100644 --- a/library/Icinga/Chart/Primitive/PieSlice.php +++ b/library/Icinga/Chart/Primitive/PieSlice.php @@ -159,7 +159,7 @@ class PieSlice extends Animatable implements Drawable // Draw the handle $path = new Path(array($midX, $midY)); - $midX += ($addOffset + $r/1.8) * ($midRadius > M_PI ? -1 : 1); + $midX += ($addOffset + $r/3) * ($midRadius > M_PI ? -1 : 1); $path->append(array($midX, $midY))->toAbsolute(); $midX += intval($r/2 * sin(M_PI/9)) * ($midRadius > M_PI ? -1 : 1);