+docstring Counters::prettyCounter(docstring const & counter,
+ string const & lang) const
+{
+ CounterList::const_iterator it = counterList_.find(counter);
+ if (it == counterList_.end())
+ return from_ascii("??");
+ Counter const & ctr = it->second;
+ docstring const & format = ctr.prettyFormat();
+ if (format.empty()) {
+ docstring cntrname = translateIfPossible(counter, lang);
+ return cntrname + " " + theCounter(counter, lang);
+ }
+ return counterLabel(format, lang);
+}
+
+