| 587 | } |
| 588 | |
| 589 | LineRef DiffTextWindow::convertDiff3LineIdxToLine(const LineType d3lIdx) const |
| 590 | { |
| 591 | assert(d3lIdx >= 0); |
| 592 | |
| 593 | if(d->m_bWordWrap && d->getDiff3LineVector() != nullptr && d->getDiff3LineVector()->size() > 0) |
| 594 | return (*d->getDiff3LineVector())[std::min((size_t)d3lIdx, d->getDiff3LineVector()->size() - 1)]->sumLinesNeededForDisplay(); |
| 595 | else |
| 596 | return d3lIdx; |
| 597 | } |
| 598 | |
| 599 | /** Returns a line number where the linerange [line, line+nofLines] can |
| 600 | be displayed best. If it fits into the currently visible range then |
no test coverage detected