]> git.lyx.org Git - lyx.git/blobdiff - src/insets/insetlist.C
some reindentation, revert workarea xpos++, constify, remove all traces of LyXParagra...
[lyx.git] / src / insets / insetlist.C
index 2b67d1946819cdcbb525410b67ac2e48687dee8a..d9199c3567e6fd245f190d3381a3134938c7c09b 100644 (file)
 #include "gettext.h"
 #include "lyxfont.h"
 #include "BufferView.h"
-#include "Painter.h"
 #include "lyxtext.h"
 #include "insets/insettext.h"
 #include "support/LOstream.h"
+#include "debug.h"
 
 using std::ostream;
 using std::endl;
@@ -57,17 +57,17 @@ void InsetList::Write(Buffer const * buf, ostream & os) const
 }
 
 
-Inset * InsetList::Clone() const
+Inset * InsetList::Clone(Buffer const &) const
 {
        InsetList * result = new InsetList;
-       result->inset->init(inset);
+       result->inset.init(&inset);
        
        result->collapsed = collapsed;
        return result;
 }
 
 
-char const * InsetList::EditMessage() const
+string const InsetList::EditMessage() const
 {
        return _("Opened List Inset");
 }
@@ -78,22 +78,13 @@ int InsetList::Latex(Buffer const * buf,
 {
        os << "\\footnote{%\n";
        
-       int i = inset->Latex(buf, os, fragile, fp);
+       int i = inset.Latex(buf, os, fragile, fp);
        os << "}%\n";
        
        return i + 2;
 }
 
 
-bool InsetList::InsertInset(BufferView * bv, Inset * in)
-{
-       if (!InsertInsetAllowed(in))
-               return false;
-       
-       return inset->InsertInset(bv, in);
-}
-
-
 bool InsetList::InsertInsetAllowed(Inset * in) const
 {
        if ((in->LyxCode() == Inset::FOOT_CODE) ||
@@ -102,12 +93,3 @@ bool InsetList::InsertInsetAllowed(Inset * in) const
        }
        return true;
 }
-
-#if 0
-LyXFont InsetList::GetDrawFont(BufferView * bv,LyXParagraph * p, int pos) const
-{
-       LyXFont fn = getLyXText(bv)->GetFont(bv->buffer(), p, pos);
-       fn.decSize().decSize();
-       return fn;
-}
-#endif