]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathRef.h
Fix bug 5802 (http://bugzilla.lyx.org/show_bug.cgi?id=5802)
[lyx.git] / src / mathed / InsetMathRef.h
index c70158252f2aeee63e605fceb797974c6998689e..da324522b9de9e8be4a5531331dacb86976d57e4 100644 (file)
@@ -4,7 +4,7 @@
  * This file is part of LyX, the document processor.
  * Licence details can be found in the file COPYING.
  *
- * \author André Pönitz
+ * \author André Pönitz
  *
  * Full author contact details are available in file CREDITS.
  */
 #define REF_INSET_H
 
 
-#include "InsetMathCommand.h"
+#include "CommandInset.h"
 
 
 namespace lyx {
 class Buffer;
 
 // for \ref
-class RefInset : public CommandInset {
+class InsetMathRef : public CommandInset {
 public:
        ///
-       RefInset();
+       InsetMathRef();
        ///
-       explicit RefInset(std::string const & data);
+       explicit InsetMathRef(docstring const & data);
        ///
        //void write(WriteStream & os) const;
        ///
-       void infoize(std::ostream & os) const;
+       void infoize(odocstream & os) const;
        ///
        docstring const screenLabel() const;
        ///
        void validate(LaTeXFeatures & features) const;
        ///
-       virtual RefInset * asRefInset() { return this; }
+       virtual InsetMathRef * asRefInset() { return this; }
 
-       /// plain text output in ucs4 encoding
-       int plaintext(odocstream &, OutputParams const &) const;
        /// docbook output
-       int docbook(Buffer const & buf, odocstream & os, OutputParams const &) const;
+       int docbook(odocstream & os, OutputParams const &) const;
+       /// generate something that will be understood by the Dialogs.
+       std::string const createDialogStr(std::string const & name) const;
 
        struct ref_type_info {
                ///
-               std::string latex_name;
+               docstring latex_name;
                ///
-               std::string gui_name;
+               docstring gui_name;
                ///
-               std::string short_gui_name;
+               docstring short_gui_name;
        };
        static ref_type_info types[];
        ///
-       static int getType(std::string const & name);
+       static int getType(docstring const & name);
        ///
-       static std::string const & getName(int type);
+       static docstring const & getName(int type);
 protected:
        ///
-       virtual void doDispatch(LCursor & cur, FuncRequest & cmd);
+       virtual void doDispatch(Cursor & cur, FuncRequest & cmd);
        ///
-       bool getStatus(LCursor &, FuncRequest const &, FuncStatus &) const;
+       bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const;
 private:
        ///
-       virtual std::auto_ptr<InsetBase> doClone() const;
+       virtual Inset * clone() const;
 };