2016-09-06 11:16:38 +00:00
|
|
|
/**
|
2016-09-11 20:20:15 +00:00
|
|
|
* Author......: See docs/credits.txt
|
2016-09-06 11:16:38 +00:00
|
|
|
* License.....: MIT
|
|
|
|
*/
|
|
|
|
|
2016-09-06 16:44:05 +00:00
|
|
|
#ifndef _TERMINAL_H
|
|
|
|
#define _TERMINAL_H
|
2016-09-06 11:16:38 +00:00
|
|
|
|
|
|
|
#include <stdio.h>
|
2016-09-11 08:39:19 +00:00
|
|
|
#include <string.h>
|
2016-09-06 11:16:38 +00:00
|
|
|
#include <sys/time.h>
|
|
|
|
#include <sys/types.h>
|
|
|
|
#include <unistd.h>
|
|
|
|
|
2016-09-07 20:29:57 +00:00
|
|
|
#if defined (_POSIX)
|
2016-09-06 11:16:38 +00:00
|
|
|
#include <termios.h>
|
2016-09-07 20:29:57 +00:00
|
|
|
#if defined (__APPLE__)
|
2016-09-06 20:25:54 +00:00
|
|
|
#include <sys/ioctl.h>
|
|
|
|
#endif // __APPLE__
|
2016-09-06 11:16:38 +00:00
|
|
|
#endif // _POSIX
|
|
|
|
|
2016-09-07 20:29:57 +00:00
|
|
|
#if defined (_WIN)
|
2016-09-06 11:16:38 +00:00
|
|
|
#include <windows.h>
|
|
|
|
#endif // _WIN
|
|
|
|
|
2016-09-11 08:39:19 +00:00
|
|
|
void send_prompt ();
|
|
|
|
void clear_prompt ();
|
|
|
|
|
2016-09-15 02:21:41 +00:00
|
|
|
void *thread_keypress (void *p);
|
|
|
|
|
2016-09-08 07:21:25 +00:00
|
|
|
#if defined (_WIN)
|
|
|
|
void SetConsoleWindowSize (const int x);
|
|
|
|
#endif
|
|
|
|
|
2016-09-06 11:16:38 +00:00
|
|
|
int tty_break();
|
|
|
|
int tty_getchar();
|
|
|
|
int tty_fix();
|
2016-09-06 16:44:05 +00:00
|
|
|
|
|
|
|
#endif // _TERMINAL_H
|