Skip to content
Snippets Groups Projects
Commit 804b7341 authored by deuce's avatar deuce
Browse files

Added textcolor(), textbackground(), clreol(), and putch() for better

conio compatability.
parent f4849ba2
Branches
Tags
No related merge requests found
......@@ -331,6 +331,26 @@ void textattr(unsigned char attr)
bkgdset(colour);
}
void textbackground(int colour)
{
unsigned char attr;
attr=lastattr;
attr&=143;
attr|=(colour<<4);
textattr(attr);
}
void textcolor(int colour)
{
unsigned char attr;
attr=lastattr;
attr&=240;
attr|=colour;
textattr(attr);
}
int kbhit(void)
{
struct timeval timeout;
......
......@@ -48,6 +48,8 @@ struct text_info {
unsigned char screenwidth;
};
#define clreol() clrtoeol()
#define putch(x) echochar(x)
short curses_color(short color);
int puttext(int sx, int sy, int ex, int ey, unsigned char *fill);
#define gettext(x1,y1,x2,y2,z) cio_gettext(x1,y1,x2,y2,z)
......@@ -67,3 +69,5 @@ void clrscr(void);
void initciowrap(long inmode);
void gettextinfo(struct text_info *info);
void _setcursortype(int type);
void textbackground(int colour);
void textcolor(int colour);
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment