karun.jiju has asked for the wisdom of the Perl Monks concerning the following question:
I used the module Text::Format to format the text after 70 columns. The text used for formating is "The Email Issue (matter getting shattering/ numbers coming in between etc..) was addressed to Jiju and he is looking into this with highest priority. This will be fixed ASAP." But the output after formatting is a bit different than expected.In the output after the first two words ie.,after 'The Email Issue' the next words are coming in new line.The output and code is given below
Output is "The Email Issue
(matter getting shattering/ numbers coming in between
etc..) was
addressed to jiju and he is looking into this with highest
priority. This will be fixed ASAP."
use Text::Format; $body = "The Email Issue (matter getting shattering/ numbers coming in between etc..) was addressed to jiju and he is looking into this with + highest priority. This will be fixed ASAP."; $body = Text::Format->new({columns => 70,firstIndent => 0})->form +at($body); print $body;
The output i needed is each line should contain 70 characters that is
"The Email Issue (matter getting shattering/ numbers coming in between
etc..) was addressed to Jiju and he is looking into this with highest
priority. This will be fixed ASAP."
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: text formatting
by ikegami (Patriarch) on Feb 16, 2010 at 09:15 UTC | |
by karun.jiju (Initiate) on Feb 16, 2010 at 09:34 UTC | |
by Animator (Hermit) on Feb 16, 2010 at 09:56 UTC | |
by ikegami (Patriarch) on Feb 16, 2010 at 16:46 UTC | |
by karun.jiju (Initiate) on Feb 17, 2010 at 08:50 UTC | |
by ikegami (Patriarch) on Feb 17, 2010 at 12:35 UTC |