Method for querying the beginning and end of a line
| 526 | |
| 527 | // Method for querying the beginning and end of a line |
| 528 | bool ZepBuffer::GetLineOffsets(const long line, ByteRange& range) const |
| 529 | { |
| 530 | // Not valid |
| 531 | if ((long)m_lineEnds.size() <= line) |
| 532 | { |
| 533 | range.first = 0; |
| 534 | range.second = 0; |
| 535 | return false; |
| 536 | } |
| 537 | |
| 538 | // Find the line bounds - we know the end, find the start from the previous |
| 539 | range.second = m_lineEnds[line]; |
| 540 | range.first = line == 0 ? 0 : m_lineEnds[line - 1]; |
| 541 | return true; |
| 542 | } |
| 543 | |
| 544 | std::string ZepBuffer::GetFileExtension() const |
| 545 | { |
no test coverage detected