I do a lot of printing (point of sales stuff). Generally, i to all the layouting ("printing") on a PNG of the correct pixel size, then send that off to a printer. Either directly as PNG when using CUPS, or converting it to printer specific encoding (ESC/POS for thermal receipt printers; ZPL for Zebra-compatible label printers).

As for specific implementations, i can't really recommend any. This is (for me, i've been doing this a long time) such a standard problem that i just usually write the few lines of code required by hand. Basically, you make the 5 strings, calculate where you want to position it in the PNG and you're done. If you want to go that route: I like to use GD

PerlMonks XP is useless? Not anymore: XPD - Do more with your PerlMonks XP
Also check out my sisters artwork and my weekly webcomics

In reply to Re: Printing Labels by cavac
in thread Printing Labels by Bod

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • 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:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.