diff --git a/src/insets/InsetTabular.cpp b/src/insets/InsetTabular.cpp index 902814a723..e8db353e8e 100644 --- a/src/insets/InsetTabular.cpp +++ b/src/insets/InsetTabular.cpp @@ -3418,6 +3418,16 @@ void InsetTabular::updateLabels(ParIterator const & it, UpdateType utype) } +void InsetTabular::addToToc(DocIterator const & cpit) +{ + DocIterator dit = cpit; + dit.forwardPos(); + size_t const end = dit.nargs(); + for ( ; dit.idx() < end; dit.top().forwardIdx()) + cell(dit.idx())->addToToc(cpit); +} + + void InsetTabular::doDispatch(Cursor & cur, FuncRequest & cmd) { LYXERR(Debug::DEBUG, "# InsetTabular::doDispatch: cmd: " << cmd diff --git a/src/insets/InsetTabular.h b/src/insets/InsetTabular.h index bc72937741..47b9aa4c60 100644 --- a/src/insets/InsetTabular.h +++ b/src/insets/InsetTabular.h @@ -835,8 +835,10 @@ public: Inset * editXY(Cursor & cur, int x, int y); /// can we go further down on mouse click? bool descendable(BufferView const &) const { return true; } - // Update the counters of this inset and of its contents + /// Update the counters of this inset and of its contents void updateLabels(ParIterator const &, UpdateType); + /// + void addToToc(DocIterator const &); /// bool completionSupported(Cursor const &) const;