mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-23 13:31:49 +00:00
Following commit 19040, those partial updateLabels() functions are not needed anymore.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19041 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
f1a6378d72
commit
ba4214cbe9
@ -636,62 +636,6 @@ void setLabel(Buffer const & buf, ParIterator & it, TextClass const & textclass)
|
||||
} // anon namespace
|
||||
|
||||
|
||||
bool updateCurrentLabel(Buffer const & buf,
|
||||
ParIterator & it)
|
||||
{
|
||||
if (it == par_iterator_end(buf.inset()))
|
||||
return false;
|
||||
|
||||
// if (it.lastpit == 0 && Text::isMainText(buf))
|
||||
// return false;
|
||||
|
||||
switch (it->layout()->labeltype) {
|
||||
|
||||
case LABEL_NO_LABEL:
|
||||
case LABEL_MANUAL:
|
||||
case LABEL_BIBLIO:
|
||||
case LABEL_TOP_ENVIRONMENT:
|
||||
case LABEL_CENTERED_TOP_ENVIRONMENT:
|
||||
case LABEL_STATIC:
|
||||
case LABEL_ITEMIZE:
|
||||
setLabel(buf, it, buf.params().getTextClass());
|
||||
return true;
|
||||
|
||||
case LABEL_SENSITIVE:
|
||||
case LABEL_COUNTER:
|
||||
// do more things with enumerate later
|
||||
case LABEL_ENUMERATE:
|
||||
return false;
|
||||
}
|
||||
|
||||
// This is dead code which get rid of a warning:
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
void updateLabels(Buffer const & buf,
|
||||
ParIterator & from, ParIterator & to, bool childonly)
|
||||
{
|
||||
for (ParIterator it = from; it != to; ++it) {
|
||||
if (it.pit() > it.lastpit())
|
||||
return;
|
||||
if (!updateCurrentLabel (buf, it)) {
|
||||
updateLabels(buf, childonly);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void updateLabels(Buffer const & buf, ParIterator & iter, bool childonly)
|
||||
{
|
||||
if (updateCurrentLabel(buf, iter))
|
||||
return;
|
||||
|
||||
updateLabels(buf, childonly);
|
||||
}
|
||||
|
||||
|
||||
void updateLabels(Buffer const & buf, bool childonly)
|
||||
{
|
||||
Buffer const * const master = buf.getMasterBuffer();
|
||||
|
@ -56,19 +56,6 @@ void bufferErrors(Buffer const &, TeXErrors const &, ErrorList &);
|
||||
/// Count the number of words in the text between these two iterators
|
||||
int countWords(DocIterator const & from, DocIterator const & to);
|
||||
|
||||
/// update labels at "iter".
|
||||
/**
|
||||
A full updateLabels(Buffer const &) will be called if not possible.
|
||||
*/
|
||||
void updateLabels(Buffer const & buf, ParIterator & it, bool childonly = false);
|
||||
|
||||
/// update labels between "from" and "to" if possible.
|
||||
/**
|
||||
A full updateLabels(Buffer const &) will be called if not possible.
|
||||
*/
|
||||
void updateLabels(Buffer const & buf,
|
||||
ParIterator & from, ParIterator & to, bool childonly = false);
|
||||
|
||||
/// updates all counters
|
||||
void updateLabels(Buffer const &, bool childonly = false);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user