⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 tutorial-howto.pod

📁 PDF-API2-0.2.3.7_dev.tar.gz
💻 POD
字号:
=head1 PDF::API2 TUTORIAL and HOWTO

=head2 Document

=head2 Fonts and Text

=head3 Core Fonts

=item Q: How to use text with a 'corefont' ?

B<Answer:> Noting's simpler than this if you know which fonts are defined:

	Courier Courier-Bold Courier-BoldOblique Courier-Oblique
	Helvetica Helvetica-Bold Helvetica-BoldOblique Helvetica-Oblique
	Times-Roman Times-Bold Times-BoldItalic Times-Italic
	Symbol ZapfDingbats
	
B<Example:>

	$pdf=PDF::API2->new;
	$helv = $pdf->corefont('Helvetica');
	$timb = $pdf->corefont('Times-Bold');
	$zapf = $pdf->corefont('ZapfDingbats');
	$page = $pdf->page;
	$txt = $page->text;
	$txt->font($helv,20);
	$txt->text('Hello Helvetica !');
	$txt->cr;
	$txt->font($timb,20);
	$txt->text('Hello Times-Bold !');
	$txt->cr;
	$txt->font($zapf,20);
	$txt->text('Hello ZapfDingbats !');
	
B<Result:>

=for pod3pdf corefont Helvetica Helv

=for pod3pdf corefont Times-Bold TimB

=for pod3pdf corefont ZapfDingbats Zapf

=begin pod3pdf(400,70) 

BT
1 0 0 1 0 40 Tm 15 TL 
/Helv 15 Tf (Hello Helvetica !) Tj T* 
/TimB 15 Tf (Hello Times-Bold !) Tj T* 
/Zapf 15 Tf (Hello ZapgDingbats !) Tj 
ET

=end pod3pdf

*TODO*

=head2 Images

*TODO*

=begin pod3pdf(400,200)

 0 0 m 400 200 l S

=end pod3pdf

=xfor pod3pdf image examples/tou.jpg 0.33

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -