Commit Graph

9 Commits

Author SHA1 Message Date
Maxime Coste
9337938403 replace std::string references with String 2012-04-14 01:17:09 +00:00
Maxime Coste
e4b872abd2 remove ModificationListener and use a list of iterators to update instead
This permits to fix a bug in BufferIterator::upgrade, replaced by
BufferIterator::on_insert and BufferIterator::on_erase. ModificationListener
was only used to updating iterators anyway.
2012-04-04 13:56:19 +00:00
Maxime Coste
2cd318e50d fix BufferIterator::update when removing an end of line 2012-04-01 15:40:25 +00:00
Maxime Coste
07e1fcf67b specialize BufferIterator::operator-- 2012-03-31 15:21:14 +00:00
Maxime Coste
45e362d213 specialize BufferIterator::operator++ to speed up Kakoune 2012-03-30 12:01:18 +00:00
Maxime Coste
2e7cd2233c add a Line::length method 2012-03-30 12:00:40 +00:00
Maxime Coste
0ba7c7286d Store buffer content in a list of lines
Instead of a big std::string, buffer now store it's content in a
list of lines. In order to achieve O(log(n)) random access, lines
contains both their content and their offset since the start of
the file, making binary search usable.

BufferIterator now have a LineAndColumn coordinate into the buffer
instead of an offset so that access is still O(1).
2012-03-30 11:37:18 +00:00
Maxime Coste
3dd82a2b85 get rid of Buffer::at 2012-03-19 14:04:33 +00:00
Maxime Coste
62482b65ec rename buffer_iterator.inl.h to buffer_iterator.inl.hh 2011-10-27 14:13:39 +00:00