Texonom
Texonom
/
Computing
Computing
/Data/Data Structure/Array Data/Dynamic array/
Gap buffer
Search

Gap buffer

Creator
Creator
Seonglae Cho
Created
Created
2023 Oct 19 7:19
Editor
Editor
Seonglae Cho
Edited
Edited
2023 Dec 9 8:31
Refs
Refs
String
 
 
 
 
 
 
 
Gap buffer
A gap buffer in computer science is a dynamic array that allows efficient insertion and deletion operations clustered near the same location. Gap buffers are especially common in text editors, where most changes to the text occur at or near the current location of the cursor. The text is stored in a large buffer in two contiguous segments, with a gap between them for inserting new text. Moving the cursor involves copying text from one side of the gap to the other (sometimes copying is delayed until the next operation that changes the text). Insertion adds new text at the end of the first segment; deletion deletes it.
Gap buffer
https://en.wikipedia.org/wiki/Gap_buffer
 

Recommendations

Texonom
Texonom
/
Computing
Computing
/Data/Data Structure/Array Data/Dynamic array/
Gap buffer
Copyright Seonglae Cho