View Single Post
Old 12-11-2010, 03:49 AM   #10
karunaji
Evangelist
karunaji ought to be getting tired of karma fortunes by now.karunaji ought to be getting tired of karma fortunes by now.karunaji ought to be getting tired of karma fortunes by now.karunaji ought to be getting tired of karma fortunes by now.karunaji ought to be getting tired of karma fortunes by now.karunaji ought to be getting tired of karma fortunes by now.karunaji ought to be getting tired of karma fortunes by now.karunaji ought to be getting tired of karma fortunes by now.karunaji ought to be getting tired of karma fortunes by now.karunaji ought to be getting tired of karma fortunes by now.karunaji ought to be getting tired of karma fortunes by now.
 
karunaji's Avatar
 
Posts: 421
Karma: 1033566
Join Date: Mar 2010
Location: Latvia
Device: Kindle 3 Wifi, Bookeen Opus
Post

I have suggestion how to improve line unwrapping a little bit. You only need to unwrap lines that are longer than certain threshold, for example, 50 chars. Shorter lines are probably headings, so do not remove line breaks for them.

Also, lines containing ------------ are used for underlining, so no removal of line breaks before and after them as well.

Python is not my forte but here is an example how it looks like: cables_201012102105.epub
karunaji is offline   Reply With Quote