]> git.lyx.org Git - lyx.git/blobdiff - src/Paragraph.cpp
* src/LyXRC.{cpp,h}:
[lyx.git] / src / Paragraph.cpp
index 1d52e552d65b39bf7a6bfe4558ead5b4487c4b53..12a267fb5f48d1d90bb14f0b5dc8a733a707fb3b 100644 (file)
@@ -190,6 +190,10 @@ public:
        ///
        ParagraphParameters params_;
 
+       /// position of the paragraph in the buffer. Only macros from
+       /// paragraphs strictly smaller are visible in this paragraph
+       unsigned int macrocontext_position_;
+       
        /// for recording and looking up changes
        Changes changes_;
 
@@ -243,6 +247,7 @@ Paragraph::Private::Private(Paragraph * owner)
        : owner_(owner), inset_owner_(0), begin_of_body_(0)
 {
        id_ = paragraph_id++;
+       macrocontext_position_ = 0;
        text_.reserve(100);
 }
 
@@ -2489,6 +2494,18 @@ int Paragraph::checkBiblio(bool track_changes)
 }
 
 
+unsigned int Paragraph::macrocontextPosition() const
+{
+       return d->macrocontext_position_;
+}
+
+
+void Paragraph::setMacrocontextPosition(unsigned int pos)
+{
+       d->macrocontext_position_ = pos;
+}
+
+
 void Paragraph::checkAuthors(AuthorList const & authorList)
 {
        d->changes_.checkAuthors(authorList);