]> git.lyx.org Git - lyx.git/blobdiff - src/insets/InsetBox.h
Fix GRAPHICS_EDIT of InsetGraphics
[lyx.git] / src / insets / InsetBox.h
index 4aa9336c6804d3c1222ba0af677ce504130d354c..4f207c28a832dbcb370ab9bc3afb1f932081285c 100644 (file)
@@ -57,10 +57,25 @@ public:
 */
 class InsetBox : public InsetCollapsable {
 public:
+       ///
+       enum BoxType {
+               Frameless,
+               Boxed,
+               Framed,
+               ovalbox,
+               Ovalbox,
+               Shadowbox,
+               Shaded,
+               Doublebox
+       };
        ///
        InsetBox(Buffer const &, std::string const &);
        ///
        ~InsetBox();
+private:
+       ///
+       friend class InsetBoxParams;
+       friend class InsetBoxMailer;
        ///
        docstring editMessage() const;
        ///
@@ -79,17 +94,16 @@ public:
        bool showInsetDialog(BufferView * bv) const;
        ///
        DisplayType display() const { return Inline; }
-       //FIXME Is this the one we want? or is it:
-       //allowParagraphCustomization(idx_type)?
        ///
-       virtual bool forceEmptyLayout() const;
+       virtual bool allowParagraphCustomization(idx_type = 0)
+               { return forceEmptyLayout(); }
+       ///
+       virtual bool forceEmptyLayout(idx_type = 0) const;
        ///
        bool neverIndent() const { return true; }
        ///
        bool noFontChange() const { return true; }
        ///
-       bool isMacroScope() const;
-       ///
        int latex(odocstream &, OutputParams const &) const;
        ///
        int plaintext(odocstream &, OutputParams const &) const;
@@ -102,28 +116,14 @@ public:
        ///
        bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const;
        ///
-       enum BoxType {
-               Frameless,
-               Boxed,
-               Framed,
-               ovalbox,
-               Ovalbox,
-               Shadowbox,
-               Shaded,
-               Doublebox
-       };
-protected:
-       InsetBox(InsetBox const &);
-       virtual void doDispatch(Cursor & cur, FuncRequest & cmd);
+       void doDispatch(Cursor & cur, FuncRequest & cmd);
        /// Is the width forced to some value?
-       virtual bool hasFixedWidth() const;
-private:
-       friend class InsetBoxParams;
-
-       virtual Inset * clone() const;
-
+       bool hasFixedWidth() const;
+       ///
+       Inset * clone() const { return new InsetBox(*this); }
        /// used by the constructors
        void init();
+
        ///
        InsetBoxParams params_;
 };