git.ucc.asn.au
/
tpg
/
acess2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Cleaned up some TODOs
[tpg/acess2.git]
/
Usermode
/
Applications
/
gui_shell_src
/
display.c
diff --git
a/Usermode/Applications/gui_shell_src/display.c
b/Usermode/Applications/gui_shell_src/display.c
index
0651634
..
bb07e39
100644
(file)
--- a/
Usermode/Applications/gui_shell_src/display.c
+++ b/
Usermode/Applications/gui_shell_src/display.c
@@
-79,14
+79,15
@@
void Display_AddText(int Length, const char *UTF8Text)
{
uint32_t cp;
bytes += ReadUTF8(UTF8Text+bytes, &cp);
- if( Unicode_IsPrinting(cp) )
+ if( Unicode_IsPrinting(cp) )
{
space --;
+ giCurrentCol ++;
+ }
}
Display_int_PushString(bytes, UTF8Text);
UTF8Text += bytes;
- _SysDebug("Length(%i) -= bytes(%i)", Length, bytes);
Length -= bytes;
if( Length != 0 )
{
@@
-100,7
+101,7
@@
void Display_AddText(int Length, const char *UTF8Text)
void Display_Newline(int bCarriageReturn)
{
-
Display_Flush();
+
//
Display_Flush();
// Going down!
giCurrentLine ++;
@@
-146,7
+147,23
@@
void Display_SetCursor(int Row, int Col)
void Display_MoveCursor(int RelRow, int RelCol)
{
- UNIMPLIMENTED();
+ if( RelRow < 0 )
+ {
+ for( ; RelRow < 0; RelRow ++ )
+ {
+ uint32_t cp;
+ int delta = ReadUTF8Rev(gasDisplayLines[giCurrentLine], giCurrentLinePos, &cp);
+ if( !Unicode_IsPrinting(cp) )
+ RelRow --;
+ else
+ giCurrentCol --;
+ giCurrentLinePos -= delta;
+ }
+ }
+ else
+ {
+ UNIMPLIMENTED();
+ }
}
void Display_ClearLine(int Dir) // 0: All, 1: Forward, -1: Reverse
@@
-220,8
+237,6
@@
void Display_Flush(void)
AxWin3_RichText_SendLine(gMainWindow, giFirstLine + i, gasDisplayLines[line] );
gabDisplayLinesDirty[line] = 0;
}
-
- // force redraw?
AxWin3_RichText_SetCursorPos(gMainWindow, giCurrentLine, giCurrentCol);
}
UCC
git Repository :: git.ucc.asn.au