|
|
#1 |
|
Connoisseur
![]() Posts: 73
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? |
|
|
|
|
|
#2 |
|
Connoisseur
![]() Posts: 73
Karma: 46
Join Date: Mar 2017
Device: None
|
The tabbing disappeared from my post; hopefully the gist is apparent. Thanks.
|
|
|
|
| Advert | |
|
|
|
|
#3 |
|
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 9,121
Karma: 6404930
Join Date: Nov 2009
Device: many
|
It isn't apparent. And what type of reformatting? A Mend? A Prettify?, a Plugin?
|
|
|
|
|
|
#4 |
|
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 28,930
Karma: 207182180
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 09:01 PM. |
|
|
|
|
|
#5 |
|
Connoisseur
![]() Posts: 73
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>
|
|
|
|
| Advert | |
|
|
|
|
#6 |
|
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 9,121
Karma: 6404930
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"
};
|
|
|
|
|
|
#7 |
|
Connoisseur
![]() Posts: 73
Karma: 46
Join Date: Mar 2017
Device: None
|
Ah, I see. Thank you.
|
|
|
|
![]() |
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Sigil output with no html or head elements | pittendrigh | Sigil | 10 | 08-25-2018 09:58 AM |
| Sigil changes markup of empty elements when the document is saved | ibu | Sigil | 9 | 08-12-2013 02:39 PM |
| Linking question in Sigil | ralphiedee | Sigil | 2 | 12-07-2012 03:13 PM |
| Sigil question | OTMGD | Sigil | 3 | 02-05-2011 10:21 AM |
| Sigil Newbie Question | 93terp | Sigil | 2 | 01-11-2010 08:22 PM |