git.ucc.asn.au
/
tpg
/
acess2.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4d498b0
)
Kernel - Fixed VTerm tab behavior when width is not a multiple of 8
author
John Hodge
<
[email protected]
>
Sun, 3 Jul 2011 03:11:02 +0000
(11:11 +0800)
committer
John Hodge
<
[email protected]
>
Sun, 3 Jul 2011 03:11:02 +0000
(11:11 +0800)
Kernel/drv/vterm.c
patch
|
blob
|
history
diff --git
a/Kernel/drv/vterm.c
b/Kernel/drv/vterm.c
index
2b9f656
..
de920d8
100644
(file)
--- a/
Kernel/drv/vterm.c
+++ b/
Kernel/drv/vterm.c
@@
-1247,13
+1247,15
@@
void VT_int_PutChar(tVTerm *Term, Uint32 Ch)
write_pos -= write_pos % Term->TextWidth;
break;
- case '\t':
+ case '\t': { int tmp = write_pos / Term->TextWidth;
+ write_pos %= Term->TextWidth;
do {
buffer[ write_pos ].Ch = '\0';
buffer[ write_pos ].Colour = Term->CurColour;
write_pos ++;
} while(write_pos & 7);
- break;
+ write_pos += tmp * Term->TextWidth;
+ break; }
case '\b':
// Backspace is invalid at Offset 0
UCC
git Repository :: git.ucc.asn.au