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-05-2013, 12:56 PM   #1
Benasam
Junior Member
Benasam began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Mar 2013
Device: iPad
Exclamation Stop Sigil from inserting unwanted lines between paragraphs

I've started using Sigil because my mac was inserting invisible files into ePubs that were creating problems on some platforms (iBookstore, for example).

The problems went away simply by opening the ePubs in Sigil and then saving them again.

Now, for some reason, Sigil is inserting extra lines between paragraphs. I've read some other threads, but they don't seem to solve this issue.

Originally, the codes say:
Quote:
<p class="s1">Sample text</p><p class="s1">More sample text</p>
But Sigil changes it to:
Quote:
<p class="s1">Sample text</p>
<p class="s1">More sample text</p>
When I use find and replace in Code View, the removed line breaks just reappear when I save.

Please help!
Attached Files
File Type: epub original.epub (418.9 KB, 357 views)
File Type: epub sigil.epub (411.6 KB, 361 views)

Last edited by Benasam; 03-05-2013 at 01:06 PM.
Benasam is offline   Reply With Quote
Old 03-05-2013, 01:08 PM   #2
meme
Sigil developer
meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.
 
Posts: 1,275
Karma: 1101600
Join Date: Jan 2011
Location: UK
Device: Kindle PW, K4 NT, K3, Kobo Touch
What you seem to be referring to are the blank lines between the <p>...</p> tags. These have no effect on how your book is displayed. The space between tags does not matter except for how readable your code is.

In 0.7.1 you can use Preferences->Clean Source and uncheck the Open and Save boxes and Sigil will no longer Pretty Print your source code on Open or Save.

Why iBookstore is having problems with your file is another question/forum.
meme is offline   Reply With Quote
Old 03-05-2013, 01:14 PM   #3
Benasam
Junior Member
Benasam began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Mar 2013
Device: iPad
Thanks, Meme. But I can't see why else there'd be extra spaces in the saved ePub.

I'm using Sigil 6.2 (my computer isn't running ios 10.7). Any idea what else could be causing this issue?
Benasam is offline   Reply With Quote
Old 03-05-2013, 02:13 PM   #4
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
It is no issue. It is not causing problems with your files, it just makes it more readable. It is correct code.
Toxaris is offline   Reply With Quote
Old 03-05-2013, 03:45 PM   #5
elibrarian
Imperfect Perfectionist
elibrarian ought to be getting tired of karma fortunes by now.elibrarian ought to be getting tired of karma fortunes by now.elibrarian ought to be getting tired of karma fortunes by now.elibrarian ought to be getting tired of karma fortunes by now.elibrarian ought to be getting tired of karma fortunes by now.elibrarian ought to be getting tired of karma fortunes by now.elibrarian ought to be getting tired of karma fortunes by now.elibrarian ought to be getting tired of karma fortunes by now.elibrarian ought to be getting tired of karma fortunes by now.elibrarian ought to be getting tired of karma fortunes by now.elibrarian ought to be getting tired of karma fortunes by now.
 
elibrarian's Avatar
 
Posts: 464
Karma: 724664
Join Date: Dec 2011
Location: Ølstykke, Denmark
Device: none
The culprit seems to be the style="white-space:pre-wrap". When that is set, the empty lines set by Sigil will be rendered as just that - empty lines. Remove it, and everything looks ok.

- I think ...

Regards,

Kim
elibrarian is offline   Reply With Quote
Old 07-03-2013, 09:50 AM   #6
brinded
Member
brinded began at the beginning.
 
Posts: 11
Karma: 10
Join Date: Jul 2013
Device: iPad2
Quote:
The culprit seems to be the style="white-space:pre-wrap". When that is set, the empty lines set by Sigil will be rendered as just that - empty lines. Remove it, and everything looks ok.
I'm having the same problem. I've noticed other similar posts, particularly when ePub is derived from Apple Pages/Export.

Where does this "white-space:pre-wrap" come from? Is there a way to avoid it?

thanks,

Last edited by Jellby; 07-03-2013 at 10:28 AM. Reason: remove spurious smileys
brinded is offline   Reply With Quote
Old 07-03-2013, 01:05 PM   #7
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
Probably caused by Apple Pages. Avoid it by using another program, solve it by removing it.
Toxaris is offline   Reply With Quote
Old 07-03-2013, 03:23 PM   #8
Hitch
Bookmaker & Cat Slave
Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.
 
Hitch's Avatar
 
Posts: 11,462
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
Quote:
Originally Posted by Benasam View Post
I've started using Sigil because my mac was inserting invisible files into ePubs that were creating problems on some platforms (iBookstore, for example).

The problems went away simply by opening the ePubs in Sigil and then saving them again.

Now, for some reason, Sigil is inserting extra lines between paragraphs. I've read some other threads, but they don't seem to solve this issue.

Originally, the codes say:


But Sigil changes it to:


When I use find and replace in Code View, the removed line breaks just reappear when I save.

Please help!
I have to say, I prefer the lines of whitespace for readability. I've had a number of Pages-exported ePUBs sent to me, and they are literally unreadable--not even line breaks between paragraphs, etc. Absolute garbage to try to "fix."

I'll take the lines in Sigil any day. They're harmless, AFAIK, and I've never seen an issue with them.

Hitch
Hitch is offline   Reply With Quote
Old 05-21-2014, 09:33 PM   #9
tmarsh1
Junior Member
tmarsh1 began at the beginning.
 
Posts: 2
Karma: 10
Join Date: May 2014
Device: Kindle
Here's my experience with this frustrating bug.

Removing the white-space:pre-wrap doesn't fix things.
It appears to be random. In smaller epubs, it seems ok, but I opened a larger one (90 pages) and these extra lines appear.
It's NOT css, it's NOT Pages.
The template generating these files in Pages is exactly the same, the files both have images, tables etc. I use styles to manage line heights etc.

I had the two clean checkboxes checked (on Save) which I think is what causes it.

I use Apple Pages as it supports intra-document linking, whereas Word on Mac does not (Bookmarks are a nightmare).

I basically can't pin this down to anything. The Sigil forums simply pour scorn on Pages, but I don't think it's pages.

It seems to occur randomly. I've unchecked Tidy too. And will report back.

Last edited by Jellby; 05-22-2014 at 03:29 AM. Reason: noparse
tmarsh1 is offline   Reply With Quote
Old 05-21-2014, 10:24 PM   #10
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 27,548
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
With the exception of when the "whitespace" style attribute exists (which can be used externally, internally, or inline), blank spaces between block elements in the html code have no bearing on how that code is rendered. None. If the "whitespace" attribute doesn't exist anywhere in your css or html files, then any unwanted spacing between elements has to be the fault of some other styling (or lack thereof) present in the html or css.

If you simply prefer to have total control over the spacing/indentation of your html code for aesthetic purposes, then turn off all Clean Source settings in the preferences. If your xhtml is already well-formed and error free, it won't be altered (provided you're using one of the latest versions of Sigil).
DiapDealer is offline   Reply With Quote
Old 05-22-2014, 03:23 AM   #11
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
Quote:
Originally Posted by tmarsh1 View Post
Here's my experience with this frustrating bug.
It is NOT a bug. It is to make your code more readable. It is intentional. Something that is intentional cannot be a bug...
Empty lines in Codeview (and Pretty Print in general) will help you to read and understand the code better.
Toxaris is offline   Reply With Quote
Old 05-22-2014, 05:50 AM   #12
BobC
Guru
BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.
 
Posts: 691
Karma: 3026110
Join Date: Dec 2008
Location: Lancashire, U.K.
Device: BeBook 1, BeBook Pure, Kobo Glo, (and HD),Energy Sistem EReader Pro +
If you want to find out why you are getting the unwanted spacing have you tried opening the file with Sigil and then using "inspect element" from the context menu in book view to show just what is contributing to it ?

BobC
BobC is offline   Reply With Quote
Old 05-22-2014, 05:03 PM   #13
Hitch
Bookmaker & Cat Slave
Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.Hitch ought to be getting tired of karma fortunes by now.
 
Hitch's Avatar
 
Posts: 11,462
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
Quote:
Originally Posted by tmarsh1 View Post
Here's my experience with this frustrating bug.

Removing the white-space:pre-wrap doesn't fix things.
It appears to be random. In smaller epubs, it seems ok, but I opened a larger one (90 pages) and these extra lines appear.
It's NOT css, it's NOT Pages.
The template generating these files in Pages is exactly the same, the files both have images, tables etc. I use styles to manage line heights etc.

I had the two clean checkboxes checked (on Save) which I think is what causes it.

I use Apple Pages as it supports intra-document linking, whereas Word on Mac does not (Bookmarks are a nightmare).

I basically can't pin this down to anything. The Sigil forums simply pour scorn on Pages, but I don't think it's pages.

It seems to occur randomly. I've unchecked Tidy too. And will report back.
Can you show us a screenshot of what you're getting? it's still not clear to me if you mean, the whitespace between lines of CODE, in Codeview, or between elements of the book (paragraphs, whatever), in the finished product. Upon what device or reader are you viewing this for inspection, and can you screenshoot us a) the problem and b) the code?

Plus, you'll need to give us the code, BOTH the HTML and the CSS, between CODE tags, thanks. (And a spoiler tag, if they are lengthy). We don't need to see all of your book; just the html for the section in which the problem is occurring and the relevant CSS.) Otherwise, we're nailing jello to the walls, here. You say this:

Quote:
Removing the white-spacere-wrap doesn't fix things.
It appears to be random. In smaller epubs, it seems ok, but I opened a larger one (90 pages) and these extra lines appear.
...but we don't have any examples to look at. I don't know what you're getting, and thus, don't know what to say. So, if you'll provide, we'll help.

Hitch
Hitch is offline   Reply With Quote
Old 05-23-2014, 03:58 AM   #14
tmarsh1
Junior Member
tmarsh1 began at the beginning.
 
Posts: 2
Karma: 10
Join Date: May 2014
Device: Kindle
Quote:
Originally Posted by Toxaris View Post
It is NOT a bug. It is to make your code more readable. It is intentional. Something that is intentional cannot be a bug...
Empty lines in Codeview (and Pretty Print in general) will help you to read and understand the code better.
Beg to differ.
Using styles, I have para spacing (white space).
This is spacing in the WYSIWYG view. Not the code view.

I removed the pre white space wrap, fixed.
I previously tried that, and it didn't fix it.

Cheers
tmarsh1 is offline   Reply With Quote
Old 05-23-2014, 07:55 AM   #15
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
If you read my comment closely, I only talk about CODEVIEW, not BOOKVIEW.

Also the white-space:pre-wrap is something that is added by pages and can give serious issues with lines not breaking and continue off screen.
Toxaris is offline   Reply With Quote
Reply

Tags
breaks, code, line breaks, paragraph, sigil


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Smashwords inserting blank vertical gifs in unwanted places? Keloff ePub 4 12-11-2011 10:20 AM
Sigil 0.4.1 : unwanted span added by Sigil Bertrand Sigil 0 09-02-2011 05:28 AM
Can I stop Sigil from inserting sgc formatting commands? ramjet1953 Sigil 4 11-22-2010 11:59 AM
inserting blank lines into rtf/txt/html errata Ectaco jetBook 7 07-10-2010 09:16 PM
Unwanted space between paragraphs superanima Calibre 3 10-14-2009 02:28 PM


All times are GMT -4. The time now is 12:11 AM.


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