public flatten ( ) : |
||
return | the pdf instance for method chaining |
public function flatten()
{
$this->getCommand()->addOption('flatten');
return $this;
}
public function testCanFlatten() { $document = $this->getDocument1(); $file = $this->getOutFile(); $pdf = new Pdf($document); $this->assertInstanceOf('mikehaertl\\pdftk\\Pdf', $pdf->flatten()); $this->assertTrue($pdf->saveAs($file)); $this->assertFileExists($file); $tmpFile = (string) $pdf->getTmpFile(); $this->assertEquals("pdftk A='{$document}' output '{$tmpFile}' flatten", (string) $pdf->getCommand()); }