home *** CD-ROM | disk | FTP | other *** search
/ The Arcade BBS / arcadebbs.zip / arcadebbs / bbstools / MODS / COMMON40.ZIP / COMMON.H < prev    next >
Encoding:
C/C++ Source or Header  |  1995-06-04  |  2.0 KB  |  107 lines

  1. #define COMMON
  2. #define COMMON_VER 4.0
  3.  
  4. #include <conio.h>
  5.  
  6.  
  7.  
  8. struct side_menu_colors
  9. {
  10.   unsigned normal_highlight;
  11.   unsigned normal_menu_item;
  12.   unsigned current_highlight;
  13.   unsigned current_menu_item;
  14. };
  15.  
  16.  
  17.  
  18. struct search_record
  19. {
  20.   char filemask[13];
  21.  
  22.   long nscandate;
  23.  
  24.   char search[81];
  25.  
  26.   int alldirs;
  27.   int search_extended;
  28. };
  29.  
  30.  
  31. typedef struct
  32. {
  33.   char name[31];          /* verify against a user */
  34.  
  35.   unsigned long status;
  36.  
  37.   unsigned long lp_options;
  38.   unsigned char lp_colors[32];
  39.  
  40.   char junk[129];
  41. } asylum_config;
  42.  
  43.  
  44.  
  45.  
  46.  
  47. /* INI STUFF */
  48.  
  49. #define AMOUNT_BOOLS (4)
  50.  
  51.  
  52. /* longest ini line to be read in */
  53. #define MAX_LINE_WIDTH (128)
  54.  
  55. #define INI_COL_WIDTH "-22"
  56. #define INI_COMMENT_POS (40)
  57.  
  58. #define INI_FLAGS_NONE                   0x00000000
  59. #define INI_FLAGS_SEE_THROUGH_COMMENTS   0x00000001
  60. #define INI_FLAGS_SEE_THROUGH_ON_READ    0x00000002
  61. #define INI_FLAGS_READ_ONLY              0x00000004
  62. #define INI_FLAGS_WRITE_IF_NO_READ       0x00000008
  63.  
  64. #define IF_NONE  INI_FLAGS_NONE
  65. #define IF_STC   INI_FLAGS_SEE_THROUGH_COMMENTS
  66. #define IF_STCR  INI_FLAGS_SEE_THROUGH_ON_READ
  67. #define IF_OREAD INI_FLAGS_READ_ONLY
  68. #define IF_WINR  INI_FLAGS_WRITE_IF_NO_READ
  69.  
  70.  
  71. #ifdef __OS2__
  72. #define REALLOC realloc
  73. #else
  74. #define REALLOC farrealloc
  75. #endif
  76.  
  77. #define MALLOC  malloca
  78. #define FREE    bbsfree
  79.  
  80. #define FOPEN  fsh_open
  81. #define FCLOSE fsh_close
  82.  
  83.  
  84. extern char bool_strings[AMOUNT_BOOLS][2][8];
  85.  
  86.  
  87.  
  88. typedef struct
  89. {
  90.   char fname[131];
  91.   char area[31];
  92.   char **ini_rows;     /* a pointer to a row of pointers */
  93.   unsigned amount_rows, rows_allocated;
  94.  
  95.  
  96.   int amount_patt_idents;  /* used for finding duplicate identifiers   */
  97.   int *patt_idents;        /* allocated in get_idents_positions, freed */
  98.                            /* by function close_ini                    */
  99.  
  100.   int modified;
  101.   unsigned long flags;
  102.   FILE *fp;                /* ini file pointer */
  103. }ini_record;
  104.  
  105.  
  106. /* end INI stuff */
  107.