diff options
| author | Maxime Coste <frrrwww@gmail.com> | 2013-06-05 18:41:02 +0200 |
|---|---|---|
| committer | Maxime Coste <frrrwww@gmail.com> | 2013-06-06 19:44:07 +0200 |
| commit | 580749a91da1e293c9dc8c5f3a72aa9c5a5e7666 (patch) | |
| tree | b93b4b02550a4765504cb0b14f75f1fa08727976 /src/buffer.hh | |
| parent | 6b667bc803557de2d83cdc5f562c286bb66f86fa (diff) | |
Buffer: remove line_length and replace line_content with operator[]
Diffstat (limited to 'src/buffer.hh')
| -rw-r--r-- | src/buffer.hh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/buffer.hh b/src/buffer.hh index 7aacb841..4775f44b 100644 --- a/src/buffer.hh +++ b/src/buffer.hh @@ -134,8 +134,8 @@ public: BufferIterator end() const; ByteCount byte_count() const; LineCount line_count() const; - ByteCount line_length(LineCount line) const; - const String& line_content(LineCount line) const + + const String& operator[](LineCount line) const { return m_lines[line].content; } // returns an iterator at given coordinates. clamp line_and_column |
