if (in_allowed_inset && inInset().asInsetText() && il.allowedOccurrences() != -1) {
ParagraphList & pars = cur.text()->paragraphs();
for (Paragraph const & par : pars) {
- for (auto const & table : par.insetList())
- if (table.inset->getLayout().name() == il.name())
+ for (auto const & elem : par.insetList())
+ if (elem.inset->getLayout().name() == il.name())
++have_ins;
}
if (have_ins >= il.allowedOccurrences())
for (; pit <= lastpit; ++pit) {
if (&pars[pit].layout() != d->layout_)
break;
- for (auto const & table : pars[pit].insetList())
- if (table.inset->getLayout().name() == il.name())
+ for (auto const & elem : pars[pit].insetList())
+ if (elem.inset->getLayout().name() == il.name())
++have_ins;
}
if (have_ins >= il.allowedOccurrences())
// If we find an InsetArgument that is supposed to provide the TOC caption,
// we'll save it for use later.
InsetArgument const * arginset = nullptr;
- for (auto const & table : par.insetList()) {
- dit.pos() = table.pos;
- table.inset->addToToc(dit, doing_output, utype, backend);
- if (InsetArgument const * x = table.inset->asInsetArgument())
+ for (auto const & elem : par.insetList()) {
+ dit.pos() = elem.pos;
+ elem.inset->addToToc(dit, doing_output, utype, backend);
+ if (InsetArgument const * x = elem.inset->asInsetArgument())
if (x->isTocCaption())
arginset = x;
}