4 * Copyright 1995-2002 the LyX Team
5 * Read the file COPYING
7 * \author Matthias Ettrich
17 /// Represents the correspondence between paragraphs and the generated LaTeX file
21 TexRow() : count(0), lastid(-1), lastpos(-1) {}
23 TexRow & operator+= (TexRow const &);
28 /// Define what paragraph and position the next row will represent
29 void start(int id, int pos);
31 /// Insert node when line is completed
35 * getIdFromRow - find pid and position for a given row
36 * @param row row number to find
37 * @param id set to id if found
38 * @param pos set to paragraph position if found
39 * @return true if found, false otherwise
41 * If the row could not be found, pos is set to zero and
44 bool getIdFromRow(int row, int & id, int & pos) const;
46 /// Returns the number of rows contained
47 int rows() const { return count; }
49 /// an individual id/pos <=> row mapping
52 RowItem(int id, int pos, int row)
53 : id_(id), pos_(pos), rownumber_(row)
61 /// set paragraph position
66 /// paragraph position
72 int rownumber() const {
81 typedef std::list<RowItem> RowList;
82 /// increment position of all other RowItems
83 /// with same par id, to avoid placing error insets
84 /// at the same position
85 void increasePos(int id, int pos);
89 /// container of id/pos <=> row mapping