> In principle I agree (more elegant, more c++, more STL-like, etc.), but it
> was doing something strange/weird: consider the buffer with a single par,
> with a footnote inside. As it was before, it was iterating 2 paragraphs:
> the outer one (producing "[footnote: foo]") and then the inner one in the
> footnote (producing "foo": total is "[footnote: foo]foo"). That is, it was
> behaving like a DocIterator when you advance it.
> Instead, here I want only to iterate outer paragraph(s) (mostly it's only 1,
> but sometimes we have 2 if we search for something unusual) and textify them.

So, the problem is that Paragraph::stringify already goes into the nested
paragraphs. IMHO the correct way to fix this is then to have an
InsetText::stringify() function that will make sure that it will iterate
over the outer paragraphs only.

This kind of things that should really go into the commit message. This is
apparently not very obvious, so please document it.

Vincent

Reply via email to