#!/usr/bin/perl
require
"./pango00.pl"
;
my
$surface
= Cairo::PdfSurface->create(
'pango04.pdf'
, 595, 842 );
my
$cr
= Cairo::Context->create(
$surface
);
my
$layout
= Pango::Cairo::create_layout(
$cr
);
my
$PANGO_SCALE
= Pango->scale;
my
$font
= Pango::FontDescription->from_string(
'AR PL New Sung 60'
);
$layout
->set_font_description(
$font
);
$layout
->get_context->set_base_gravity(
'west'
);
my
$x
= 0;
my
$y
= 842-700;
$layout
->set_width( 595 *
$PANGO_SCALE
);
$layout
->set_alignment(
"left"
);
$layout
->set_markup(
"懶惰的姜貓"
);
$cr
->translate(300,100);
$cr
->rotate(2
*atan2
(1,1));
showlayout(
$cr
,
$layout
,
$x
,
$y
);
$cr
->show_page;