X-Git-Url: https://jxself.org/git/?a=blobdiff_plain;f=conio.c;h=95e8a78c81085bdd1f1aa5483e352c719915e0a6;hb=a96a31750d67dfc0d4636aae4040155f78d5eda8;hp=9c37ad5225c654155d7474ad6a1ea2ff3f0e56d5;hpb=49483a1747cd310e33eea758b32a453fb46d4aac;p=super-star-trek.git diff --git a/conio.c b/conio.c index 9c37ad5..95e8a78 100644 --- a/conio.c +++ b/conio.c @@ -124,9 +124,12 @@ char *cgets (char *str) /* ugly function :-( */ } void clreol (void) +/* clear to end of line -- can be a no-op in tty mode */ { +#ifdef SERGEEV wclrtoeol(conio_scr); wrefresh(conio_scr); +#endif /* SERGEEV */ } void clrscr (void) @@ -215,17 +218,22 @@ void gettextinfo(struct text_info *inforec) } void gotoxy (int x, int y) +/* address cusor -- OK for this to be a no-op in TTY mode */ { +#ifdef SERGEEV y--; x--; wmove(conio_scr,y,x); wrefresh(conio_scr); +#endif /* SERGEEV */ } void highvideo (void) { +#ifdef SERGEEV textcolor(15); /* White */ textbackground(0); /* Black */ +#endif /* SERGEEV */ } void insline (void) @@ -276,11 +284,14 @@ void textbackground (int color) docolor(color); } + void textcolor (int color) { +#ifdef SERGEEV fgc=color; color=(bgc*16)+fgc; docolor(color); +#endif /* SERGEEV */ } void textmode (int mode)