Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: Wrap eats newlines

by arden (Curate)
on Jun 18, 2004 at 16:05 UTC ( #367979=note: print w/replies, xml ) Need Help??


in reply to Wrap eats newlines

eznoh, not to be mean, but RTFM! From the description of Text::Wrap, "It will destory any whitespace in the original text." That includes the extra newline character. Now, if you use  Text::Wrap::wrap() individually on each paragraph, you can then add the extra newline yourself.

- - arden.

Replies are listed 'Best First'.
Re^2: Wrap eats newlines
by eznoh (Initiate) on Jun 18, 2004 at 19:43 UTC
    I did RTFM, I guess I should have asked, is there an easy way to do what I want or a different function to use? Thanks!

      Since you know that Text::Wrap eats the whitespace, you can put the newline(s) back yourself.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://367979]
help
Chatterbox?
[choroba]: fortunately, I haven't the need to verify this
[choroba]: haven't had
[choroba]: but most tourist here are form the US, France, and Russia
[Your Mother]: The best whiskey in Thailand is Vietnamese, is all I know.

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (5)
As of 2017-02-26 05:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Before electricity was invented, what was the Electric Eel called?






    Results (371 votes). Check out past polls.