home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 7 / 07.iso / c / c021 / 7.img / INCLUDE.ZIP / CONIO.H < prev    next >
Encoding:
C/C++ Source or Header  |  1990-05-04  |  2.5 KB  |  111 lines

  1. /*    conio.h
  2.  
  3.     Direct MSDOS console input/output.
  4.  
  5.         Copyright (c) Borland International 1987,1988,1990
  6.     All Rights Reserved.
  7. */
  8. #if    !defined(__VIDEO)
  9. #define __VIDEO
  10.  
  11. #if __STDC__
  12. #define _Cdecl
  13. #else
  14. #define _Cdecl    cdecl
  15. #endif
  16.  
  17. #ifndef __PAS__
  18. #define _CType _Cdecl
  19. #else
  20. #define _CType pascal
  21. #endif
  22.  
  23. #define _NOCURSOR      0
  24. #define _SOLIDCURSOR   1
  25. #define _NORMALCURSOR  2
  26.  
  27. struct text_info {
  28.     unsigned char winleft;
  29.     unsigned char wintop;
  30.     unsigned char winright;
  31.     unsigned char winbottom;
  32.     unsigned char attribute;
  33.     unsigned char normattr;
  34.     unsigned char currmode;
  35.     unsigned char screenheight;
  36.     unsigned char screenwidth;
  37.     unsigned char curx;
  38.     unsigned char cury;
  39. };
  40.  
  41. enum text_modes { LASTMODE=-1, BW40=0, C40, BW80, C80, MONO=7, C4350=64 };
  42.  
  43. #if    !defined(__COLORS)
  44. #define __COLORS
  45.  
  46. enum COLORS {
  47.     BLACK,            /* dark colors */
  48.     BLUE,
  49.     GREEN,
  50.     CYAN,
  51.     RED,
  52.     MAGENTA,
  53.     BROWN,
  54.     LIGHTGRAY,
  55.     DARKGRAY,        /* light colors */
  56.     LIGHTBLUE,
  57.     LIGHTGREEN,
  58.     LIGHTCYAN,
  59.     LIGHTRED,
  60.     LIGHTMAGENTA,
  61.     YELLOW,
  62.     WHITE
  63. };
  64. #endif
  65.  
  66. #define BLINK        128    /* blink bit */
  67.  
  68. extern     int _Cdecl directvideo;
  69.  
  70. #ifdef __cplusplus
  71. extern "C" {
  72. #endif
  73. void      _Cdecl clreol        (void);
  74. void      _Cdecl clrscr        (void);
  75. void      _Cdecl delline        (void);
  76. int     _Cdecl gettext        (int __left, int __top, int __right, int __bottom,
  77.                  void *__destin);
  78. void     _Cdecl gettextinfo    (struct text_info *__r);
  79. void      _Cdecl gotoxy        (int __x, int __y);
  80. void     _Cdecl highvideo    (void);
  81. void      _Cdecl insline        (void);
  82. void     _Cdecl lowvideo    (void);
  83. int     _Cdecl movetext    (int __left, int __top, int __right, int __bottom,
  84.                  int __destleft, int __desttop);
  85. void     _Cdecl normvideo    (void);
  86. int     _Cdecl puttext        (int __left, int __top, int __right, int __bottom,
  87.                  void *__source);
  88. void     _Cdecl textattr    (int __newattr);
  89. void      _Cdecl textbackground    (int __newcolor);
  90. void      _Cdecl textcolor    (int __newcolor);
  91. void      _Cdecl textmode    (int __newmode);
  92. int       _Cdecl wherex        (void);
  93. int       _Cdecl wherey        (void);
  94. void      _Cdecl window        (int __left, int __top, int __right, int __bottom);
  95.  
  96. void     _Cdecl _setcursortype    (int __cur_t);
  97. char    *_Cdecl cgets        (char *__str);
  98. int       _Cdecl cprintf        (const char *__format, ...);
  99. int     _Cdecl cputs        (const char *__str);
  100. int     _Cdecl cscanf        (const char *__format, ...);
  101. int     _Cdecl getch        (void);
  102. int     _Cdecl getche        (void);
  103. char    *_Cdecl getpass        (const char *__prompt);
  104. int     _Cdecl kbhit        (void);
  105. int     _Cdecl putch        (int __c);
  106. int     _Cdecl ungetch        (int __ch);
  107. #ifdef __cplusplus
  108. }
  109. #endif
  110. #endif
  111.