home *** CD-ROM | disk | FTP | other *** search
/ The C Users' Group Library 1994 August / wc-cdrom-cusersgrouplibrary-1994-08.iso / vol_200 / 214_01 / xshow.h < prev    next >
Text File  |  1979-12-31  |  3KB  |  95 lines

  1. /* XSHOW.H   VERS:- 01.00  DATE:- 09/26/86  TIME:- 09:37:45 PM */
  2. /*
  3. Description:
  4.  
  5. Header file for XSHOWR.C and XSHOWFNS.C
  6.  
  7. By J.A. Rupley, Tucson, Arizona
  8. Coded for BDS C compiler, version 1.50a
  9. */
  10.  
  11. #define NSECS 16    /* Number of SECSIZ sectors transferred per read */
  12. #define BUFSIZ (NSECS * SECSIZ * 2 + 3) 
  13. #define PAUSE_COUNT 2    /* seconds to wait for input */
  14. #define TAB_SPACES 8    /* number of spaces in expansion of tab character */
  15. #define TLENGTH 23    /* (number of lines on screen) - 1 */
  16. #define TWIDTH 79    /* (number of characters on screen line) - 1 */
  17.  
  18. #define BS 8
  19. #define TAB 9
  20. #define LF 10
  21. #define FF 12
  22. #define CR 13
  23. #define ESC 27
  24. #define SPACE 32
  25. #define CNTRL_C 'C' - 0x40
  26. #define CNTRL_S 'S' - 0x40
  27.  
  28.  
  29. #define    CONST 2
  30. #define CONIN 3
  31. #define CONOUT 4
  32. #define    CHAR_AVAILABLE 0xff
  33.  
  34. #define BIOS_OUTPUT(x)    bios(CONOUT, x)
  35. #define BIOS_INPUT    bios(CONIN, 0)
  36. #define KBHIT        (bios(CONST, 0) == CHAR_AVAILABLE)
  37. #define CLEAR        {bios(CONOUT, ESC); bios(CONOUT, '*');}
  38. #define HOME        {bios(CONOUT, '^' - 0x40);}
  39. #define INSERT_LINE    {bios(CONOUT, ESC); bios(CONOUT, 'E');}
  40. #define DELETE_LINE    {bios(CONOUT, ESC); bios(CONOUT, 'R');}
  41. #define ERA_EOP        {bios(CONOUT, ESC); bios(CONOUT, 'Y');}
  42. #define ERA_EOL        {bios(CONOUT, ESC); bios(CONOUT, 'T');}
  43. #define CUR_TOP        {bios(CONOUT, ESC); bios(CONOUT, '='); bios(CONOUT, SPACE); bios(CONOUT, SPACE);}
  44. #define CUR_BOTTOM    {bios(CONOUT, ESC); bios(CONOUT, '='); bios(CONOUT, '7'); bios(CONOUT, SPACE);}
  45. #define CUR_UP        {bios(CONOUT, 'K' - 0x40);}
  46. #define REV_OFF        {bios(CONOUT, ESC); bios(CONOUT, '(');}
  47. #define REV_ON        {bios(CONOUT, ESC); bios(CONOUT, ')');}
  48.  
  49. #define FOUND 0x80
  50. #define NOTFOUND 0x81
  51. #define MATCH 0x82
  52. #define NOTMATCH 0x83
  53. #define SKIPANY 0x86
  54. #define SKIPONE 0x87
  55. #define IGNOREONE 0x1c
  56. #define LINEEND 0x1d
  57. #define LINESTART 0x7f
  58. #define ANYALPHA 0x1e
  59. #define ANYNUMBER 0x1f
  60. #define SRCH_CHAR 1
  61. #define FIRST 2
  62. #define NEXT 3
  63.  
  64.  
  65. int x, t, i, j;
  66. int tabcount;
  67. int start_flag, end_flag;
  68. int top_flag, last_flag, old_flag;
  69. int disp_sec, last_sec, old_sec;
  70. int end_sec;
  71. int fd;
  72. int c1, c2, n1;
  73. int old_c1, old_c2, old_n1;
  74. int use_last;
  75. int sleep_base;
  76. int upper_case;
  77. int f_sec, n_sec;
  78. int srch_out;
  79.  
  80. char *p_srch1, *p_srch2;
  81. char *f_pntr, *n_pntr;
  82. char *start_addr, *mid_addr, *end_addr;
  83. char *disp_pntr, *last_pntr, *old_pntr;
  84. char buffer[BUFSIZ];
  85. char file[30];
  86. char pattern[80];
  87. char input_pattern[80];
  88. char old_pattern[80];
  89. char string1[10];
  90. char jbuf[JBUFSIZE];
  91. char jbufsrch[BUFSIZ];
  92.  
  93.  
  94.  
  95.