Hello all.
Question regarding the text formatting modules out there. I've found three on
CPAN that seem to have the functionality that I'm looking for but I don't know
which would best suit my needs. The three are Text::Format, Text::Wrapper and
Text::Autoformat.
I have a script which populates and email with data that gets laid out in the
following manner:
customer_name
Ticket ID Subject hh:mm
-----------------------------------------------------------------
###### Random Ticket Subject Line ##:##
However, the subject length is not a constant. It can be quite short (maybe a
few characters long) to much longer than the alloted space I've given using
'printf'. So, I'd like to be able to do things like wrap the text at a certain
length so that it might look something like this:
customer_name
Ticket ID Subject hh:mm
-----------------------------------------------------------------
###### Random Ticket Subject Line Which Might End Up ##:##
Longer Than The Allocated Space Using printf
###### Next Random Ticket Subject Line ##:##
Of the three formatting options I've found, which might be my best bet to handle
something of this nature. Also, after deciding which is the better option, how
would I go about printing the data out? Can I populate variables with
pre-formatted text or would I perhaps do something with a printf command that
uses a call to one of the formatting methods?
Any help would be appreciated.
Thanks
Mathew
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/