Make Paragraphs
Moderators: DataMystic Support, Moderators, DataMystic Support, Moderators, DataMystic Support, Moderators
-
- Posts: 8
- Joined: Tue Feb 09, 2010 7:26 pm
Make Paragraphs
I have used textsoap on mac , with a feature which gives the option of make paragraph from the text below , there are extra spaces as you can see from the body of the text. I cannot find anything like this in Remove menu .
South African White Corn Falls as Rand Gains Against Dollar
By Mkhululi Mancotywa
March 15 (Bloomberg) -- White corn in South Africa, the
largest producer of the grain on the continent, fell as the rand
rose, cutting the cost of imports for local millers.
The rand traded at 7.3994 against the dollar at 9:25 a.m.
in Johannesburg, compared with 7.4015 at the close of trading at
noon March 12.
South African White Corn Falls as Rand Gains Against Dollar
By Mkhululi Mancotywa
March 15 (Bloomberg) -- White corn in South Africa, the
largest producer of the grain on the continent, fell as the rand
rose, cutting the cost of imports for local millers.
The rand traded at 7.3994 against the dollar at 9:25 a.m.
in Johannesburg, compared with 7.4015 at the close of trading at
noon March 12.
-
- Posts: 11
- Joined: Mon Aug 25, 2008 9:16 pm
- Location: Dublin and Manila
- Contact:
Re: Make Paragraphs
Hi pakiyabhai,
I think this is something that could be done in TextPipe.
What do you want to do exactly? Can you post the output of the text you would like to see.
Anthony.
I think this is something that could be done in TextPipe.
What do you want to do exactly? Can you post the output of the text you would like to see.
Anthony.
http://www.TheLocalizer.com/
High Quality, Low Cost, Localization Engineering, Testing, Audio & Video Services
High Quality, Low Cost, Localization Engineering, Testing, Audio & Video Services
-
- Posts: 8
- Joined: Tue Feb 09, 2010 7:26 pm
Re: Make Paragraphs
From
To
Code: Select all
South African White Corn Falls as Rand Gains Against Dollar
By Mkhululi Mancotywa
March 15 (Bloomberg) -- White corn in South Africa, the
largest producer of the grain on the continent, fell as the rand
rose, cutting the cost of imports for local millers.
The rand traded at 7.3994 against the dollar at 9:25 a.m.
in Johannesburg, compared with 7.4015 at the close of trading at
noon March 12.
To
Code: Select all
South African White Corn Falls as Rand Gains Against Dollar By Mkhululi Mancotywa March 15 (Bloomberg) -- White corn in South Africa, the largest producer of the grain on the continent, fell as the rand rose, cutting the cost of imports for local millers. The rand traded at 7.3994 against the dollar at 9:25 a.m.in Johannesburg, compared with 7.4015 at the close of trading at noon March 12.
- DataMystic Support
- Site Admin
- Posts: 2227
- Joined: Mon Jun 30, 2003 12:32 pm
- Location: Melbourne, Australia
- Contact:
Re: Make Paragraphs
Use an EasyPattern like this, to replace runs of spaces tabs and line breaks with a single space.
ie
Code: Select all
[ longest 1+ (space or tab or cr or lf) ]
Code: Select all
EasyPattern [[ longest 1+ (space or tab or cr or lf) ]] with [ ]
[ ] Match case
[ ] Whole words only
[ ] Case sensitive replace
[X] Prompt on replace
[ ] Skip prompt if identical
[ ] First only
[ ] Extract matches
Maximum text buffer size 4096
-
- Posts: 8
- Joined: Tue Feb 09, 2010 7:26 pm
Re: Make Paragraphs
hanks for the reply , you were close but something did go wrong , the output comes with no space at all now , something like . I did precisely what you asked me to used a replace filter with easy pattern.
Update , in replace column i entered one single space and it worked.
Can you tell me whta does cr or lf mean & what would the perl equivalent of this command be ?
Code: Select all
SouthAfricanWhiteCornFallsasRandGainsAgainstDollarByMkhululiMancotywaMarch15(Bloomberg)--WhitecorninSouthAfrica,thelargestproducerofthegrainonthecontinent,fellastherandrose,cuttingthecostofimportsforlocalmillers.Therandtradedat7.3994againstthedollarat9:25a.m.inJohannesburg,comparedwith7.4015atthecloseoftradingatnoonMarch12.
Can you tell me whta does cr or lf mean & what would the perl equivalent of this command be ?
- DataMystic Support
- Site Admin
- Posts: 2227
- Joined: Mon Jun 30, 2003 12:32 pm
- Location: Melbourne, Australia
- Contact:
Re: Make Paragraphs
Glad you realized you had missed the space in the replacement!
CR is a carriage return. LF is a line feed. TextPipe hides these details for you - you don't need to know the technical details at all when you use EasyPatterns in TextPipe.
CR is a carriage return. LF is a line feed. TextPipe hides these details for you - you don't need to know the technical details at all when you use EasyPatterns in TextPipe.
Re: Make Paragraphs
thanks for this post...it was time to fix this problem:)
-
- Posts: 8
- Joined: Tue Feb 09, 2010 7:26 pm
Re: Make Paragraphs
there is a small error which I am facing with this now .
This seems to remove ALL the spaces between the paragraphs as well and my news becomes one long string.
Can I modify this to respects paragraphs or maybe 2 spaces ?
This seems to remove ALL the spaces between the paragraphs as well and my news becomes one long string.
Can I modify this to respects paragraphs or maybe 2 spaces ?
- DataMystic Support
- Site Admin
- Posts: 2227
- Joined: Mon Jun 30, 2003 12:32 pm
- Location: Melbourne, Australia
- Contact:
Re: Make Paragraphs
PLease attach the filter as a zip file, with sample text in the Trial Run area.