please Abdel

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29349 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jean-Marc Lasgouttes 2009-04-19 22:24:48 +00:00
parent 87bf0e82f4
commit b20965dd83

View File

@ -267,8 +267,8 @@ void Counters::reset()
// It only needs to be done when the textclass is
// updated, but in practice the extra work is probably
// not noticeable (JMarc)
docstring const fls = flattenLabelString(it->first, false, callers);
docstring const flsa = flattenLabelString(it->first, true, callers);
docstring const & fls = flattenLabelString(it->first, false, callers);
docstring const & flsa = flattenLabelString(it->first, true, callers);
it->second.setFlatLabelStrings(fls, flsa);
}
}
@ -480,8 +480,8 @@ docstring Counters::flattenLabelString(docstring const & counter, bool in_append
while (k < ls.size() && lowercase(ls[k]) >= 'a'
&& lowercase(ls[k]) <= 'z')
++k;
docstring const newc = ls.substr(j, k - j);
docstring const repl = flattenLabelString(newc, in_appendix, callers);
docstring const & newc = ls.substr(j, k - j);
docstring const & repl = flattenLabelString(newc, in_appendix, callers);
ls.replace(i, k - j + 4, repl);
}
callers.pop_back();
@ -506,8 +506,8 @@ docstring Counters::counterLabel(docstring const & format) const
while (k < label.size() && lowercase(label[k]) >= 'a'
&& lowercase(label[k]) <= 'z')
++k;
docstring const newc = label.substr(j, k - j);
docstring const repl = theCounter(newc);
docstring const & newc = label.substr(j, k - j);
docstring const & repl = theCounter(newc);
label.replace(i, k - j + 4, repl);
}
while (true) {
@ -524,7 +524,7 @@ docstring Counters::counterLabel(docstring const & format) const
break;
docstring const numbertype(label, i + 1, j - i - 1);
docstring const counter(label, j + 1, k - j - 1);
docstring const rep = labelItem(counter, numbertype);
docstring const & rep = labelItem(counter, numbertype);
label = docstring(label, 0, i) + rep
+ docstring(label, k + 1, docstring::npos);
}