Oh wise monk brothers and sisters,
I would like to create a PDF file from a list of strings I have generated. The list is as follows:
@text = ( "text 0x000000FF 0x00009283",
" text2 0x0000000FF 0x00000002",
" text3 0x000000101 0x00000064",
... and so forth );
I would like text to print out on a page in my PDF file as:
text 0x000000FF 0x00009283
text2 0x0000000FF 0x00000002
text3 0x000000101 0x00000064
My problem is that
PDF::API2 has very poor documentation. I attemped to combine all the lines into a string and use the
text->paragraph method. However, the newline characters are not recognised. I'm thinking that you could determine the height of each line and use that to
translate the next line to the appropriate point. The text should also span multiple pages as needed. Unfortunately, I've run into quite a lot of difficulties due my inexperience with this module.
Update:
I should also mention, that the first page will consist of a graphic
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.