This is mostly important for subfigures, but debugging this issue showed that InsetCaption could be slightly simplified and InsetLabel should be made a tad more robust.
This ensures that all comparisons for DocBook are made on the same normalised version of the float type. This cased a strange bug where <table> was output within <informaltable> for Linguistics Tableaux.
This lead to a quite subtle bug. The major problem is that float tags
depend on whether the LyX float has a title (formal) or nor (informal).
This information cannot be encoded in the layout format as easily as a
simple DocBookTag.
This was due to Floating::docbookTag not returning anything with the floattype_ tableau. Another issue that happened with that document is that the standard library's isspace crashed for some characters. I therefore implemented a more efficient version of the part that required it, and inlined the definition of isspace (even though that part becomes irrespective of locale, but was that feature ever used?).
This is a minimal implementation, as DocBook lacks a serious way of encoding all of this. Maybe a <formalpara> could do the trick, but I'd need to find a way to shoehorn a title through the styles (i.e. a first complete tag):
Theorem: Bla bla
<formalpara>
<title>Theorem</title>
<para>Bla bla</para>
</formalpara>
This would also only be a solution for single-paragraph things, as formalpara only allows one paragraph. Or a sidebar, but it's semantically very remote.
Includes: semantic markup (sorry about noun: Additional.lyx uses it to mark menus; there is something better in DocBook, but it looks like the LaTeX equivalent is really for person names), boxes, info layouts.
Actually output something when list item is empty. XMLStream discarded the sequence StartTag/EndTag (nothing in between).
New-line behaviour around term in description lists.
That's mostly generating DocBook tags at an inappropriate place with some metadata, rather than outputting whatever you have at your disposal. Far from satisfying, but good enough for a generic tool (see details in the new TODO). Doesn't trigger assertions. Is valid XML.