Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 03-06-2013, 01:27 PM   #1
skammer1974
Junior Member
skammer1974 began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Mar 2013
Device: none
I need help with text wrap...

Would someone assist me in fixing the text wrap issue I am having when I bring in epub file converted from PDF using Calibre. For example, here is a sample:

text text text text text text text text text text
text text text text text te
xt text text text text text t
ext text text

If you notice the text are broke apart at the right margin. Is there a way to fix this for efficiently without having to use the backspace keys?

I hope this makes sense. skammer1974
skammer1974 is offline   Reply With Quote
Old 03-06-2013, 02:25 PM   #2
Doitsu
Grand Sorcerer
Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.
 
Doitsu's Avatar
 
Posts: 5,680
Karma: 23983815
Join Date: Dec 2010
Device: Kindle PW2
Quote:
Originally Posted by skammer1974 View Post
Would someone assist me in fixing the text wrap issue I am having when I bring in epub file converted from PDF using Calibre.
You most likely didn't activate the Heuristisc Processing options (Heuristic Processing > Enable heuristic Processing), which are by default disabled. Try to convert the .pdf file again with all Heuristic options enabled.

This should take care of some of the issues.
Doitsu is offline   Reply With Quote
Old 03-06-2013, 04:36 PM   #3
Toxaris
Wizard
Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.
 
Toxaris's Avatar
 
Posts: 4,520
Karma: 121692313
Join Date: Oct 2009
Location: Heemskerk, NL
Device: PRS-T1, Kobo Touch, Kobo Aura
Also learn the basics of RegEx S&R. That will help.
Toxaris is offline   Reply With Quote
Old 03-06-2013, 07:28 PM   #4
Tex2002ans
Wizard
Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.
 
Posts: 2,306
Karma: 13057279
Join Date: Jul 2012
Device: Kobo Forma, Nook
Converting a document from PDF is the WORST case scenario. It will take a lot of elbow grease to fix the document after conversion.

I personally use these two Regexes to help combine broken paragraphs:

Search #1:

Code:
-</p>\s+<p>
Replace #1: (empty)

Search #2:

Code:
([^>”\?\!\.])</p>\s+<p>
Replace #2: (a space is following the 1)

Code:
\1
Search #1 will take a line that ends with a hyphen, erase the hyphen, and combine it with the next line (you may/may not want to keep the hyphen, I replace one at a time to make sure the hyphen is not needed).

Search #2 will look for a paragraph NOT ending with any of the characters in red, and will combine it with the next paragraph.

For cleaning up directly from calibre's output you may need to use these Regexes for search instead:

Code:
-</p>\s+<p class="calibre[0-9]+">
Code:
([^>”\?\!\.])</p>\s+<p class="calibre[0-9]+">
Tex2002ans is offline   Reply With Quote
Reply

Tags
text wrap, text wrapping


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Floats, images, text-wrap --- need advice GrannyGrump ePub 11 09-06-2012 09:14 AM
TEXT WRAP AROUND IMAGES RKEP71 Sigil 1 06-20-2011 08:26 PM
Wrap Text Around Picture - Mobi Bull06 Conversion 6 03-23-2011 11:52 AM
Help - text won't wrap around Images WRB Sigil 2 02-11-2011 01:46 AM
LRF and wrap-around text Seabound Calibre 13 12-28-2008 03:30 PM


All times are GMT -4. The time now is 10:18 AM.


MobileRead.com is a privately owned, operated and funded community.