Abdelrazak Younes wrote:
I'd prefer:
vector<Layout *> counter_layout = tclass.counterLayout();
Or maybe:
vector<Layout *> counter_layout = tclass.layoutsWithType(LABEL_COUNTER);
for (size_t i; i != layout ; ++i) {
int const toclevel = counter_layout[i]->toclevel;
if (toclevel != Layout::NOT_IN_TOC) {
item = new QTreeWidgetItem(numberingModule->tocTW);
item->setText(0,toqstr(translateIfPossible(
counter_layout[i]->name())));
item->setText(1, (toclevel <= depth) ? yes : no);
item->setText(2, (toclevel <= toc) ? yes : no);
}
}