View Full Version : problem with spacing between paragraphs in ADE


iain robinson
06-15-2011, 02:52 PM
Hi all

I have several files with bulleted lists, which are followed by "normal" paragraphs, all styled by my CSS file. Everything looks good when viewed in Sigil (and iBooks I think – haven’t got access to an iPad at the moment) but the problem is when viewed in ADE or the Sony Reader Library software (which I understand uses the ADE engine) sometimes there's a gap between the bullet list and the next para and sometimes not. Looking at the code in Sigil I can't see any difference between one instance where in ADE it looks wrong and another where it looks right.

Example which looks right;

<p class="main-text-no-para-indent">blah blah blah could usefully be considered when reviewing cloud providers’ T&amp;Cs:</p>

<ul>
<li class="bulleted-list"><span class="bullet">•</span> What legal system do the T&amp;Cs claim to be governed by; are there any limits on where, how or when a legal claim can be brought against the provider?</li>

<li class="bulleted-list"><span class="bullet">•</span> Does the provider exclude or limit liability for damage, particularly consequential damages such as business losses?</li>
</ul>

<p class="main-text-no-para-indent">In conclusion, blah blah blah.<p>


Example which looks wrong;
<p class="main-text-no-para-indent">Despite this agreement, by April 2008, blah blah blah. This correspondence revealed that Atos wanted to:</p>

<ul>
<li class="bulleted-list"><span class="bullet">•</span> retain all existing payments</li>

<li class="bulleted-list"><span class="bullet">•</span> have a further six months to complete the work.</li>
</ul>

<p class="main-text-no-para-indent">De Beers rejected these demands and, oblah blah blah.</p>

I could supply screenshots if it would help. Anyone got any ideas?

thanks,
Iain

susan_cassidy
06-15-2011, 03:08 PM
The first paragraph in the "right" example says "main-text-no-para-indent", whereas the "wrong" example says "main-text-para-indent".

iain robinson
06-15-2011, 03:37 PM
Thanks for your reply Susan - that is correct. In actual fact that was an error in the code - I copied and pasted a lump of code but it was too much so I edited it down and introduced that error. Sorry - I have edited the post.

The problem is after the bullet list. I have attched a couple of screenshots.

Iain

theducks
06-15-2011, 04:16 PM
was there another <UL> before that next bullet item? I don't believe ADE supports interspersed <LI>'s

JSWolf
06-15-2011, 04:19 PM
Sigil doesn't count. Sigil is not what should be used to view ePub. It should be ADE. It's more correct in ADE then in Sigil.

Also, you meed to post your CSS.

iain robinson
06-15-2011, 04:33 PM
theducks - There are no lists within lists, if that's what you mean. It goes;

<p>...</p>
<ul>
<li>...</li>
<li>...</li>
</ul>
<p>...</p>

for both right and wrong instances. Can't understand why.

JSWolf - I know Sigil is only part of the picture. The title I'm converting is not aimed at any particular device but I do have periodic access to an iPad so I can test the files on that. Sigil quite accurately previews how it will display on the iPad (I guess they both use the webkit rendering engine?) but it's ADE (and all the devices I know that uses that engine) that's giving me the problem. I use Sigil to look at the code (saves me having to unzip the ePub) - I turn off Sigil's "HTML Tidy" option. So irrespective of how Sigil displays it, the code seems the same but I get two different results in ADE.

iain robinson
06-15-2011, 04:36 PM
When I say on the iPad I mean in iBooks.

Toxaris
06-15-2011, 05:02 PM
You can always set a style for <ul> with 'margin-bottom: 0'

iain robinson
06-15-2011, 05:10 PM
I hadn't thought of that! Thanks - I do want a gap after the lists so I added a 1em margin to the bottom and the lists work consistently now (and matches what I has seeing in Sigil, and hopefully iBooks).

cheers!

JSWolf
06-15-2011, 09:53 PM
theducks - There are no lists within lists, if that's what you mean. It goes;

<p>...</p>
<ul>
<li>...</li>
<li>...</li>
</ul>
<p>...</p>

for both right and wrong instances. Can't understand why.

JSWolf - I know Sigil is only part of the picture. The title I'm converting is not aimed at any particular device but I do have periodic access to an iPad so I can test the files on that. Sigil quite accurately previews how it will display on the iPad (I guess they both use the webkit rendering engine?) but it's ADE (and all the devices I know that uses that engine) that's giving me the problem. I use Sigil to look at the code (saves me having to unzip the ePub) - I turn off Sigil's "HTML Tidy" option. So irrespective of how Sigil displays it, the code seems the same but I get two different results in ADE.

The problem is that how iBooks displays something can be different enough that it is silly. Use Bluefire Reader with the iPad. It uses ADE and will look like ADE on your desktop.

iain robinson
06-16-2011, 03:55 AM
Thanks - I'm trying to find a happy medium that looks presentable in as many scenarios as possible. The customer for this title has indicated that many of the potential readers will be using iPads so I have to assume that a lot of them will be using iBooks. I will look at Bluefire though.

What's your experience with this aim? Is it possible to make one file that looks good on ADE-based readers and webkit-based readers?

JSWolf
06-23-2011, 12:10 AM
Thanks - I'm trying to find a happy medium that looks presentable in as many scenarios as possible. The customer for this title has indicated that many of the potential readers will be using iPads so I have to assume that a lot of them will be using iBooks. I will look at Bluefire though.

What's your experience with this aim? Is it possible to make one file that looks good on ADE-based readers and webkit-based readers?

It is possible if you don't try to get too fancy. I'm not sure if some of the workarounds for iBooks is ADE compatible. But the first thing to do is create the ePub so it looks good in ADE and then try it in iBooks and see what happens.

But the best thing to do is buy Liz Castro's ePub book. She knows iBooks very well. Her blog is at http://www.pigsgourdsandwikis.com/.

iain robinson
06-23-2011, 03:51 AM
Thanks - I already have her book and her blog is a great resource for finding out about the quirks of iBooks. of which there are many!

I have an ePub now which looks pretty good in both, thanks in part to this forum!