Terminal: insert space on tab only at the end of the line.

This commit is contained in:
Jérôme Duval
2016-11-02 22:04:00 +01:00
parent 1674f60dae
commit 2085048ea9
+4 -2
View File
@@ -745,8 +745,10 @@ BasicTerminalBuffer::InsertTab()
if (x != fCursor.x) {
TerminalLine* line = _LineAt(fCursor.y);
for (int32 i = fCursor.x; i <= x; i++) {
line->cells[i].character = ' ';
line->cells[i].attributes = fAttributes;
if (line->length <= i) {
line->cells[i].character = ' ';
line->cells[i].attributes = fAttributes;
}
}
fCursor.x = x;
if (line->length < fCursor.x)