Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre > Conversion

Notices

Reply
 
Thread Tools Search this Thread
Old 03-18-2012, 11:06 PM   #1
zippitydoda
Junior Member
zippitydoda began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Mar 2012
Device: Kindle
EPUB to mobi - new line after every bullet

I’m trying to convent from an EPUB document to a mobi document. Everything works great except Calibre adds a new line after every bullet in the list. Is there an option in Calibre to fix this?

Thanks.
zippitydoda is offline   Reply With Quote
Old 03-19-2012, 12:10 AM   #2
speakingtohe
Wizard
speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.
 
Posts: 4,812
Karma: 26912940
Join Date: Apr 2010
Device: sony PRS-T1 and T3, Kobo Mini and Aura HD, Tablet
Try remove space after paragraph under look and feel?

Helen
speakingtohe is offline   Reply With Quote
Old 03-22-2012, 12:57 AM   #3
zippitydoda
Junior Member
zippitydoda began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Mar 2012
Device: Kindle
I tried the option to remove space after paragraph, but that didn't work. There is still a Line
feed after every bullet and number. Any other thoughts?
zippitydoda is offline   Reply With Quote
Old 03-22-2012, 01:56 AM   #4
speakingtohe
Wizard
speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.speakingtohe ought to be getting tired of karma fortunes by now.
 
Posts: 4,812
Karma: 26912940
Join Date: Apr 2010
Device: sony PRS-T1 and T3, Kobo Mini and Aura HD, Tablet
Search and replace?
speakingtohe is offline   Reply With Quote
Old 03-25-2012, 11:38 AM   #5
eping
ePub Maker
eping began at the beginning.
 
eping's Avatar
 
Posts: 120
Karma: 16
Join Date: Dec 2009
Location: Mordor
Device: iPad,Kindle 3, Nook 2
It's a bug of Kindle, not Calibre.
The same file will show with no problem on Kindle Fire.
eping is offline   Reply With Quote
Old 03-25-2012, 12:41 PM   #6
dwig
Wizard
dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.
 
dwig's Avatar
 
Posts: 1,613
Karma: 6718479
Join Date: Dec 2004
Location: Paradise (Key West, FL)
Device: Current:Surface Go & Kindle 3 - Retired: DellV8p, Clie UX50, ...
Quote:
Originally Posted by zippitydoda View Post
I tried the option to remove space after paragraph, but that didn't work. There is still a Line
feed after every bullet and number. Any other thoughts?
How are you coding your list??

This code produces no extra line between bullet items when converted ePub>MOBI with either Calibre 0.8.44 or KindleGen2 (via Previewer 2):

Code:
<p>Bullet (unordered list):</p>
<ul>
  <li>Item 1</li>
  <li>Item 2</li>
  <li>Item 3</li>
</ul>
<p>what does it look like?? </p>
If you are referring to the "extra" blank line before and after the whole list, that's default behavior in the Kindle readers and most browsers. If you want to remove those spaces you need to style the <ul> tag. With this in the CSS the block of list items is set tight to be paragraph before and after:

Code:
ul {
  margin-top: 0m;
  margin-bottom: 0m;
  }
(note: The display in Sigil does not respect this CSS although ADE (on Windows) and calibre's ePub>MOBI conversion engine do.)

Interestingly, even without the CSS, the Preview/KindleGen2 conversion resulted in 1em spaces before and after the <UL> block when viewed on the Fire (KF8 partition) but was set tight as if the CSS was present when viewed on a K3 (PRC/MOBI partition)

Last edited by dwig; 03-25-2012 at 12:47 PM.
dwig is offline   Reply With Quote
Old 03-25-2012, 02:32 PM   #7
zippitydoda
Junior Member
zippitydoda began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Mar 2012
Device: Kindle
I don’t know if it’s a bug in Calibre or how styles are interpreted.

I do know that the EPUB document is displayed properly using the Sony Reader Library Version 3.3, and Calibre Version 0.8.44 E-Book Viewer.

After converting the document from EPUB to the Mobi format (default settings), I viewed the Mobi document using the following: Kindle PC Version 1.8.3, Kindle Previewer Version 2.31, Kindle Fire and Kindle Keyboard. All of these had a new line inserted after every bullet and numbered paragraph.

I even did a conversion to the HTMLZ format and viewed the HTML document with Google Chrome, and it still had the same problem.

I have looked at the HTML code (EPUB, HTMLZ), and they are very similar. So at this point I’m assuming it has something to do with how Calibre interprets styles during the conversion process.
zippitydoda is offline   Reply With Quote
Old 03-25-2012, 03:23 PM   #8
zippitydoda
Junior Member
zippitydoda began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Mar 2012
Device: Kindle
I don't have control of the source (EPUB file). I'm pulling the document from the web.
zippitydoda is offline   Reply With Quote
Old 03-25-2012, 03:28 PM   #9
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,754
Karma: 54401244
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 zippitydoda View Post
I don't have control of the source (EPUB file). I'm pulling the document from the web.
Sure you do, unless it is equipped with DRM (Which would also prevent conversion unless you did remove it. Then you have gained back control of the CSS )

Use the Tweak feature, and EDIT the CSS (or use Sigil to get at the whole EPUB).
Then convert to whatever format.
theducks is online now   Reply With Quote
Old 03-25-2012, 04:53 PM   #10
zippitydoda
Junior Member
zippitydoda began at the beginning.
 
Posts: 5
Karma: 10
Join Date: Mar 2012
Device: Kindle
I don't know if this helps or not.
The following is from the original EPUB document.

Code:
<div class="LISTbullet">
	<div class="listItem">
		<p class="label">•</p>
		<p id="lds-38"> Text Text Text</p>	
	</div>
	<div class="listItem">
		<p class="label">•</p>
		<p id="lds-39">Text Text Text</p>
	</div>
	<div class="listItem">
		<p class="label">•</p>
		<p id="lds-40">Text Text Text</p>
	</div>			
	<div class="listItem">
		<p class="label">•</p>
		<p id="lds-41">Text Text Text</p>
	</div>
	<div class="listItem">
		<p class="label">•</p>
		<p id="lds-42">Text Text Text</p>
	</div>
	<div class="listItem">
		<p class="label">•</p>
		<p id="lds-43">Text Text Text</p>
	</div>
</div>

This is what is looks like after I use Calibre to convert from EPUB to HTMLZ

Code:
<div class="titleBlock">
	<div class="titleBlock">
		<p class="seriesTitle">•</p>
		<p id="calibre_link-655" class="seriesTitle">Text Text Text</p>
	</div>
	<div class="titleBlock">
		<p class="seriesTitle">•</p>
		<p id="calibre_link-656" class="seriesTitle">Text Text Text</p>
	</div>
	<div class="titleBlock">
		<p class="seriesTitle">•</p>
		<p id="calibre_link-657" class="seriesTitle">Text Text Text</p>
	</div>
	<div class="titleBlock">
		<p class="seriesTitle">•</p>
		<p id="calibre_link-658" class="seriesTitle">Text Text Text</p>
	</div>
	<div class="titleBlock">
		<p class="seriesTitle">•</p>
		<p id="calibre_link-659" class="seriesTitle">Text Text Text</p>
	</div>
	<div class="titleBlock">
		<p class="seriesTitle">•</p>
		<p id="calibre_link-660" class="seriesTitle">Text Text Text</p>
	</div>
</div>
zippitydoda is offline   Reply With Quote
Old 03-25-2012, 05:34 PM   #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: 29,754
Karma: 54401244
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
Code:
<div class="listItem">
		<p class="label">•</p>
		<p id="lds-39">Text Text Text</p>
	</div>

It is a faked list
This is 2 paragraphs (and not a standard HTML bullet list to boot). Which is why 2 lines

This is one way for a single line
Code:
<div class="listItem">
		<p class="label" id="lds-39">• <span class="if_needed">
		Text Text Text</span></p>
	</div>
class if_needed allow you to control padding, font... for the text
theducks is online now   Reply With Quote
Old 05-15-2012, 02:20 PM   #12
ame67
Junior Member
ame67 began at the beginning.
 
Posts: 4
Karma: 10
Join Date: May 2012
Device: Kindle
Quote:
Originally Posted by dwig View Post
How are you coding your list??

This code produces no extra line between bullet items when converted ePub>MOBI with either Calibre 0.8.44 or KindleGen2 (via Previewer 2):

Code:
<p>Bullet (unordered list):</p>
<ul>
  <li>Item 1</li>
  <li>Item 2</li>
  <li>Item 3</li>
</ul>
<p>what does it look like?? </p>
If you are referring to the "extra" blank line before and after the whole list, that's default behavior in the Kindle readers and most browsers. If you want to remove those spaces you need to style the <ul> tag. With this in the CSS the block of list items is set tight to be paragraph before and after:

Code:
ul {
  margin-top: 0m;
  margin-bottom: 0m;
  }
(note: The display in Sigil does not respect this CSS although ADE (on Windows) and calibre's ePub>MOBI conversion engine do.)

Interestingly, even without the CSS, the Preview/KindleGen2 conversion resulted in 1em spaces before and after the <UL> block when viewed on the Fire (KF8 partition) but was set tight as if the CSS was present when viewed on a K3 (PRC/MOBI partition)
I was having the issue with the extra space before and after bullet lists and found that the top and bottom margin elements of the ul were no defined in my epub. When I set these the extra space was removed when I converted to mobi format in calibre.
Thanks for this
ame67 is offline   Reply With Quote
Old 05-15-2012, 07:15 PM   #13
amo48
Junior Member
amo48 began at the beginning.
 
Posts: 6
Karma: 10
Join Date: Jul 2011
Device: Kindle
Quote:
Originally Posted by zippitydoda View Post
I tried the option to remove space after paragraph, but that didn't work. There is still a Line
feed after every bullet and number. Any other thoughts?
You really need to look at the document in "code view" to see why this is happening. I think you would need to go in and delete XHTML <p> and </p> tags or <br> tags that appear in the text of the document. But you can't do this in Calibre. Bring up the file in Sigil (download this app if you don't have it), switch the view to "code view" and delete the appropriate tags. The extra lines should disappear.
amo48 is offline   Reply With Quote
Old 05-24-2012, 06:34 AM   #14
maff
Junior Member
maff began at the beginning.
 
Posts: 7
Karma: 10
Join Date: May 2012
Device: Mac, iPad, Kindle
I am also have the same problem with my EPUB files converted to MOBI using Calibre. The bullets display on a paragraph of their own. The attached photo shows an example (apologies for the quality!)

I have checked the EPUB file using Sigil and the lists are coded correctly:

Quote:
<p>Focusing back on London, the Market can be divided broadly into three categories of insurers:</p>

<ul>
<li>
<p>those operating in Lloyd’s;</p>
</li>

<li>
<p>insurance companies; and</p>
</li>

<li>
<p>mutual insurers.</p>
</li>
</ul>
Interestingly, the Kindle app does not display this error, and renders the list correctly. (See screen grab)

I'd be grateful for any help.
Attached Thumbnails
Click image for larger version

Name:	IMG-20120524-00003.jpg
Views:	365
Size:	78.4 KB
ID:	86794   Click image for larger version

Name:	Screen shot 2012-05-24 at 11.36.35.png
Views:	327
Size:	140.6 KB
ID:	86795  
maff is offline   Reply With Quote
Old 05-24-2012, 10:34 AM   #15
itimpi
Wizard
itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.
 
Posts: 4,552
Karma: 950151
Join Date: Nov 2008
Device: Sony PRS-950, iphone/ipad (Marvin/iBooks/QuickReader)
I think it is the <p> tags around the <li> text that is causing your problem. It is not unusual for a <p> tag to generate a new line at the display level. What is correct behaviour in this case I have no idea - I suspect it is implementation defined.
itimpi is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Epub converted to Mobi, hyperlinks jump to line after on Kindle dkingdesigner Conversion 21 07-07-2013 06:57 AM
Ebook conversion (EPUB to MOBI) via command line ebooklab Conversion 4 09-16-2011 09:34 PM
EPUB to MOBI - Extra Space on Bullet Lists squiggy Conversion 2 01-31-2011 10:50 AM
Command line convert ePub->MOBI mangles cover cscotts Calibre 7 12-14-2010 12:21 AM
bullets add a new line converting ePub to MOBI jomaweb Calibre 4 06-22-2010 11:13 AM


All times are GMT -4. The time now is 11:54 PM.


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