Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 06-03-2019, 06:39 PM   #1
mrprobert
Connoisseur
mrprobert began at the beginning.
 
Posts: 71
Karma: 46
Join Date: Mar 2017
Device: None
Question about reformatting <aside> elements (Sigil 0.9.13)

Hi,

I have an epub3 with this code:

<body>
<aside epub:type="footnote">
Text
here,
and here.
</aside>
</body>

After reformatting I expect:

<body>
<aside epub:type="footnote">
Text here, and here.
</aside>
</body>

But instead I see this:

<body>
<aside epub:type="footnote">
Text
here,
and here.
</aside>
</body>

Is Sigil's behavior correct for this example?
mrprobert is offline   Reply With Quote
Old 06-03-2019, 06:43 PM   #2
mrprobert
Connoisseur
mrprobert began at the beginning.
 
Posts: 71
Karma: 46
Join Date: Mar 2017
Device: None
The tabbing disappeared from my post; hopefully the gist is apparent. Thanks.
mrprobert is offline   Reply With Quote
Advert
Old 06-03-2019, 07:04 PM   #3
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,759
Karma: 5706256
Join Date: Nov 2009
Device: many
It isn't apparent. And what type of reformatting? A Mend? A Prettify?, a Plugin?
KevinH is online now   Reply With Quote
Old 06-03-2019, 07:59 PM   #4
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: 28,568
Karma: 204127028
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Prettifying doesn't seem to be collapsing whitespace in the textual contents of aside (or div) tags like it does for most other tags. Not sure if that's by design or not.

Last edited by DiapDealer; 06-03-2019 at 08:01 PM.
DiapDealer is online now   Reply With Quote
Old 06-03-2019, 08:43 PM   #5
mrprobert
Connoisseur
mrprobert began at the beginning.
 
Posts: 71
Karma: 46
Join Date: Mar 2017
Device: None
I did a mend and prettify code. What I expected was that the 3 lines of text would be concatenated.

It ended up looking like this:

Code:
<body>
  <aside epub:type="footnote">
    Text
here,
and here.
  </aside>
</body>
mrprobert is offline   Reply With Quote
Advert
Old 06-03-2019, 09:15 PM   #6
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,759
Karma: 5706256
Join Date: Nov 2009
Device: many
It is as designed. Bare text whose parent is a structural tag will not have its whitespace condensed. This set of structural tags is:

Code:
static std::unordered_set<std::string> structural_tags     = {
  "article","aside","blockquote","body","canvas","colgroup","div","dl",
  "figure","footer","head","header","hr","html","ol","section",
  "table","tbody","tfoot","thead","td","th","tr","ul"
};
So if you were to make that bare text the child of a p tag or a span tag, and place it inside a structural tag, then the text whitespace would be condensed.
KevinH is online now   Reply With Quote
Old 06-03-2019, 09:24 PM   #7
mrprobert
Connoisseur
mrprobert began at the beginning.
 
Posts: 71
Karma: 46
Join Date: Mar 2017
Device: None
Ah, I see. Thank you.
mrprobert is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Sigil output with no html or head elements pittendrigh Sigil 10 08-25-2018 08:58 AM
Sigil changes markup of empty elements when the document is saved ibu Sigil 9 08-12-2013 01:39 PM
Linking question in Sigil ralphiedee Sigil 2 12-07-2012 02:13 PM
Sigil question OTMGD Sigil 3 02-05-2011 09:21 AM
Sigil Newbie Question 93terp Sigil 2 01-11-2010 07:22 PM


All times are GMT -4. The time now is 07:53 PM.


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