comparison grapher.cpp @ 49:f9b53c10a3f6

* A fix that will only work when we sort changesets by date (test with classical-rdf)
author Chris Cannam
date Wed, 10 Nov 2010 22:27:58 +0000
parents 24efab584ee5
children bf3ab0ffb559
comparison
equal deleted inserted replaced
48:996b3c4037ef 49:f9b53c10a3f6
163 m_alloc[row].insert(col); 163 m_alloc[row].insert(col);
164 item->setColumn(col); 164 item->setColumn(col);
165 m_handled.insert(id); 165 m_handled.insert(id);
166 166
167 int nchildren = cs->children().size(); 167 int nchildren = cs->children().size();
168
169 // look for merging children and make sure nobody
170 // is going to overwrite their "merge lines"
171 foreach (QString childId, cs->children()) {
172 if (!m_changesets.contains(childId)) continue;
173 Changeset *child = m_changesets[childId];
174 if (child->parents().size() > 1) {
175 int childRow = m_items[childId]->row();
176 std::cerr << "I'm at " << row << ", child with >1 parents is at " << childRow << std::endl;
177 for (int r = row; r >= childRow; --r) {
178 std::cerr << "setting row " << r << ", col " << col << std::endl;
179 m_alloc[r].insert(col);
180 }
181 }
182 }
183
168 if (nchildren > 1) { 184 if (nchildren > 1) {
169 // Normally the children will lay out themselves. We just 185 // Normally the children will lay out themselves. We just
170 // want to handle the case where exactly two children have the 186 // want to handle the case where exactly two children have the
171 // same branch as us, because we can handle that neatly 187 // same branch as us, because we can handle that neatly
172 QList<QString> special; 188 QList<QString> special;