Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre

Notices

Reply
 
Thread Tools Search this Thread
Old 08-26-2020, 12:57 PM   #1
motsaw
Junior Member
motsaw began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Aug 2020
Device: Kindle
How can I remove unnecessary space

Hello.
How can I remove unnecessary space between words during conversion? Maybe some calibre plugin can do it, or there's some option in calibre, that I can't find? Please look at the screenshot.
Please point me to the proper thread if this was resolved already.
motsaw is offline   Reply With Quote
Old 08-26-2020, 01:02 PM   #2
hobnail
Running with scissors
hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.
 
Posts: 1,587
Karma: 14328510
Join Date: Nov 2019
Device: none
Can you provide the original file? Looks to me like there are incorrect p tags. What are you converting from? Converting to?
hobnail is offline   Reply With Quote
Advert
Old 08-26-2020, 01:16 PM   #3
motsaw
Junior Member
motsaw began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Aug 2020
Device: Kindle
Quote:
Originally Posted by hobnail View Post
Can you provide the original file? Looks to me like there are incorrect p tags. What are you converting from? Converting to?
Of course, here:

I'm trying to convert from mobi to mobi (just to get it better formated), but have some epub files with this bug as well.

Last edited by BetterRed; 08-26-2020 at 05:30 PM. Reason: OP Request - remove link to file
motsaw is offline   Reply With Quote
Old 08-26-2020, 01:29 PM   #4
hobnail
Running with scissors
hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.
 
Posts: 1,587
Karma: 14328510
Join Date: Nov 2019
Device: none
That may still be under copyright so you should probably delete your link. Maybe someone here who knows more can explain what's going on without seeing the file.
hobnail is offline   Reply With Quote
Old 08-26-2020, 01:32 PM   #5
motsaw
Junior Member
motsaw began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Aug 2020
Device: Kindle
Ok, can I send you a PM?
I can't edit my previus post anymore, but the file is deleted from the hosting.
motsaw is offline   Reply With Quote
Advert
Old 08-26-2020, 01:53 PM   #6
gbm
Wizard
gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.
 
Posts: 2,188
Karma: 8888888
Join Date: Jun 2010
Device: Kobo Clara HD,Hisence Sero 7 Pro RIP, Nook STR, jetbook lite
Quote:
Originally Posted by motsaw View Post
Hello.
How can I remove unnecessary space between words during conversion? Maybe some calibre plugin can do it, or there's some option in calibre, that I can't find? Please look at the screenshot.
Please point me to the proper thread if this was resolved already.
Convert to epub or azw then open using the editor and use this regex to find and join the split paragraphs:
Edit:
Search
Code:
</p>\s*<p[^>]+>([a-z0-9])
Replace
Code:
 \1
bernie

Last edited by gbm; 08-26-2020 at 02:30 PM. Reason: edit the seach
gbm is offline   Reply With Quote
Old 08-26-2020, 01:53 PM   #7
hobnail
Running with scissors
hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.
 
Posts: 1,587
Karma: 14328510
Join Date: Nov 2019
Device: none
Probably better to wait for someone who knows more about this than I do to respond.
hobnail is offline   Reply With Quote
Old 08-26-2020, 09:03 PM   #8
retiredbiker
Evangelist
retiredbiker ought to be getting tired of karma fortunes by now.retiredbiker ought to be getting tired of karma fortunes by now.retiredbiker ought to be getting tired of karma fortunes by now.retiredbiker ought to be getting tired of karma fortunes by now.retiredbiker ought to be getting tired of karma fortunes by now.retiredbiker ought to be getting tired of karma fortunes by now.retiredbiker ought to be getting tired of karma fortunes by now.retiredbiker ought to be getting tired of karma fortunes by now.retiredbiker ought to be getting tired of karma fortunes by now.retiredbiker ought to be getting tired of karma fortunes by now.retiredbiker ought to be getting tired of karma fortunes by now.
 
retiredbiker's Avatar
 
Posts: 450
Karma: 3886916
Join Date: May 2013
Location: Ontario, Canada
Device: Kindle KB, Oasis, Pop_Os!, Kobo Forma
These are the kind of wrapped lines you typically get from a pdf conversion, and are probably in the original file. It is caused by each line being coded as its own paragraph.

Try converting to epub with heuristic processing turned on in the conversion options. This will probably fix a lot of it, but as the name implies, it guesses at where to unwrap. So it will almost certainly make some mistakes. Once you have the epub version, you can open it in the editor and fix the remainder using search and replace like gbm suggested. Then convert to a Kindle format.
retiredbiker is offline   Reply With Quote
Old 08-27-2020, 01:30 AM   #9
motsaw
Junior Member
motsaw began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Aug 2020
Device: Kindle
Ok, I'll try. Thanks for help.
motsaw is offline   Reply With Quote
Old 08-27-2020, 10:28 AM   #10
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 79,752
Karma: 145864619
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Are these conversions from PDF? If so, don't bother.
JSWolf is offline   Reply With Quote
Old 08-27-2020, 11:19 AM   #11
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 31,055
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
PDF conversions are the worst to start from. They (the content) can appear random because it is a 'paste up' format.
Put 'a' there.
Put 'g' there.
put 'b' here.
The RESULTS is the PDF page you see. It looks perfect (because it was what was wanted in the end)

Jon is a little harsh. Try, then see if it looks fixable (all the pieces are in the proper ORDER), or a basket case (what you showed, seems fixable)

Then clean up using the Editor (I found doing multiple conversions with different settings, took more time than doing edits using saved 'join' searches. I have 4 or 5, I tweak (to match the code I see) and use, rather than do a 'catch all' pass. This also tends to let me run into other issues, since I look at a lot of the final pages
theducks is offline   Reply With Quote
Old 08-27-2020, 11:44 AM   #12
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 79,752
Karma: 145864619
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
I'm not being harsh. I'm being honest. If this is not something that has to be converted, then I would not bother. It's not worth the hassle. And unless you A/B compare everything, you most likely have errors no matter how you try to clean it up.

For example, in the sample posted of the conversion, How do you know if the two sentences go together to form one paragraph or not? You can tell the sentence fragments go together, but you cannot automate knowing if the two sentences go together.

Last edited by JSWolf; 08-27-2020 at 11:48 AM.
JSWolf is offline   Reply With Quote
Old 08-27-2020, 01:04 PM   #13
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 31,055
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
Quote:
Originally Posted by JSWolf View Post

For example, in the sample posted of the conversion, How do you know if the two sentences go together to form one paragraph or not? You can tell the sentence fragments go together, but you cannot automate knowing if the two sentences go together.
(and that would fail on any automated combine)
But it would be closer to pleasing the eye than what they have now.

Been a long time since I have seen an error free (at least that I did not detect) book.
Spell check is only ONE check. (I have no issue with the other versions of en_XX spelling). Wrong (Gimme a BRAKE )
theducks is offline   Reply With Quote
Old 08-27-2020, 04:07 PM   #14
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 79,752
Karma: 145864619
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by theducks View Post
(and that would fail on any automated combine)
But it would be closer to pleasing the eye than what they have now.
But the thing is, you would need to compare the PDF to the ePub and while doing that you would have to read the PDF. So just reaf the PDF anyway and forget converting.

Been a long time since I have seen an error free (at least that I did not detect) book.
Spell check is only ONE check. (I have no issue with the other versions of en_XX spelling). Wrong (Gimme a BRAKE )[/QUOTE]

I've seen a fair number of eBooks that I did not find a text error. I'm not saying there werenone.Just that I did not notiice if there was.
JSWolf is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Remove periods (and the space that follows) when author's name has initials droopy Library Management 10 11-05-2019 05:07 PM
How to remove any space between sentences? rockster Conversion 12 12-11-2012 01:18 PM
How to remove white space between paragraphs for iPad? kabloooie Conversion 4 05-28-2012 05:11 AM
Heuristic "Remove unnecessary hyphens" not working? therealjoeblow Conversion 2 03-06-2012 10:21 AM
Is there any way to remove space between paragraphs? kabloooie Calibre 6 11-03-2010 08:32 AM


All times are GMT -4. The time now is 01:24 PM.


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