home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Internet Tools 1993 July / Internet Tools.iso / RockRidge / mail / pine / pine3.07 / pico / edef.h < prev    next >
Encoding:
C/C++ Source or Header  |  1992-06-07  |  7.0 KB  |  155 lines

  1. /*
  2.  * Program:    Global definitions and initializations
  3.  *
  4.  * Modifier:    Michael Seibel
  5.  *        Networks and Distributed Computing
  6.  *        Computing & Communications
  7.  *        University of Washington
  8.  *        Administration Building, AG-44
  9.  *        Seattle, WA  98195
  10.  *        Internet: mikes@cac.washington.edu
  11.  *
  12.  * Date:    14 Jan 90
  13.  * Last Edited:    9 Jan 1991
  14.  *
  15.  * Copyright 1991 by the University of Washington
  16.  *
  17.  *  Permission to use, copy, modify, and distribute this software and its
  18.  * documentation for any purpose and without fee is hereby granted, provided
  19.  * that the above copyright notice appears in all copies and that both the
  20.  * above copyright notice and this permission notice appear in supporting
  21.  * documentation, and that the name of the University of Washington not be
  22.  * used in advertising or publicity pertaining to distribution of the software
  23.  * without specific, written prior permission.  This software is made
  24.  * available "as is", and
  25.  * THE UNIVERSITY OF WASHINGTON DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED,
  26.  * WITH REGARD TO THIS SOFTWARE, INCLUDING WITHOUT LIMITATION ALL IMPLIED
  27.  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, AND IN
  28.  * NO EVENT SHALL THE UNIVERSITY OF WASHINGTON BE LIABLE FOR ANY SPECIAL,
  29.  * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
  30.  * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, TORT
  31.  * (INCLUDING NEGLIGENCE) OR STRICT LIABILITY, ARISING OUT OF OR IN CONNECTION
  32.  * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  33.  *
  34.  */
  35.  
  36. /*    EDEF:        Global variable definitions for
  37.             MicroEMACS 3.2
  38.  
  39.             written by Dave G. Conroy
  40.             modified by Steve Wilhite, George Jones
  41.             greatly modified by Daniel Lawrence
  42. */
  43.  
  44. #ifndef    EDEF_H
  45. #define    EDEF_H
  46.  
  47. #ifdef    maindef
  48.  
  49. /* for MAIN.C */
  50.  
  51. /* initialized global definitions */
  52.  
  53. int     fillcol = 72;                   /* Current fill column          */
  54. short   kbdm[NKBDM] = {CTLX|')'};       /* Macro                        */
  55. char    pat[NPAT];                      /* Search pattern        */
  56. char    rpat[NPAT];            /* replacement pattern        */
  57. char    sarg[NSTRING] = "";        /* string argument for line exec*/
  58. int    eolexist = TRUE;        /* does clear to EOL exist    */
  59. int    optimize = FALSE;        /* optimize flag(cf line speed)    */
  60. int    scrollexist = TRUE;        /* does insert line exist    */
  61. int    inschar = TRUE;            /* does insert character exist    */
  62. int    delchar = TRUE;            /* does delete character exist    */
  63. int     sgarbk = TRUE;                  /* TRUE if keyhelp garbaged     */
  64. char    s[16384];            /* global temporary string    */
  65. int     mline_open = FALSE;             /* TRUE if message line is open */
  66. int    ComposerTopLine = 2;        /* TRUE if message line is open */
  67. int    ComposerEditing = FALSE;    /* TRUE if message line is open */
  68. int    revexist = FALSE;        /* does reverse video exist?    */
  69. char    *modename[] = {            /* name of modes        */
  70.     "WRAP", "CMODE", "SPELL", "EXACT", "VIEW", "OVER"};
  71. char    modecode[] = "WCSEVO";        /* letters to represent modes    */
  72. int    gmode = MDWRAP;            /* global editor mode        */
  73. int     sgarbf  = TRUE;                 /* TRUE if screen is garbage    */
  74. int     mpresf  = FALSE;                /* TRUE if message in last line */
  75. int    clexec    = FALSE;        /* command line execution flag    */
  76.  
  77. /* uninitialized global definitions */
  78. int     currow;                 /* Cursor row                   */
  79. int     curcol;                 /* Cursor column                */
  80. int     thisflag;               /* Flags, this command          */
  81. int     lastflag;               /* Flags, last command          */
  82. int     curgoal;                /* Goal for C-P, C-N            */
  83. WINDOW  *curwp;                 /* Current window               */
  84. BUFFER  *curbp;                 /* Current buffer               */
  85. WINDOW  *wheadp;                /* Head of list of windows      */
  86. BUFFER  *bheadp;                /* Head of list of buffers      */
  87. BUFFER  *blistp;                /* Buffer for C-X C-B           */
  88. short   *kbdmip;                /* Input pointer for above      */
  89. short   *kbdmop;                /* Output pointer for above     */
  90.  
  91. BUFFER  *bfind();               /* Lookup a buffer by name      */
  92. WINDOW  *wpopup();              /* Pop up window creation       */
  93. LINE    *lalloc();              /* Allocate a line              */
  94.  
  95. #else
  96.  
  97. /* for all the other .C files */
  98.  
  99. /* initialized global external declarations */
  100.  
  101. extern  int     fillcol;                /* Fill column                  */
  102. extern  short   kbdm[];                 /* Holds kayboard macro data    */
  103. extern  char    pat[];                  /* Search pattern               */
  104. extern    char    rpat[];            /* Replacement pattern        */
  105. extern    char    sarg[];            /* string argument for line exec*/
  106. extern    int    eolexist;        /* does clear to EOL exist?    */
  107. extern    int    optimize;        /* optimize flag(cf line speed)    */
  108. extern    int    scrollexist;        /* does insert line exist    */
  109. extern    int    inschar;        /* does insert character exist    */
  110. extern    int    delchar;        /* does delete character exist    */
  111. extern  int     sgarbk;
  112. extern  char    s[];            /* global temporary string    */
  113. extern  int     mline_open;             /* Message line is open         */
  114. extern    int    ComposerTopLine;    /* TRUE if message line is open */
  115. extern    int    ComposerEditing;    /* TRUE if message line is open */
  116. extern    int    timeout;        /* how long we wait in GetKey    */
  117. extern    int    revexist;        /* does reverse video exist?    */
  118. extern    char *modename[];        /* text names of modes        */
  119. extern    char    modecode[];        /* letters to represent modes    */
  120. extern    KEYTAB keytab[];        /* key bind to functions table    */
  121. extern    KEYTAB pkeytab[];        /* pico's function table    */
  122. extern    NBIND names[];            /* name to function table    */
  123. extern    int    gmode;            /* global editor mode        */
  124. extern  int     sgarbf;                 /* State of screen unknown      */
  125. extern  int     mpresf;                 /* Stuff in message line        */
  126. extern    int    clexec;            /* command line execution flag    */
  127.  
  128. /* initialized global external declarations */
  129. extern  int     currow;                 /* Cursor row                   */
  130. extern  int     curcol;                 /* Cursor column                */
  131. extern  int     thisflag;               /* Flags, this command          */
  132. extern  int     lastflag;               /* Flags, last command          */
  133. extern  int     curgoal;                /* Goal for C-P, C-N            */
  134. extern  WINDOW  *curwp;                 /* Current window               */
  135. extern  BUFFER  *curbp;                 /* Current buffer               */
  136. extern  WINDOW  *wheadp;                /* Head of list of windows      */
  137. extern  BUFFER  *bheadp;                /* Head of list of buffers      */
  138. extern  BUFFER  *blistp;                /* Buffer for C-X C-B           */
  139. extern  short   *kbdmip;                /* Input pointer for above      */
  140. extern  short   *kbdmop;                /* Output pointer for above     */
  141.  
  142. extern  BUFFER  *bfind();               /* Lookup a buffer by name      */
  143. extern  WINDOW  *wpopup();              /* Pop up window creation       */
  144. extern  LINE    *lalloc();              /* Allocate a line              */
  145.  
  146. #endif
  147.  
  148. /* terminal table defined only in TERM.C */
  149.  
  150. #ifndef    termdef
  151. extern  TERM    term;                   /* Terminal information.        */
  152. #endif
  153.  
  154. #endif    /* EDEF_H */
  155.