diff --git a/src/BufferView.cpp b/src/BufferView.cpp index fff47d0559..178bcfc521 100644 --- a/src/BufferView.cpp +++ b/src/BufferView.cpp @@ -561,7 +561,7 @@ docstring BufferView::toolTip(int x, int y) const } -docstring BufferView::contextMenu(int x, int y) const +string BufferView::contextMenu(int x, int y) const { //If there is a selection, return the containing inset menu if (d->cursor_.selection()) diff --git a/src/BufferView.h b/src/BufferView.h index 901d055223..fa85195b52 100644 --- a/src/BufferView.h +++ b/src/BufferView.h @@ -124,7 +124,7 @@ public: /// \return Tool tip for the given position. docstring toolTip(int x, int y) const; /// \return the context menu for the given position. - docstring contextMenu(int x, int y) const; + std::string contextMenu(int x, int y) const; /// Save the current position as bookmark. /// if idx == 0, save to temp_bookmark diff --git a/src/frontends/qt4/GuiWorkArea.cpp b/src/frontends/qt4/GuiWorkArea.cpp index f18dbf5f59..563d00b738 100644 --- a/src/frontends/qt4/GuiWorkArea.cpp +++ b/src/frontends/qt4/GuiWorkArea.cpp @@ -716,7 +716,7 @@ bool GuiWorkArea::event(QEvent * e) void GuiWorkArea::contextMenuEvent(QContextMenuEvent * e) { - docstring name; + string name; if (e->reason() == QContextMenuEvent::Mouse) // the menu name is set on mouse press name = d->context_menu_name_; diff --git a/src/frontends/qt4/GuiWorkArea_Private.h b/src/frontends/qt4/GuiWorkArea_Private.h index ee7f1b3473..133a6cdbec 100644 --- a/src/frontends/qt4/GuiWorkArea_Private.h +++ b/src/frontends/qt4/GuiWorkArea_Private.h @@ -181,7 +181,7 @@ struct GuiWorkArea::Private /// pressed. This is used to get the correct context menu /// when the menu is actually shown (after releasing on Windows) /// and after the DEPM has done its job. - docstring context_menu_name_; + std::string context_menu_name_; }; // GuiWorkArea } // namespace frontend diff --git a/src/insets/Inset.cpp b/src/insets/Inset.cpp index 9a8a084cac..21ef625c7f 100644 --- a/src/insets/Inset.cpp +++ b/src/insets/Inset.cpp @@ -258,15 +258,15 @@ void Inset::forToc(docstring &, size_t) const } -docstring Inset::contextMenu(BufferView const &, int, int) const +string Inset::contextMenu(BufferView const &, int, int) const { return contextMenuName(); } -docstring Inset::contextMenuName() const +string Inset::contextMenuName() const { - return docstring(); + return string(); } diff --git a/src/insets/Inset.h b/src/insets/Inset.h index 2d272e3436..fbe664d5f6 100644 --- a/src/insets/Inset.h +++ b/src/insets/Inset.h @@ -408,11 +408,11 @@ public: /// \return Context menu identifier. This function determines /// whose Inset's menu should be shown for the given position. - virtual docstring contextMenu(BufferView const & bv, int x, int y) const; + virtual std::string contextMenu(BufferView const & bv, int x, int y) const; /// \return Context menu identifier for this inset. /// This default implementation returns an empty string. - virtual docstring contextMenuName() const; + virtual std::string contextMenuName() const; virtual docstring layoutName() const; diff --git a/src/insets/InsetBibtex.cpp b/src/insets/InsetBibtex.cpp index 329b32994c..831613023e 100644 --- a/src/insets/InsetBibtex.cpp +++ b/src/insets/InsetBibtex.cpp @@ -992,9 +992,9 @@ docstring InsetBibtex::xhtml(XHTMLStream & xs, OutputParams const &) const } -docstring InsetBibtex::contextMenuName() const +string InsetBibtex::contextMenuName() const { - return from_ascii("context-bibtex"); + return "context-bibtex"; } diff --git a/src/insets/InsetBibtex.h b/src/insets/InsetBibtex.h index 6e38fcc407..79ee82759b 100644 --- a/src/insets/InsetBibtex.h +++ b/src/insets/InsetBibtex.h @@ -58,7 +58,7 @@ public: /// docstring xhtml(XHTMLStream &, OutputParams const &) const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; //@} /// \name Static public methods obligated for InsetCommand derived classes diff --git a/src/insets/InsetBox.cpp b/src/insets/InsetBox.cpp index a9130a7060..03cdc318a4 100644 --- a/src/insets/InsetBox.cpp +++ b/src/insets/InsetBox.cpp @@ -530,9 +530,9 @@ void InsetBox::validate(LaTeXFeatures & features) const } -docstring InsetBox::contextMenuName() const +string InsetBox::contextMenuName() const { - return from_ascii("context-box"); + return "context-box"; } diff --git a/src/insets/InsetBox.h b/src/insets/InsetBox.h index 2fb33bf209..52cb776416 100644 --- a/src/insets/InsetBox.h +++ b/src/insets/InsetBox.h @@ -133,7 +133,7 @@ private: /// used by the constructors void init(); /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// InsetBoxParams params_; diff --git a/src/insets/InsetBranch.cpp b/src/insets/InsetBranch.cpp index f0920956cd..3c917db7f7 100644 --- a/src/insets/InsetBranch.cpp +++ b/src/insets/InsetBranch.cpp @@ -257,9 +257,9 @@ void InsetBranch::validate(LaTeXFeatures & features) const } -docstring InsetBranch::contextMenuName() const +string InsetBranch::contextMenuName() const { - return from_ascii("context-branch"); + return "context-branch"; } diff --git a/src/insets/InsetBranch.h b/src/insets/InsetBranch.h index c51c728e4f..64029c0193 100644 --- a/src/insets/InsetBranch.h +++ b/src/insets/InsetBranch.h @@ -79,7 +79,7 @@ private: /// void validate(LaTeXFeatures &) const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// void addToToc(DocIterator const &) const; /// diff --git a/src/insets/InsetCitation.cpp b/src/insets/InsetCitation.cpp index 6f9035c5b9..c1a5145f0e 100644 --- a/src/insets/InsetCitation.cpp +++ b/src/insets/InsetCitation.cpp @@ -611,9 +611,9 @@ void InsetCitation::validate(LaTeXFeatures & features) const } -docstring InsetCitation::contextMenuName() const +string InsetCitation::contextMenuName() const { - return from_ascii("context-citation"); + return "context-citation"; } diff --git a/src/insets/InsetCitation.h b/src/insets/InsetCitation.h index 6eb0da03fc..2762bfd9f2 100644 --- a/src/insets/InsetCitation.h +++ b/src/insets/InsetCitation.h @@ -63,7 +63,7 @@ public: /// void addToToc(DocIterator const &) const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; //@} /// \name Static public methods obligated for InsetCommand derived classes diff --git a/src/insets/InsetCollapsable.cpp b/src/insets/InsetCollapsable.cpp index a8a114f3a6..6c880cd514 100644 --- a/src/insets/InsetCollapsable.cpp +++ b/src/insets/InsetCollapsable.cpp @@ -618,15 +618,15 @@ InsetLayout::InsetDecoration InsetCollapsable::decoration() const } -docstring InsetCollapsable::contextMenu(BufferView const & bv, int x, +string InsetCollapsable::contextMenu(BufferView const & bv, int x, int y) const { - docstring context_menu = contextMenuName(); - docstring const it_context_menu = InsetText::contextMenuName(); + string context_menu = contextMenuName(); + string const it_context_menu = InsetText::contextMenuName(); if (decoration() == InsetLayout::CONGLOMERATE) return context_menu + ";" + it_context_menu; - docstring const ic_context_menu = InsetCollapsable::contextMenuName(); + string const ic_context_menu = InsetCollapsable::contextMenuName(); if (ic_context_menu != context_menu) context_menu += ";" + ic_context_menu; @@ -641,12 +641,12 @@ docstring InsetCollapsable::contextMenu(BufferView const & bv, int x, } -docstring InsetCollapsable::contextMenuName() const +string InsetCollapsable::contextMenuName() const { if (decoration() == InsetLayout::CONGLOMERATE) - return from_ascii("context-conglomerate"); + return "context-conglomerate"; else - return from_ascii("context-collapsable"); + return "context-collapsable"; } } // namespace lyx diff --git a/src/insets/InsetCollapsable.h b/src/insets/InsetCollapsable.h index fba355a5c6..d7d050e3fe 100644 --- a/src/insets/InsetCollapsable.h +++ b/src/insets/InsetCollapsable.h @@ -141,9 +141,9 @@ public: /// virtual bool usePlainLayout() const { return true; } /// - docstring contextMenu(BufferView const & bv, int x, int y) const; + std::string contextMenu(BufferView const & bv, int x, int y) const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// docstring floatName(std::string const & type) const; protected: diff --git a/src/insets/InsetCommand.cpp b/src/insets/InsetCommand.cpp index 92eb1a84fc..1c9a170b11 100644 --- a/src/insets/InsetCommand.cpp +++ b/src/insets/InsetCommand.cpp @@ -210,9 +210,9 @@ bool InsetCommand::getStatus(Cursor & cur, FuncRequest const & cmd, } -docstring InsetCommand::contextMenuName() const +string InsetCommand::contextMenuName() const { - return from_ascii("context-") + from_ascii(insetName(p_.code())); + return "context-" + insetName(p_.code()); } diff --git a/src/insets/InsetCommand.h b/src/insets/InsetCommand.h index 3ea57c98dc..4d5066e33f 100644 --- a/src/insets/InsetCommand.h +++ b/src/insets/InsetCommand.h @@ -91,7 +91,7 @@ protected: /// \name Methods relaying to the InsetCommandParams p_ //@{ /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// bool showInsetDialog(BufferView * bv) const; /// diff --git a/src/insets/InsetERT.h b/src/insets/InsetERT.h index 83ac11cf58..7d77bdafa4 100644 --- a/src/insets/InsetERT.h +++ b/src/insets/InsetERT.h @@ -38,8 +38,8 @@ public: /// static std::string params2string(CollapseStatus); - docstring contextMenuName() const - { return from_ascii("context-ert"); } + std::string contextMenuName() const + { return "context-ert"; } private: /// InsetCode lyxCode() const { return ERT_CODE; } diff --git a/src/insets/InsetExternal.cpp b/src/insets/InsetExternal.cpp index 77d1b2f7bf..bd9df03e1c 100644 --- a/src/insets/InsetExternal.cpp +++ b/src/insets/InsetExternal.cpp @@ -802,9 +802,9 @@ void InsetExternal::addPreview(DocIterator const & /*inset_pos*/, } -docstring InsetExternal::contextMenuName() const +string InsetExternal::contextMenuName() const { - return from_ascii("context-external"); + return "context-external"; } diff --git a/src/insets/InsetExternal.h b/src/insets/InsetExternal.h index 92eb61238f..fba0e7406b 100644 --- a/src/insets/InsetExternal.h +++ b/src/insets/InsetExternal.h @@ -111,7 +111,7 @@ public: /// \returns the number of rows (\n's) of generated code. void latex(otexstream &, OutputParams const &) const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// bool setMouseHover(BufferView const * bv, bool mouse_hover); /// diff --git a/src/insets/InsetGraphics.cpp b/src/insets/InsetGraphics.cpp index 48155fc109..f3e3c47079 100644 --- a/src/insets/InsetGraphics.cpp +++ b/src/insets/InsetGraphics.cpp @@ -1054,9 +1054,9 @@ void InsetGraphics::addToToc(DocIterator const & cpit) const } -docstring InsetGraphics::contextMenuName() const +string InsetGraphics::contextMenuName() const { - return from_ascii("context-graphics"); + return "context-graphics"; } diff --git a/src/insets/InsetGraphics.h b/src/insets/InsetGraphics.h index 2a04f0c33c..408a3c1f33 100644 --- a/src/insets/InsetGraphics.h +++ b/src/insets/InsetGraphics.h @@ -98,7 +98,7 @@ private: /// void addToToc(DocIterator const &) const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// Force inset into LTR environment if surroundings are RTL bool forceLTR() const { return true; } /// diff --git a/src/insets/InsetHyperlink.cpp b/src/insets/InsetHyperlink.cpp index e87103ac13..442b839f0e 100644 --- a/src/insets/InsetHyperlink.cpp +++ b/src/insets/InsetHyperlink.cpp @@ -271,9 +271,9 @@ void InsetHyperlink::validate(LaTeXFeatures & features) const } -docstring InsetHyperlink::contextMenuName() const +string InsetHyperlink::contextMenuName() const { - return from_ascii("context-hyperlink"); + return "context-hyperlink"; } diff --git a/src/insets/InsetHyperlink.h b/src/insets/InsetHyperlink.h index 4e428c767d..fb4c891979 100644 --- a/src/insets/InsetHyperlink.h +++ b/src/insets/InsetHyperlink.h @@ -42,7 +42,7 @@ public: /// docstring toolTip(BufferView const & bv, int x, int y) const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// void validate(LaTeXFeatures &) const; /// diff --git a/src/insets/InsetInclude.cpp b/src/insets/InsetInclude.cpp index b3df0d1971..42b4d8f652 100644 --- a/src/insets/InsetInclude.cpp +++ b/src/insets/InsetInclude.cpp @@ -985,9 +985,9 @@ void InsetInclude::draw(PainterInfo & pi, int x, int y) const } -docstring InsetInclude::contextMenuName() const +string InsetInclude::contextMenuName() const { - return from_ascii("context-include"); + return "context-include"; } diff --git a/src/insets/InsetInclude.h b/src/insets/InsetInclude.h index ad216bcca6..e3269badc0 100644 --- a/src/insets/InsetInclude.h +++ b/src/insets/InsetInclude.h @@ -103,7 +103,7 @@ public: /// void updateBuffer(ParIterator const &, UpdateType); /// - docstring contextMenuName() const; + std::string contextMenuName() const; //@} /// \name Static public methods obligated for InsetCommand derived classes diff --git a/src/insets/InsetIndex.cpp b/src/insets/InsetIndex.cpp index bec5a90e09..51ba81be84 100644 --- a/src/insets/InsetIndex.cpp +++ b/src/insets/InsetIndex.cpp @@ -373,9 +373,9 @@ void InsetIndex::validate(LaTeXFeatures & features) const } -docstring InsetIndex::contextMenuName() const +string InsetIndex::contextMenuName() const { - return from_ascii("context-index"); + return "context-index"; } @@ -572,10 +572,10 @@ void InsetPrintIndex::validate(LaTeXFeatures & features) const } -docstring InsetPrintIndex::contextMenuName() const +string InsetPrintIndex::contextMenuName() const { return buffer().masterBuffer()->params().use_indices ? - from_ascii("context-indexprint") : docstring(); + "context-indexprint" : string(); } diff --git a/src/insets/InsetIndex.h b/src/insets/InsetIndex.h index 0c6a961a49..42d67615b9 100644 --- a/src/insets/InsetIndex.h +++ b/src/insets/InsetIndex.h @@ -79,7 +79,7 @@ private: /// Updates needed features for this inset. void validate(LaTeXFeatures & features) const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// Inset * clone() const { return new InsetIndex(*this); } @@ -108,7 +108,7 @@ public: /// bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// Updates needed features for this inset. void validate(LaTeXFeatures & features) const; /// diff --git a/src/insets/InsetInfo.cpp b/src/insets/InsetInfo.cpp index d78793dd83..2b9b231903 100644 --- a/src/insets/InsetInfo.cpp +++ b/src/insets/InsetInfo.cpp @@ -462,7 +462,7 @@ void InsetInfo::updateInfo() } -docstring InsetInfo::contextMenu(BufferView const &, int, int) const +string InsetInfo::contextMenu(BufferView const &, int, int) const { //FIXME: We override the implementation of InsetCollapsable, //because this inset is not a collapsable inset. @@ -470,9 +470,9 @@ docstring InsetInfo::contextMenu(BufferView const &, int, int) const } -docstring InsetInfo::contextMenuName() const +string InsetInfo::contextMenuName() const { - return from_ascii("context-info"); + return "context-info"; } diff --git a/src/insets/InsetInfo.h b/src/insets/InsetInfo.h index 44bc7b2bf3..66f6a8634a 100644 --- a/src/insets/InsetInfo.h +++ b/src/insets/InsetInfo.h @@ -126,9 +126,9 @@ public: /// docstring toolTip(BufferView const & bv, int x, int y) const; /// - docstring contextMenu(BufferView const &, int, int) const; + std::string contextMenu(BufferView const &, int, int) const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// should paragraph indendation be ommitted in any case? bool neverIndent() const { return true; } diff --git a/src/insets/InsetListings.cpp b/src/insets/InsetListings.cpp index 6156f8883f..a8b56d0773 100644 --- a/src/insets/InsetListings.cpp +++ b/src/insets/InsetListings.cpp @@ -300,9 +300,9 @@ docstring InsetListings::xhtml(XHTMLStream & os, OutputParams const & rp) const } -docstring InsetListings::contextMenuName() const +string InsetListings::contextMenuName() const { - return from_ascii("context-listings"); + return "context-listings"; } diff --git a/src/insets/InsetListings.h b/src/insets/InsetListings.h index c9d833a4ad..0782d68ec7 100644 --- a/src/insets/InsetListings.h +++ b/src/insets/InsetListings.h @@ -67,7 +67,7 @@ private: /// InsetListingsParams & params() { return params_; } /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// void doDispatch(Cursor & cur, FuncRequest & cmd); /// diff --git a/src/insets/InsetNewline.cpp b/src/insets/InsetNewline.cpp index d22bb369ae..92f94eaaa7 100644 --- a/src/insets/InsetNewline.cpp +++ b/src/insets/InsetNewline.cpp @@ -259,9 +259,9 @@ void InsetNewline::draw(PainterInfo & pi, int x, int y) const } -docstring InsetNewline::contextMenuName() const +string InsetNewline::contextMenuName() const { - return from_ascii("context-newline"); + return "context-newline"; } diff --git a/src/insets/InsetNewline.h b/src/insets/InsetNewline.h index de9c7343a9..3dbbaa1085 100644 --- a/src/insets/InsetNewline.h +++ b/src/insets/InsetNewline.h @@ -77,7 +77,7 @@ private: /// ColorCode ColorName() const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// Inset * clone() const { return new InsetNewline(*this); } /// diff --git a/src/insets/InsetNewpage.cpp b/src/insets/InsetNewpage.cpp index b0e2906001..85e8d14dd3 100644 --- a/src/insets/InsetNewpage.cpp +++ b/src/insets/InsetNewpage.cpp @@ -256,9 +256,9 @@ docstring InsetNewpage::xhtml(XHTMLStream & xs, OutputParams const &) const } -docstring InsetNewpage::contextMenuName() const +string InsetNewpage::contextMenuName() const { - return from_ascii("context-newpage"); + return "context-newpage"; } diff --git a/src/insets/InsetNewpage.h b/src/insets/InsetNewpage.h index 002ae7f77f..6a1d639b07 100644 --- a/src/insets/InsetNewpage.h +++ b/src/insets/InsetNewpage.h @@ -81,7 +81,7 @@ private: /// ColorCode ColorName() const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// Inset * clone() const { return new InsetNewpage(*this); } /// diff --git a/src/insets/InsetNomencl.cpp b/src/insets/InsetNomencl.cpp index cd0a526ea0..7bdcfc7672 100644 --- a/src/insets/InsetNomencl.cpp +++ b/src/insets/InsetNomencl.cpp @@ -334,9 +334,9 @@ InsetCode InsetPrintNomencl::lyxCode() const } -docstring InsetPrintNomencl::contextMenuName() const +string InsetPrintNomencl::contextMenuName() const { - return from_ascii("context-nomenclprint"); + return "context-nomenclprint"; } diff --git a/src/insets/InsetNomencl.h b/src/insets/InsetNomencl.h index f445066550..2a0eda957f 100644 --- a/src/insets/InsetNomencl.h +++ b/src/insets/InsetNomencl.h @@ -98,7 +98,7 @@ public: /// void latex(otexstream &, OutputParams const &) const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; //@} /// \name Static public methods obligated for InsetCommand derived classes diff --git a/src/insets/InsetNote.cpp b/src/insets/InsetNote.cpp index da9dd33669..2351c2584a 100644 --- a/src/insets/InsetNote.cpp +++ b/src/insets/InsetNote.cpp @@ -322,9 +322,9 @@ void InsetNote::validate(LaTeXFeatures & features) const } -docstring InsetNote::contextMenuName() const +string InsetNote::contextMenuName() const { - return from_ascii("context-note"); + return "context-note"; } bool InsetNote::allowSpellCheck() const diff --git a/src/insets/InsetNote.h b/src/insets/InsetNote.h index efb0f27866..dc7de0e3f3 100644 --- a/src/insets/InsetNote.h +++ b/src/insets/InsetNote.h @@ -101,7 +101,7 @@ private: /// used by the constructors void init(); /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// friend class InsetNoteParams; diff --git a/src/insets/InsetPhantom.cpp b/src/insets/InsetPhantom.cpp index 9e3808f0e7..5a63957ef8 100644 --- a/src/insets/InsetPhantom.cpp +++ b/src/insets/InsetPhantom.cpp @@ -358,9 +358,9 @@ docstring InsetPhantom::xhtml(XHTMLStream &, OutputParams const &) const return docstring(); } -docstring InsetPhantom::contextMenuName() const +string InsetPhantom::contextMenuName() const { - return from_ascii("context-phantom"); + return "context-phantom"; } diff --git a/src/insets/InsetPhantom.h b/src/insets/InsetPhantom.h index 548bdb0b9c..eb36274f6e 100644 --- a/src/insets/InsetPhantom.h +++ b/src/insets/InsetPhantom.h @@ -94,7 +94,7 @@ private: /// used by the constructors void init(); /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// friend class InsetPhantomParams; diff --git a/src/insets/InsetPreview.h b/src/insets/InsetPreview.h index 039b8e2f45..15380ba543 100644 --- a/src/insets/InsetPreview.h +++ b/src/insets/InsetPreview.h @@ -49,8 +49,8 @@ public: bool descendable(BufferView const & /*bv*/) const { return true; } - docstring contextMenuName() const - { return from_ascii("context-preview"); } + std::string contextMenuName() const + { return "context-preview"; } void metrics(MetricsInfo & mi, Dimension & dim) const; diff --git a/src/insets/InsetScript.cpp b/src/insets/InsetScript.cpp index 32c83ff161..1328e3847a 100644 --- a/src/insets/InsetScript.cpp +++ b/src/insets/InsetScript.cpp @@ -421,9 +421,9 @@ docstring InsetScript::xhtml(XHTMLStream & xs, OutputParams const & runparams) c } -docstring InsetScript::contextMenuName() const +string InsetScript::contextMenuName() const { - return from_ascii("context-script"); + return "context-script"; } diff --git a/src/insets/InsetScript.h b/src/insets/InsetScript.h index e558a76294..eaec3c97c9 100644 --- a/src/insets/InsetScript.h +++ b/src/insets/InsetScript.h @@ -109,7 +109,7 @@ public: /// Inset * clone() const { return new InsetScript(*this); } /// - docstring contextMenuName() const; + std::string contextMenuName() const; //@} /// \name Public functions inherited from InsetText class diff --git a/src/insets/InsetSpace.cpp b/src/insets/InsetSpace.cpp index 081b98c44c..90d171e2d4 100644 --- a/src/insets/InsetSpace.cpp +++ b/src/insets/InsetSpace.cpp @@ -837,9 +837,9 @@ bool InsetSpace::isStretchableSpace() const } -docstring InsetSpace::contextMenuName() const +string InsetSpace::contextMenuName() const { - return from_ascii("context-space"); + return "context-space"; } diff --git a/src/insets/InsetSpace.h b/src/insets/InsetSpace.h index 753e3bf708..dc74faadca 100644 --- a/src/insets/InsetSpace.h +++ b/src/insets/InsetSpace.h @@ -150,7 +150,7 @@ public: // a line separator)? bool isSpace() const { return true; } /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// bool clickable(int /* x */, int /* y */) const { return true; } protected: diff --git a/src/insets/InsetTabular.cpp b/src/insets/InsetTabular.cpp index 55c96d8282..3cd8213b3a 100644 --- a/src/insets/InsetTabular.cpp +++ b/src/insets/InsetTabular.cpp @@ -3399,7 +3399,7 @@ void InsetTabular::write(ostream & os) const } -docstring InsetTabular::contextMenu(BufferView const &, int, int) const +string InsetTabular::contextMenu(BufferView const &, int, int) const { // FIXME: depending on the selection state, // we could offer a different menu. @@ -3407,9 +3407,9 @@ docstring InsetTabular::contextMenu(BufferView const &, int, int) const } -docstring InsetTabular::contextMenuName() const +string InsetTabular::contextMenuName() const { - return from_ascii("context-tabular"); + return "context-tabular"; } diff --git a/src/insets/InsetTabular.h b/src/insets/InsetTabular.h index 3a3f63a602..81b6c14e5a 100644 --- a/src/insets/InsetTabular.h +++ b/src/insets/InsetTabular.h @@ -824,9 +824,9 @@ public: /// InsetCode lyxCode() const { return TABULAR_CODE; } /// - docstring contextMenu(BufferView const &, int, int) const; + std::string contextMenu(BufferView const &, int, int) const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// get offset of this cursor slice relative to our upper left corner void cursorPos(BufferView const & bv, CursorSlice const & sl, bool boundary, int & x, int & y) const; diff --git a/src/insets/InsetText.cpp b/src/insets/InsetText.cpp index 77131a055b..09a5215050 100644 --- a/src/insets/InsetText.cpp +++ b/src/insets/InsetText.cpp @@ -848,18 +848,18 @@ void InsetText::completionPosAndDim(Cursor const & cur, int & x, int & y, } -docstring InsetText::contextMenu(BufferView const &, int, int) const +string InsetText::contextMenu(BufferView const &, int, int) const { - docstring context_menu = contextMenuName(); + string context_menu = contextMenuName(); if (context_menu != InsetText::contextMenuName()) context_menu += ";" + InsetText::contextMenuName(); return context_menu; } -docstring InsetText::contextMenuName() const +string InsetText::contextMenuName() const { - return from_ascii("context-edit"); + return "context-edit"; } diff --git a/src/insets/InsetText.h b/src/insets/InsetText.h index 704194c5d0..0110adf867 100644 --- a/src/insets/InsetText.h +++ b/src/insets/InsetText.h @@ -203,9 +203,9 @@ public: size_t numlines = 5, size_t len = 80) const; /// - docstring contextMenu(BufferView const &, int, int) const; + std::string contextMenu(BufferView const &, int, int) const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// void doDispatch(Cursor & cur, FuncRequest & cmd); protected: diff --git a/src/insets/InsetVSpace.cpp b/src/insets/InsetVSpace.cpp index 057435eeda..1e46425aa6 100644 --- a/src/insets/InsetVSpace.cpp +++ b/src/insets/InsetVSpace.cpp @@ -232,9 +232,9 @@ docstring InsetVSpace::xhtml(XHTMLStream &, OutputParams const &) const } -docstring InsetVSpace::contextMenuName() const +string InsetVSpace::contextMenuName() const { - return from_ascii("context-vspace"); + return "context-vspace"; } diff --git a/src/insets/InsetVSpace.h b/src/insets/InsetVSpace.h index 4a8a104931..f8df1d3b3f 100644 --- a/src/insets/InsetVSpace.h +++ b/src/insets/InsetVSpace.h @@ -32,7 +32,7 @@ public: /// bool hasSettings() const { return true; } /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// static void string2params(std::string const &, VSpace &); /// diff --git a/src/mathed/InsetMathHull.cpp b/src/mathed/InsetMathHull.cpp index 18dd602ae9..2d2025cca3 100644 --- a/src/mathed/InsetMathHull.cpp +++ b/src/mathed/InsetMathHull.cpp @@ -2252,9 +2252,9 @@ void InsetMathHull::forToc(docstring & os, size_t) const } -docstring InsetMathHull::contextMenuName() const +string InsetMathHull::contextMenuName() const { - return from_ascii("context-math"); + return "context-math"; } diff --git a/src/mathed/InsetMathHull.h b/src/mathed/InsetMathHull.h index 4bbb573174..d37fe3af14 100644 --- a/src/mathed/InsetMathHull.h +++ b/src/mathed/InsetMathHull.h @@ -163,7 +163,7 @@ public: void recordLocation(DocIterator const & di); /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// InsetCode lyxCode() const { return MATH_HULL_CODE; } diff --git a/src/mathed/InsetMathSpace.cpp b/src/mathed/InsetMathSpace.cpp index e53c62e6ee..6d873b3460 100644 --- a/src/mathed/InsetMathSpace.cpp +++ b/src/mathed/InsetMathSpace.cpp @@ -288,9 +288,9 @@ InsetSpaceParams InsetMathSpace::params() const } -docstring InsetMathSpace::contextMenuName() const +string InsetMathSpace::contextMenuName() const { - return from_ascii("context-mathspace"); + return "context-mathspace"; } diff --git a/src/mathed/InsetMathSpace.h b/src/mathed/InsetMathSpace.h index 83a9c59f45..4f16f1640b 100644 --- a/src/mathed/InsetMathSpace.h +++ b/src/mathed/InsetMathSpace.h @@ -61,7 +61,7 @@ public: /// bool hasSettings() const { return true; } /// - docstring contextMenuName() const; + std::string contextMenuName() const; /// bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const; /// diff --git a/src/mathed/MathMacroTemplate.cpp b/src/mathed/MathMacroTemplate.cpp index 2989e2be5c..2d36e4d223 100644 --- a/src/mathed/MathMacroTemplate.cpp +++ b/src/mathed/MathMacroTemplate.cpp @@ -1367,9 +1367,9 @@ void MathMacroTemplate::infoize(odocstream & os) const } -docstring MathMacroTemplate::contextMenuName() const +string MathMacroTemplate::contextMenuName() const { - return from_ascii("context-math-macro-definition"); + return "context-math-macro-definition"; } } // namespace lyx diff --git a/src/mathed/MathMacroTemplate.h b/src/mathed/MathMacroTemplate.h index 0efbb24a84..4e5fc72174 100644 --- a/src/mathed/MathMacroTemplate.h +++ b/src/mathed/MathMacroTemplate.h @@ -104,7 +104,7 @@ public: /// void infoize(odocstream & os) const; /// - docstring contextMenuName() const; + std::string contextMenuName() const; protected: /// virtual void doDispatch(Cursor & cur, FuncRequest & cmd);