Skip to content

Commit

Permalink
Fix draw
Browse files Browse the repository at this point in the history
  • Loading branch information
Florian CELLIER committed Jun 10, 2015
1 parent 2e0497d commit ff40869
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions lib/draw/draw.php
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ function Curve($x0, $y0, $x1, $y1, $x2, $y2, $x3, $y3, $style = '', $line_style

$this->_Point($x0, $y0);
$this->_Curve($x1, $y1, $x2, $y2, $x3, $y3);
$this->_out($op);
$this->pdf->_out($op);
}

// Draws an ellipse
Expand Down Expand Up @@ -205,7 +205,7 @@ function Ellipse($x0, $y0, $rx, $ry = 0, $angle = 0, $astart = 0, $afinish = 360
$y0 = ($this->pdf->h - $y0) * $this->pdf->k;
if ($angle != 0) {
$a = -deg2rad((float) $angle);
$this->_out(sprintf('q %.2F %.2F %.2F %.2F %.2F %.2F cm', cos($a), -1 * sin($a), sin($a), cos($a), $x0, $y0));
$this->pdf->_out(sprintf('q %.2F %.2F %.2F %.2F %.2F %.2F cm', cos($a), -1 * sin($a), sin($a), cos($a), $x0, $y0));
$x0 = 0;
$y0 = 0;
}
Expand Down Expand Up @@ -234,9 +234,9 @@ function Ellipse($x0, $y0, $rx, $ry = 0, $angle = 0, $astart = 0, $afinish = 360
$c0 = $c1;
$d0 = $d1;
}
$this->_out($op);
$this->pdf->_out($op);
if ($angle !=0)
$this->_out('Q');
$this->pdf->_out('Q');
}
}

Expand Down Expand Up @@ -292,7 +292,7 @@ function Polygon($p, $style = '', $line_style = null, $fill_color = null) {
for ($i = 2; $i < ($np * 2); $i = $i + 2)
$this->_Line($p[$i], $p[$i + 1]);
$this->_Line($p[0], $p[1]);
$this->_out($op);
$this->pdf->_out($op);
}
$p[$np * 2] = $p[0];
$p[($np * 2) + 1] = $p[1];
Expand All @@ -306,7 +306,7 @@ function Polygon($p, $style = '', $line_style = null, $fill_color = null) {
for ($i = 2; $i < ($np * 2); $i = $i + 2)
$this->_Line($p[$i], $p[$i + 1]);
$this->_Line($p[0], $p[1]);
$this->_out($op);
$this->pdf->_out($op);
}
}

Expand Down

0 comments on commit ff40869

Please sign in to comment.