Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re^3: Better way to add text to PDFs?

by BigLug (Chaplain)
on Jul 14, 2005 at 23:16 UTC ( [id://475082]=note: print w/replies, xml ) Need Help??


in reply to Re^2: Better way to add text to PDFs?
in thread Better way to add text to PDFs?

Your code works for me .. remember from my tutorial that the origin is the lower left, so look there for your text.

If you want it anywhere else, then $text->translate($x,$y) before you set your text (in your code, after the fillcolor.

If that doesn't work for some strange reason, then let me know what version of PDF::API2 you're using, and any other relevant information.

Cheers!
Rick Measham

Replies are listed 'Best First'.
Re^4: Better way to add text to PDFs?
by friedo (Prior) on Jul 15, 2005 at 18:12 UTC
    Thanks for taking a look, BigLug. I'm afraid the results are the same, even if I use translate to move the text about. Note that there's no problem creating new PDFs, e.g. if I use PDF::API2->new instead of open, and page instead of openpage. If I do that, I get a nice big "Wahoo!" exactly where I expect it, so I know it's not a problem with fonts, or the geometry. But I've had no luck whatsoever in modifying existing PDFs.

    FWIW, $PDF::API2::VERSION is 1.081.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (6)
As of 2024-03-28 13:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found