]> git.lyx.org Git - lyx.git/blobdiff - src/insets/insetmarginal.C
Enable convertDefault.sh to run even if its executable bit is not set.
[lyx.git] / src / insets / insetmarginal.C
index 76ca85581f9082ffb4df010086a8cfb92e845cb6..853219bf143e23f40ead018b96cfe6cfafd7caec 100644 (file)
@@ -6,7 +6,7 @@
  * \author Jürgen Vigna
  * \author Lars Gullik Bjønnes
  *
- * Full author contact details are available in file CREDITS
+ * Full author contact details are available in file CREDITS.
  */
 
 #include <config.h>
@@ -23,6 +23,7 @@
 
 
 using std::ostream;
+using std::auto_ptr;
 
 
 InsetMarginal::InsetMarginal(BufferParams const & bp)
@@ -41,33 +42,19 @@ InsetMarginal::InsetMarginal(InsetMarginal const & in)
 }
 
 
-// InsetMarginal::InsetMarginal(InsetMarginal const & in, bool same_id)
-//     : InsetFootlike(in, same_id)
-// {
-//     setLabel(_("margin"));
-//     setInsetName("Marginal");
-// }
-
-
-Inset * InsetMarginal::clone(Buffer const &) const
+auto_ptr<InsetBase> InsetMarginal::clone() const
 {
-       return new InsetMarginal(*const_cast<InsetMarginal *>(this));
+       return auto_ptr<InsetBase>(new InsetMarginal(*this));
 }
 
 
-// Inset * InsetMarginal::clone(Buffer const &, bool same_id) const
-// {
-//     return new InsetMarginal(*const_cast<InsetMarginal *>(this), same_id);
-// }
-
-
 string const InsetMarginal::editMessage() const
 {
        return _("Opened Marginal Note Inset");
 }
 
 
-int InsetMarginal::latex(Buffer const * buf, ostream & os,
+int InsetMarginal::latex(Buffer const & buf, ostream & os,
                         LatexRunParams const & runparams) const
 {
        os << "%\n\\marginpar{";