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-19-2010, 08:54 AM   #1
JayLaFunk
Connoisseur
JayLaFunk will become famous soon enoughJayLaFunk will become famous soon enoughJayLaFunk will become famous soon enoughJayLaFunk will become famous soon enoughJayLaFunk will become famous soon enoughJayLaFunk will become famous soon enough
 
JayLaFunk's Avatar
 
Posts: 94
Karma: 538
Join Date: Nov 2009
Device: iPad
Removing unwanted white space

Hi Valloric,

First of all thanks for your app been using for search & replace to clean up some ebooks but I have a few ebooks that I need to clean up and remove unwanted white spaces, I am opening them up in Sigil in code view and I'm trying to use the tip below but I can't see yellow color text in code view, this will prob be a very easy thing to do to for most people but I'm not that clued up to editing, could someone post a screen grab and show me how to do what I want...

Regards
Jay

To remove the white space between the paragraphs, add this to the bottom of the CSS code (the yellow color text in the Code View):

p {margin: 0; padding: 0;}

This will affect only the paragraph spacing. To remove all the whitespace between the various elements and make the document look more "book like", use this code:

body, div, p, h1, h2, h3, h4 { margin: 0; padding: 0; }
JayLaFunk is offline   Reply With Quote
Old 03-19-2010, 09:36 AM   #2
Valloric
Created Sigil, FlightCrew
Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.
 
Valloric's Avatar
 
Posts: 1,982
Karma: 350515
Join Date: Feb 2008
Device: Kobo Clara HD
OK, which version of Sigil are you using? The 0.2.0 betas or 0.1.9?

The CSS code will probably be in a different CSS file if you're using 0.2.0. You should see a file in the "Styles" folder in the Book Browser.
Valloric is offline   Reply With Quote
Advert
Old 03-19-2010, 09:50 AM   #3
JayLaFunk
Connoisseur
JayLaFunk will become famous soon enoughJayLaFunk will become famous soon enoughJayLaFunk will become famous soon enoughJayLaFunk will become famous soon enoughJayLaFunk will become famous soon enoughJayLaFunk will become famous soon enough
 
JayLaFunk's Avatar
 
Posts: 94
Karma: 538
Join Date: Nov 2009
Device: iPad
Quote:
Originally Posted by Valloric View Post
OK, which version of Sigil are you using? The 0.2.0 betas or 0.1.9?

The CSS code will probably be in a different CSS file if you're using 0.2.0. You should see a file in the "Styles" folder in the Book Browser.
Hi,

I am using 0.1.9 (Win 7), would I be better to upgrade to 0.2.0

Jay
JayLaFunk is offline   Reply With Quote
Old 03-19-2010, 11:29 AM   #4
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: 29,778
Karma: 54830978
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 JayLaFunk View Post
Hi,

I am using 0.1.9 (Win 7), would I be better to upgrade to 0.2.0

Jay
0.2 is very much Beta. There is a file name with spaces bug that will be corrected in the next release. Removing spaces from files inside the EPUB is a PITA if there are very many splits.
theducks is offline   Reply With Quote
Old 03-19-2010, 11:33 AM   #5
roger64
Wizard
roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.
 
Posts: 2,608
Karma: 3000161
Join Date: Jan 2009
Device: Kindle PW3 (wifi)
Beware, I am just a beginner on CSS. This time I succeeded to reduce the white space between paragraphs.

The epub text is coming from a foreign source and has been converted from an odt file by calibre as an EPUB .

I opened this epub file with Sigil 0.2, I looked at an xhtml file with code view and I identified the P11 paragraph style as being the most used (why? mystery?) : see joint texte.png on the right

I then opened the css stylesheet at P11 and reduced to zero the values of margin-bottom and margin-top which were set at 1em (all the others values related to margin and padding were already at zero): see joint style.png

That was enough to do the trick.

I am not sure at all this is academic but it works. Now I have one line between paragraphs instead of three.
Attached Thumbnails
Click image for larger version

Name:	style.png
Views:	766
Size:	16.2 KB
ID:	48385   Click image for larger version

Name:	texte.png
Views:	688
Size:	13.2 KB
ID:	48386  

Last edited by roger64; 03-19-2010 at 11:45 AM. Reason: typos
roger64 is offline   Reply With Quote
Advert
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to reduce indents without "removing space between paragraphs" Skydog Calibre 5 06-05-2010 12:58 AM
Unwanted space between paragraphs superanima Calibre 3 10-14-2009 02:28 PM
Horror White, Frederick M.: The Great White Moth v1 23 apr 2009 mtravellerh ePub Books 0 04-23-2009 06:06 AM
Horror White, Fred Merrick: The Four White Days. V1. 7 Dec 2008 crutledge IMP Books 0 12-07-2008 12:12 PM
Horror White, Fred Merrick: The Four White Days. V1. 7 Dec 2008 crutledge Kindle Books 0 12-07-2008 12:05 PM


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


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