#include "math_mathmlstream.h"
#include "dispatchresult.h"
#include "funcrequest.h"
-#include "support/std_sstream.h"
+#include "support/std_sstream.h"
using std::string;
using std::auto_ptr;
CommandInset::CommandInset(string const & name)
- : MathNestInset(2),
- name_(name),
- set_label_(false)
+ : MathNestInset(2), name_(name), set_label_(false)
{
lock_ = true;
}
button_.update(screenLabel(), true);
}
button_.metrics(mi, dim);
+ dim_ = dim;
}
string const CommandInset::screenLabel() const
{
- return name_;
+ return name_;
}
string const CommandInset::createDialogStr(string const & name) const
{
- ostringstream data;
- data << name << " LatexCommand ";
- WriteStream wsdata(data);
- write(wsdata);
- wsdata << "\n\\end_inset\n\n";
- return data.str();
+ ostringstream os;
+ os << name << " LatexCommand ";
+ WriteStream ws(os);
+ write(ws);
+ ws << "\n\\end_inset\n\n";
+ return os.str();
}
virtual std::string const screenLabel() const;
/// generate something that will be understood by the Dialogs.
std::string const createDialogStr(std::string const & name) const;
-
+ ///
std::string const & commandname() const { return name_; }
private:
+ ///
std::string name_;
+ ///
mutable bool set_label_;
+ ///
mutable RenderButton button_;
};
#include <config.h>
#include "ref_inset.h"
-#include "math_data.h"
-#include "math_factory.h"
#include "BufferView.h"
+#include "LaTeXFeatures.h"
#include "cursor.h"
#include "debug.h"
#include "funcrequest.h"
-#include "math_support.h"
#include "gettext.h"
-#include "LaTeXFeatures.h"
+#include "math_data.h"
+#include "math_factory.h"
+#include "math_support.h"
#include "frontends/LyXView.h"
#include "frontends/Dialogs.h"
case LFUN_MOUSE_RELEASE:
if (cmd.button() == mouse_button::button3) {
- lyxerr << "trying to goto ref" << cell(0) << endl;
+ lyxerr << "trying to goto ref '" << asString(cell(0)) << "'" << endl;
cur.bv().dispatch(FuncRequest(LFUN_REF_GOTO, asString(cell(0))));
break;
}