my $pdf=PDF::API2->new; my $font = $pdf->corefont('Helvetica'); my $page = $pdf->page(); $page->mediabox('A4'); $page->rotate(90); # to landscape my $content = $page->text(); $content->font($font,12); $content->transform( -rotate => 90, -translate => [100,500], ); $content->text("This text should appear on the left half of the A4 Landscape page"); my $photo = $page->gfx; my $photo_file = $pdf->image_jpeg("image.jpg"); $photo->save; # does not rotate correctly because I don't quite understand the translate part $photo->transform( -rotate => 90, -translate => [my $_x = 0, my $_y = 0], ); $photo->image($photo_file, 50, 360, 200, 200); $photo->restore; $pdf->saveas("test.pdf"); $pdf->end;