+ /// The pointer is const although its contents may not be
+ boost::scoped_ptr<Counters> const ctrs;
+
+public:
+ ///
+ class inset_iterator {
+ public:
+ typedef std::input_iterator_tag iterator_category;
+ typedef Inset value_type;
+ typedef ptrdiff_t difference_type;
+ typedef Inset * pointer;
+ typedef Inset & reference;
+ typedef ParagraphList::iterator base_type;
+
+ ///
+ inset_iterator();
+ ///
+ inset_iterator(base_type p, base_type e);
+ ///
+ inset_iterator(base_type p, lyx::pos_type pos, base_type e);
+
+ /// prefix ++
+ inset_iterator & operator++();
+ /// postfix ++
+ inset_iterator operator++(int);
+ ///
+ reference operator*();
+ ///
+ pointer operator->();
+
+ ///
+ Paragraph * getPar();
+ ///
+ lyx::pos_type getPos() const;
+ ///
+ friend
+ bool operator==(inset_iterator const & iter1,
+ inset_iterator const & iter2);
+ private:
+ ///
+ void setParagraph();
+ ///
+ ParagraphList::iterator pit;
+ ///
+ ParagraphList::iterator pend;
+ ///
+ InsetList::iterator it;
+ };
+
+ ///
+ inset_iterator inset_iterator_begin() {
+ return inset_iterator(paragraphs.begin(), paragraphs.end());
+ }
+
+ ///
+ inset_iterator inset_iterator_end() {
+ return inset_iterator();
+ }
+
+ ///
+ inset_iterator inset_const_iterator_begin() const {
+ return inset_iterator(paragraphs.begin(), paragraphs.end());
+ }
+
+ ///
+ inset_iterator inset_const_iterator_end() const {
+ return inset_iterator();
+ }
+
+ ///
+ ParIterator par_iterator_begin();
+ ///
+ ParIterator par_iterator_end();
+
+ ///
+ Inset * getInsetFromID(int id_arg) const;
+};