]> git.lyx.org Git - lyx.git/blobdiff - src/Counters.cpp
Rename a couple routines in preparation for more.
[lyx.git] / src / Counters.cpp
index 0ff9f022cd602f379eb30609fbe881fc7a0a9546..3921cf2890db3742cad8d6a6bbfd51dc6c0911d9 100644 (file)
 #include <config.h>
 
 #include "Counters.h"
-
 #include "Lexer.h"
 
 #include "support/convert.h"
 #include "support/debug.h"
-#include "support/lstrings.h"
-
 #include "support/lassert.h"
+#include "support/lstrings.h"
 
+#include <algorithm>
 #include <sstream>
 
 using namespace std;
@@ -150,8 +149,7 @@ docstring const & Counter::flatLabelString(bool in_appendix) const
 }
 
 
-docstring const & Counter::setFlatLabelStrings(docstring const & fls,
-                                              docstring const & flsa)
+void Counter::setFlatLabelStrings(docstring const & fls, docstring const & flsa)
 {
        flatlabelstring_ = fls;
        flatlabelstringappendix_ = flsa;
@@ -332,10 +330,10 @@ char hebrewCounter(int const n)
 
 
 
-//On the special cases, see http://mathworld.wolfram.com/RomanNumerals.html
-//and for a list of roman numerals up to and including 3999, see 
-//http://www.research.att.com/~njas/sequences/a006968.txt. (Thanks to Joost
-//for this info.)
+// On the special cases, see http://mathworld.wolfram.com/RomanNumerals.html
+// and for a list of roman numerals up to and including 3999, see 
+// http://www.research.att.com/~njas/sequences/a006968.txt. (Thanks to Joost
+// for this info.)
 docstring const romanCounter(int const n)
 {
        static char const * const ones[9] = {
@@ -437,11 +435,13 @@ docstring Counters::theCounter(docstring const & counter) const
        CounterList::const_iterator it = counterList_.find(counter); 
        if (it == counterList_.end())
                return from_ascii("??");
+       // FIXME: this should get translated.
        return counterLabel(it->second.flatLabelString(appendix()));
 }
 
 
-docstring Counters::flattenLabelString(docstring const & counter, bool in_appendix, 
+docstring Counters::flattenLabelString(docstring const & counter, 
+                                      bool in_appendix, 
                                       vector<docstring> & callers) const
 {
        docstring label;