It is shocking to me how little known the rope data structure [0] and the order statistic tree [1] are. Especially in the context of text editors.
[0]: https://en.wikipedia.org/wiki/Rope_(data_structure) [1]: https://en.wikipedia.org/wiki/Order_statistic_tree