* This file is part of LyX, the document processor.
* Licence details can be found in the file COPYING.
*
- * \author Lars Gullik Bjønnes
+ * \author Lars Gullik Bjønnes
*
* Full author contact details are available in file CREDITS.
*/
runparams.dryrun = true;
if (full_source) {
- os << "% Preview source code\n\n";
+ os << "% " << _("Preview source code") << "\n\n";
if (isLatex())
writeLaTeXSource(os, filePath(), runparams, true, true);
else {
runparams.par_begin = par_begin;
runparams.par_end = par_end;
if (par_begin + 1 == par_end)
- os << "% Preview source code for paragraph " << par_begin << "\n\n";
+ os << "% "
+ << bformat(_("Preview source code for paragraph %1$s"), par_begin)
+ << "\n\n";
else
- os << "% Preview source code from paragraph " << par_begin
- << " to " << par_end - 1 << "\n\n";
+ os << "% "
+ << bformat(_("Preview source code from paragraph %1$s to %2$s"),
+ convert<docstring>(par_begin),
+ convert<docstring>(par_end - 1))
+ << "\n\n";
// output paragraphs
if (isLatex()) {
texrow().reset();
std::vector<docstring> const & typeNames() const
{ return type_names_; }
+ /// Return the guiname from a given cmdName of the TOC param
+ docstring const getGuiName(std::string const & type) const;
+
///
int selectedType() { return selected_type_; }
void updateBackend();
private:
- /// Return the guiname from a given cmdName of the TOC param
- docstring const getGuiName(std::string const & type) const;
-
std::vector<std::string> types_;
std::vector<docstring> type_names_;
int selected_type_;
}
QString current_text = typeCO->currentText();
- lyxerr << "current_text " << fromqstr(current_text) << endl;
+ //lyxerr << "current_text " << fromqstr(current_text) << endl;
typeCO->blockSignals(true);
typeCO->clear();
int current_type = -1;
for (size_t i = 0; i != type_names.size(); ++i) {
- QString item = toqstr(type_names[i]);
+ QString item =
+ toqstr(form_->getGuiName(to_utf8(type_names[i])));
typeCO->addItem(item);
if (item == current_text)
current_type = i;