]> git.lyx.org Git - features.git/commitdiff
add some NO_NEXT ifdefs
authorLars Gullik Bjønnes <larsbj@gullik.org>
Thu, 15 Aug 2002 07:53:46 +0000 (07:53 +0000)
committerLars Gullik Bjønnes <larsbj@gullik.org>
Thu, 15 Aug 2002 07:53:46 +0000 (07:53 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@4985 a592a061-630c-0410-9148-cb99ea01b6c8

src/ChangeLog
src/paragraph.C
src/paragraph.h

index 487d479e36f73b632dc4a4d3f57aa93c6c3ef8c3..3803a3d198dea1ca64ec86e4f14856d29de8a6c9 100644 (file)
@@ -1,3 +1,7 @@
+2002-08-15  Lars Gullik Bjønnes  <larsbj@gullik.net>
+
+       * paragraph.[Ch]: add some NO_NEXT ifdefs.
+
 2002-08-15  Lars Gullik Bjønnes  <larsbj@gullik.net>
 
        * paragraph.C (Paragraph): reformat a bit
index 14e8880ef9ded7c5f6e5b667815cd486e54f8783..8b4a2e1ed7318eb3d8f53cc12a48ad04344ee07f 100644 (file)
@@ -76,8 +76,10 @@ extern BufferView * current_view;
 Paragraph::Paragraph()
        : pimpl_(new Paragraph::Pimpl(this))
 {
+#ifndef NO_NEXT
        next_ = 0;
        previous_ = 0;
+#endif
        enumdepth = 0;
        itemdepth = 0;
        bibkey = 0; // ale970302
@@ -85,6 +87,7 @@ Paragraph::Paragraph()
 }
 
 
+#ifndef NO_NEXT
 // This constructor inserts the new paragraph in a list.
 Paragraph::Paragraph(Paragraph * par)
        : pimpl_(new Paragraph::Pimpl(this))
@@ -103,6 +106,7 @@ Paragraph::Paragraph(Paragraph * par)
        bibkey = 0; // ale970302
        params().clear();
 }
+#endif
 
 
 Paragraph::Paragraph(Paragraph const & lp, bool same_ids)
@@ -110,9 +114,10 @@ Paragraph::Paragraph(Paragraph const & lp, bool same_ids)
 {
        enumdepth = 0;
        itemdepth = 0;
+#ifndef NO_NEXT
        next_     = 0;
        previous_ = 0;
-
+#endif
        // this is because of the dummy layout of the paragraphs that
        // follow footnotes
        layout_ = lp.layout();
@@ -141,10 +146,12 @@ Paragraph::Paragraph(Paragraph const & lp, bool same_ids)
 // the destructor removes the new paragraph from the list
 Paragraph::~Paragraph()
 {
+#ifndef NO_NEXT
        if (previous_)
                previous_->next_ = next_;
        if (next_)
                next_->previous_ = previous_;
+#endif
 
        // ale970302
        delete bibkey;
@@ -688,7 +695,7 @@ void Paragraph::setFont(pos_type pos, LyXFont const & font)
 }
 
 
-
+#ifndef NO_NEXT
 void Paragraph::next(Paragraph * p)
 {
        next_ = p;
@@ -726,6 +733,7 @@ Paragraph const * Paragraph::previous() const
 {
        return previous_;
 }
+#endif
 
 
 void Paragraph::breakParagraph(BufferParams const & bparams,
@@ -1050,6 +1058,7 @@ Paragraph const * Paragraph::depthHook(depth_type depth) const
        return newpar;
 }
 
+
 Paragraph * Paragraph::outerHook()
 {
        if (!getDepth())
@@ -1057,6 +1066,7 @@ Paragraph * Paragraph::outerHook()
        return depthHook(depth_type(getDepth() - 1));
 }
 
+
 Paragraph const * Paragraph::outerHook() const
 {
        if (!getDepth())
@@ -1303,6 +1313,7 @@ Paragraph * Paragraph::TeXOnePar(Buffer const * buf,
        return next_;
 }
 
+
 // This could go to ParagraphParameters if we want to
 int Paragraph::startTeXParParams(BufferParams const & bparams,
                                 ostream & os, bool moving_arg) const
@@ -1363,6 +1374,7 @@ int Paragraph::startTeXParParams(BufferParams const & bparams,
        return column;
 }
 
+
 // This could go to ParagraphParameters if we want to
 int Paragraph::endTeXParParams(BufferParams const & bparams,
                               ostream & os, bool moving_arg) const
index 10023bf801c10e9d9bf3a8402541376ba03c2453..7aa11cbc098c03486ef44f96d9f5148e4cd4bc67 100644 (file)
@@ -83,9 +83,11 @@ public:
 
        ///
        Paragraph();
+#ifndef NO_NEXT
        /// this constructor inserts the new paragraph in a list
        explicit
        Paragraph(Paragraph * par);
+#endif
        ///
        Paragraph(Paragraph const &, bool same_ids);
        /// the destructor removes the new paragraph from the list
@@ -181,6 +183,7 @@ public:
        ///
        InsetBibKey * bibkey;  // ale970302
 
+#ifndef NO_NEXT
        ///
        void next(Paragraph *);
        /** these function are able to hide closed footnotes
@@ -195,7 +198,7 @@ public:
        Paragraph * previous();
        ///
        Paragraph const * previous() const;
-
+#endif
        /// for the environments
        Paragraph * depthHook(depth_type depth);
        /// for the environments
@@ -342,11 +345,12 @@ private:
        LyXLayout_ptr layout_;
        /// if anything uses this we don't want it to.
        Paragraph(Paragraph const &);
+#ifndef NO_NEXT
        ///
        Paragraph * next_;
        ///
        Paragraph * previous_;
-
+#endif
        struct Pimpl;
        ///
        friend struct Paragraph::Pimpl;