Skip to content

Commit

Permalink
note on example
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolaasuni committed Aug 17, 2024
1 parent fdd2274 commit 9b434a6
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions examples/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -1436,16 +1436,16 @@

// ----------

// XOBject template
// XOBject template (@TODO: fix the implementation)

$pageC02 = $pdf->page->add();

$tid = $pdf->newXObjectTemplate(60, 60, []);
$tid = $pdf->newXObjectTemplate(80, 80, []);

$xcnz = $pdf->graph->getStartTransform();
$xcnz .= $pdf->graph->getStarPolygon(0, 0, 40, 10, 3, 0, 'CNZ');
$timg = $pdf->image->add('../vendor/tecnickcom/tc-lib-pdf-image/test/images/200x100_CMYK.jpg');
$xcnz .= $pdf->image->getSetImage($timg, 0, 0, 50, 50, $pageC02['height']);
$xcnz = $pdf->graph->getStarPolygon(50, 50, 40, 10, 3, 0, 'CNZ');
$timg = $pdf->image->add('../vendor/tecnickcom/tc-lib-pdf-image/test/images/200x100_GRAY.png');
$xcnz .= $pdf->image->getSetImage($timg, 10, 10, 80, 80, $pageC02['height']);
$xcnz .= $pdf->graph->getStopTransform();

$pdf->addXObjectImageID($tid, $timg);
Expand All @@ -1455,10 +1455,10 @@

$tmpl = $pdf->getXObjectTemplate(
$tid,
15,
50,
20,
20,
0,
0,
80,
80,
'T',
'L',
);
Expand Down

0 comments on commit 9b434a6

Please sign in to comment.