Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

PDF::API2 multi-line, wrapped, header paragraph?

by buttroast (Scribe)
on Nov 30, 2005 at 05:01 UTC ( [id://512851]=perlquestion: print w/replies, xml ) Need Help??

buttroast has asked for the wisdom of the Perl Monks concerning the following question:

Hello, I am trying to generate a bunch of PDF files that contain photos. At the top of each file, I would like to print out the photograph source information (date taken, name of person, etc.). I would like this to be a multi-line paragraph. I know how to write single lines of text, but can't seem to figure out how to write a paragraph. Any help would be appreciated.
Thanks buttroast
  • Comment on PDF::API2 multi-line, wrapped, header paragraph?

Replies are listed 'Best First'.
Re: PDF::API2 multi-line, wrapped, header paragraph?
by kulls (Hermit) on Nov 30, 2005 at 08:01 UTC
      Thanks for the sample code link. Isn't there anything already built into the module so I don't have to use that much code? In one tutorial I found, it mentioned there was a 'paragraph' method, but it didn't work. I think maybe the module underwent some changes since the tutorial was written.
      Thanks buttroast
        Hi, indeed you can use the paragraph method, but like all parts of the pdf::api2 module, it is not to well documented. at first, all lines where printed on top of each other, but that was because i forgot to add a txt->lead() line like in $txt->textstart; $txt->lead(13); $txt->font($font{'bold'},10); $txt->translate($x,$y); $txt->paragraph("$SysDescr", $TextWidth, $ParagrapHeight, align => "left" );

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://512851]
Approved by planetscape
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (3)
As of 2024-04-19 21:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found