* insets/*.C: constify docstring in plaintext()

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17317 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Michael Schmitt 2007-02-24 14:35:38 +00:00
parent d8f4881926
commit 6ab7047f3a
7 changed files with 8 additions and 8 deletions

View File

@ -95,7 +95,7 @@ int InsetCommand::latex(Buffer const &, odocstream & os,
int InsetCommand::plaintext(Buffer const &, odocstream & os, int InsetCommand::plaintext(Buffer const &, odocstream & os,
OutputParams const &) const OutputParams const &) const
{ {
docstring str = "[" + _("LaTeX Command: ") + from_utf8(getCmdName()) + "]"; docstring const str = "[" + _("LaTeX Command: ") + from_utf8(getCmdName()) + "]";
os << str; os << str;
return str.size(); return str.size();
} }

View File

@ -818,8 +818,8 @@ int InsetGraphics::plaintext(Buffer const &, odocstream & os,
// FIXME UNICODE // FIXME UNICODE
// FIXME: We have no idea what the encoding of the filename is // FIXME: We have no idea what the encoding of the filename is
docstring str = bformat(_("Graphics file: %1$s"), docstring const str = bformat(_("Graphics file: %1$s"),
from_utf8(params().filename.absFilename())); from_utf8(params().filename.absFilename()));
os << '<' << str << '>'; os << '<' << str << '>';
return 2 + str.size(); return 2 + str.size();

View File

@ -502,7 +502,7 @@ int InsetInclude::plaintext(Buffer const & buffer, odocstream & os,
os << "\n]"; os << "\n]";
return PLAINTEXT_NEWLINE + 1; // one char on a separate line return PLAINTEXT_NEWLINE + 1; // one char on a separate line
} else { } else {
docstring str = '[' + getScreenLabel(buffer) + ']'; docstring const str = '[' + getScreenLabel(buffer) + ']';
os << str; os << str;
return str.size(); return str.size();
} }

View File

@ -96,7 +96,7 @@ int InsetLabel::latex(Buffer const &, odocstream & os,
int InsetLabel::plaintext(Buffer const &, odocstream & os, int InsetLabel::plaintext(Buffer const &, odocstream & os,
OutputParams const &) const OutputParams const &) const
{ {
docstring str = getParam("name"); docstring const str = getParam("name");
os << '<' << str << '>'; os << '<' << str << '>';
return 2 + str.size(); return 2 + str.size();
} }

View File

@ -331,7 +331,7 @@ int InsetQuotes::latex(Buffer const &, odocstream & os,
int InsetQuotes::plaintext(Buffer const & buf, odocstream & os, int InsetQuotes::plaintext(Buffer const & buf, odocstream & os,
OutputParams const &) const OutputParams const &) const
{ {
docstring str = dispString(buf.params().language); docstring const str = dispString(buf.params().language);
os << str; os << str;
return str.size(); return str.size();
} }

View File

@ -97,7 +97,7 @@ int InsetRef::latex(Buffer const &, odocstream & os,
int InsetRef::plaintext(Buffer const &, odocstream & os, int InsetRef::plaintext(Buffer const &, odocstream & os,
OutputParams const &) const OutputParams const &) const
{ {
docstring str = getParam("reference"); docstring const str = getParam("reference");
os << '[' << str << ']'; os << '[' << str << ']';
return 2 + str.size(); return 2 + str.size();
} }

View File

@ -81,7 +81,7 @@ int InsetUrl::plaintext(Buffer const &, odocstream & os,
else else
oss << "||" << getParam("name") << ']'; oss << "||" << getParam("name") << ']';
docstring str = oss.str(); docstring const str = oss.str();
os << str; os << str;
return str.size(); return str.size();
} }