Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 12-20-2020, 06:32 PM   #1
wellesradio
Member
wellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavens
 
Posts: 23
Karma: 13884
Join Date: Jan 2014
Device: apple ipad (3rd generation)
Paragraph spacing not working?

Forgive me for being a novice at this, but I'm having an issue with paragraph indentation. I'm editing an epub file in Sigil, but when I read it in Marvin 3 changing the setting for paragraph spacing does nothing. I can change everything else in Marvin 3; text size, margin size, line spacing, indentation. But when I try to raise or lower the paragraph spacing nothing happens.

Here's the HTML (I removed all but the first couple of paragraphs):


Quote:
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
</head>

<body>
<div class="s" style="text-indent: 14.15pt;">
<h3><span style="font-size: 1em; font-weight: bold; text-indent: 14.15pt;">CHAPTER ONE</span><br/></h3>
</div>

<div class="calibre1">
<div class="calibre1">
<div class="s" style="text-indent: 14.15pt;">

<p>Father walked into the living room.</p>
<p>"What have you been up to?" he asked Mary who was watching television by herself.</p>

<p>"Nothing much she said," she said. "I've been waiting for cartoons to start, but there's nothing on right now."</p>

<p>"Then you'd better move over," Father said, "Football game's about to start."</p>
<p></p>

<p></p>

</div>
</div>
</div>
</body>
</html>
wellesradio is offline   Reply With Quote
Old 12-20-2020, 08:46 PM   #2
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,047
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
#1) you have no stylesheet, or Margins (top, Bottom) therefore you get whatever the render engine has for <p> tags
theducks is online now   Reply With Quote
Advert
Old 12-20-2020, 09:46 PM   #3
wellesradio
Member
wellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavens
 
Posts: 23
Karma: 13884
Join Date: Jan 2014
Device: apple ipad (3rd generation)
Originally, the code did have a style, but it made no difference:

Code:
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
  "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
  <title></title>
</head>

<body>
  <div class="s" style="text-align: justify; text-indent: 14.15pt;">
    <h3 class="calibre2" style="margin: 1em 0px;"><span style="font-size: 1em; font-weight: bold; text-indent: 14.15pt;">CHAPTER ONE</span><br/></h3>
  </div>

  <div class="calibre1">
    <div class="calibre1">
      <div class="s" style="text-align: justify; text-indent: 14.15pt;">
        <p class="calibre2" style="margin: 1em 0px;">&nbsp;</p>

          <p class="calibre2" style="margin: 1em 0px;">Father walked into the living room.</p>
wellesradio is offline   Reply With Quote
Old 12-20-2020, 09:55 PM   #4
PeterT
Grand Sorcerer
PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.
 
Posts: 13,505
Karma: 78910112
Join Date: Nov 2007
Location: Toronto
Device: Libra H2O, Libra Colour
I believe people are wondering where classes like calibre1 and calibre1 are defined. There should be a stylesheet referred to by the XHTML. See https://www.w3schools.com/css/css_howto.asp
PeterT is offline   Reply With Quote
Old 12-20-2020, 10:16 PM   #5
wellesradio
Member
wellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavens
 
Posts: 23
Karma: 13884
Join Date: Jan 2014
Device: apple ipad (3rd generation)
To be honest, I haven't a clue. I didn't write the code, I'm just trying to edit it so that the book reads better on my device.
wellesradio is offline   Reply With Quote
Advert
Old 12-21-2020, 12:29 AM   #6
Thasaidon
Hedge Wizard
Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.Thasaidon ought to be getting tired of karma fortunes by now.
 
Thasaidon's Avatar
 
Posts: 802
Karma: 19999999
Join Date: May 2011
Location: UK/Philippines
Device: Kobo Touch, Nook Simple
Quote:
Originally Posted by wellesradio View Post
To be honest, I haven't a clue. I didn't write the code, I'm just trying to edit it so that the book reads better on my device.
In order to edit an eBook you need to have at least some knowledge of html and CSS.

There are plenty of basic tutorials on the internet. I think there are even a couple on this site. See the Wiki link below.

https://wiki.mobileread.com/wiki/EPub_Tutorial

Last edited by Thasaidon; 12-21-2020 at 12:32 AM. Reason: added link
Thasaidon is offline   Reply With Quote
Old 12-21-2020, 01:18 AM   #7
wellesradio
Member
wellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavenswellesradio is a rising star in the heavens
 
Posts: 23
Karma: 13884
Join Date: Jan 2014
Device: apple ipad (3rd generation)
Quote:
Originally Posted by PeterT View Post
I believe people are wondering where classes like calibre1 and calibre1 are defined. There should be a stylesheet referred to by the XHTML. See https://www.w3schools.com/css/css_howto.asp
Looking those over, they were very helpful for future reference.
I have a better idea now of how I can define certain margins, but what would when I don’t want any particular definition so that I can change that in my reader (Marvin 3)?
wellesradio is offline   Reply With Quote
Old 12-21-2020, 01:56 AM   #8
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 46,155
Karma: 168983734
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by wellesradio View Post
Looking those over, they were very helpful for future reference.
I have a better idea now of how I can define certain margins, but what would when I don’t want any particular definition so that I can change that in my reader (Marvin 3)?
Then ensure that base margins are not defined internally. Generally, I set the default margins to 0 0 0 0 and then control the left/right margins from my ereader.

OTOH, I personally found Marvin even with CSS enabled was not even near the top in displaying an epub the way the publisher intended and it's epub3 support pathetic. Admittedly this was using the free nagware version where the "basic" epub3 support is close to non-existent. Claiming epub3 support and not being able to open an epub3 nav document? And yes, epub3 ebooks without a ncx file are becoming a lot more common these days.
DNSB is offline   Reply With Quote
Old 12-21-2020, 01:34 PM   #9
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,347
Karma: 20171571
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
You need to select "Publisher's Layout" in Marvin...see the instructions I left in your post in the Marvin forum.

After doing that, Marvin still allows you to change margins, font-size, etc.

Also, the others are referring to the fact that your html file is not "linked" to the css file...in Sigil simply right click (or multi-select) on the file(s) you want to link in the Book Browser section (usually on the left of the window) and select "Link Stylesheets". Without a linked stylesheet all of those class="..." tags won't reference any of the styling.

It will end up looking something like this:

Code:
<head>
  <title>Cover</title>
  <link href="../Styles/styles.css" type="text/css" rel="stylesheet"/>
</head>
Turtle91 is offline   Reply With Quote
Old 12-22-2020, 04:29 PM   #10
Notjohn
mostly an observer
Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.
 
Posts: 1,519
Karma: 987654
Join Date: Dec 2012
Device: Kindle
You might look at my style sheet at https://notjohnkdp.blogspot.com/2013...yle-sheet.html -- free for the taking; adapt at your pleasure.

It should go in the Sigil "Styles" folder, and note Dion's pointer above. In this case you'd name the file styles.css

Note that I never use an absolute measurement such as points, but rather ems (and maybe percents; I don't remember).
Notjohn is offline   Reply With Quote
Old 12-29-2020, 05:31 AM   #11
un_pogaz
Chalut o/
un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.
 
un_pogaz's Avatar
 
Posts: 439
Karma: 145424
Join Date: Dec 2017
Device: Kobo
The <p></p> tags are not displayed because they are empty.
It might not exist that it would be the same.

Write an unbreakable space inside for "validated" this.
Search/Replace: <p></p> => <p>&nbsp;</p>

Last edited by un_pogaz; 12-29-2020 at 05:33 AM.
un_pogaz is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Kindle: Paragraph spacing macnab69 Devices 5 06-16-2014 02:28 AM
Paragraph spacing Banks ePub 2 08-09-2012 05:24 PM
Preference: Paragraph indent or a little paragraph spacing? 1611mac General Discussions 48 11-11-2011 12:43 AM
Paragraph spacing jhempel24 Calibre 5 08-24-2010 12:14 AM


All times are GMT -4. The time now is 03:37 AM.


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