]> git.lyx.org Git - lyx.git/blobdiff - src/insets/InsetSpecialChar.cpp
Fix GRAPHICS_EDIT of InsetGraphics
[lyx.git] / src / insets / InsetSpecialChar.cpp
index 0463795ee1210df7279b7b2d904edaab2c116365..e25cda94545b5cadec5497e98b7fc2970d1c2eb8 100644 (file)
@@ -14,7 +14,6 @@
 
 #include "InsetSpecialChar.h"
 
-#include "support/debug.h"
 #include "Dimension.h"
 #include "LaTeXFeatures.h"
 #include "Lexer.h"
 #include "frontends/FontMetrics.h"
 #include "frontends/Painter.h"
 
+#include "support/debug.h"
 #include "support/docstream.h"
 
-namespace lyx {
+using namespace std;
 
-using std::string;
-using std::ostream;
+namespace lyx {
 
 
 InsetSpecialChar::InsetSpecialChar(Kind k)
@@ -149,7 +148,7 @@ void InsetSpecialChar::draw(PainterInfo & pi, int x, int y) const
 
 
 // In lyxf3 this will be just LaTeX
-void InsetSpecialChar::write(Buffer const &, ostream & os) const
+void InsetSpecialChar::write(ostream & os) const
 {
        string command;
        switch (kind_) {
@@ -180,7 +179,7 @@ void InsetSpecialChar::write(Buffer const &, ostream & os) const
 
 
 // This function will not be necessary when lyx3
-void InsetSpecialChar::read(Buffer const &, Lexer & lex)
+void InsetSpecialChar::read(Lexer & lex)
 {
        lex.next();
        string const command = lex.getString();
@@ -204,7 +203,7 @@ void InsetSpecialChar::read(Buffer const &, Lexer & lex)
 }
 
 
-int InsetSpecialChar::latex(Buffer const &, odocstream & os,
+int InsetSpecialChar::latex(odocstream & os,
                            OutputParams const &) const
 {
        switch (kind_) {
@@ -234,8 +233,7 @@ int InsetSpecialChar::latex(Buffer const &, odocstream & os,
 }
 
 
-int InsetSpecialChar::plaintext(Buffer const &, odocstream & os,
-                               OutputParams const &) const
+int InsetSpecialChar::plaintext(odocstream & os, OutputParams const &) const
 {
        switch (kind_) {
        case HYPHENATION:
@@ -261,8 +259,7 @@ int InsetSpecialChar::plaintext(Buffer const &, odocstream & os,
 }
 
 
-int InsetSpecialChar::docbook(Buffer const &, odocstream & os,
-                             OutputParams const &) const
+int InsetSpecialChar::docbook(odocstream & os, OutputParams const &) const
 {
        switch (kind_) {
        case HYPHENATION:
@@ -288,16 +285,9 @@ int InsetSpecialChar::docbook(Buffer const &, odocstream & os,
 }
 
 
-int InsetSpecialChar::textString(Buffer const & buf, odocstream & os,
-                      OutputParams const & op) const
-{
-       return plaintext(buf, os, op);
-}
-
-
-Inset * InsetSpecialChar::clone() const
+void InsetSpecialChar::textString(odocstream & os) const
 {
-       return new InsetSpecialChar(kind_);
+       plaintext(os, OutputParams(0));
 }