X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2FCounters.h;h=ce122c4140ebbf71216cee445dfecc20457b3d58;hb=c6e1db7682dc8d58a68147b5eee1d004829ef6d2;hp=511c4902c84230c26e2dddf52fb1814f9878b691;hpb=152aba682f5dd5e7568b1508676374315f66e827;p=lyx.git diff --git a/src/Counters.h b/src/Counters.h index 511c4902c8..ce122c4140 100644 --- a/src/Counters.h +++ b/src/Counters.h @@ -76,6 +76,9 @@ public: private: /// int value_; + /// This is actually one less than the initial value, since the + /// counter is always stepped before being used. + int initial_value_; /// contains master counter name. /** The master counter is the counter that, if stepped * (incremented) zeroes this counter. E.g. "subsection"'s @@ -169,6 +172,10 @@ public: bool isSubfloat() const { return subfloat_; } /// Set the state variable indicating whether we are in a subfloat. void isSubfloat(bool s) { subfloat_ = s; } + /// Are we in a longtable? + bool isLongtable() const { return longtable_; } + /// Set the state variable indicating whether we are in a longtable. + void isLongtable(bool s) { longtable_ = s; } /// \name refstepcounter // @{ @@ -222,6 +229,8 @@ private: std::string current_float_; /// Are we in a subfloat? bool subfloat_; + /// Are we in a longtable? + bool longtable_; /// Used to keep track of active counters. std::vector counter_stack_; /// Same, but for last layout.