* @brief Get a line from the buffer. * @param [in] nLineIndex Index of the line to get. * @param [out] strLine Returns line text in the index. */
| 93 | * @param [out] strLine Returns line text in the index. |
| 94 | */ |
| 95 | bool CDiffTextBuffer::GetLine(int nLineIndex, String &strLine) const |
| 96 | { |
| 97 | int nLineLength = CCrystalTextBuffer::GetLineLength(nLineIndex); |
| 98 | if (nLineLength < 0) |
| 99 | return false; |
| 100 | else if (nLineLength == 0) |
| 101 | strLine.clear(); |
| 102 | else |
| 103 | strLine.assign(CCrystalTextBuffer::GetLineChars(nLineIndex), nLineLength); |
| 104 | return true; |
| 105 | } |
| 106 | |
| 107 | /** |
| 108 | * @brief Set the buffer modified status. |
no test coverage detected