Quote:
I cannot see any difference between Sigil nbsp and Calibre nbsp,
|
There is no difference.
The problem is nbsp
characters, vs entities (named, or decimal, or hex)
Because of Qt5 behavior (bug/whatever) or Tidy, the non-breaking space
character needs to be converted to something else in order to preserve it. Otherwise Qt will change it into a normal space character--which defeats the purpose of a non-breaking space character (especially consecutive ones, since html doesn't recognize consecutive spaces).
So the current version of Sigil changes the non-breaking space
character into an nbsp; named
entity. Which is fine as long as there's already a DOCTYPE/DTD declaration that
allows for named entities (beyond the handful inherently recognized by xml) in the document. But alas ... many don't have the doctype declaration, so when the characters get changed to entities, the document is then technically no longer valid xhtml. So Sigil barks at it.
If the original documents have nbsp; named
entities and no DOCTYPE/DTD, Sigil barks at it (as it should... that's not valid xhtml).
As far as calibre goes, it seems to be currently creating markup with non-breaking space
characters and no DOCTYPE declaration. Which is perfectly fine and valid and whatnot. That's fair. It's just unfortunate that,
that happens to be the exact bugaboo that's tripping up the current version of Sigil upon opening.