I've made a first attempt at creating paragraph iterators, and use them in
order to fix updating of references when the label is changed.

I've created two different implementations.
In the first, we use the fact that we have a fixed structure of a document:
We have a list of paragraph, each paragraph containing a list of insets, and
each inset may contain several insettexts. Each insetext contains a list of
paragraph etc.

The second version is more general as no such assumption is made.
However, we pay a price in performance: we need to store a vector of pointers
to iterators instead of storing the iterators in vectors.
The code is a little bit ugly, but it can be improved using virtual methods
(the code should look familiar...).

iterators1.gz

iterators2.gz

Reply via email to