home *** CD-ROM | disk | FTP | other *** search
/ ARM Club 1 / ARM_CLUB_CD.iso / contents / apps / clib / progs / haswinlib / c / defns < prev    next >
Encoding:
Text File  |  1991-02-04  |  6.8 KB  |  138 lines

  1. /* > $.CLIB.C.defns
  2.  *
  3.  *      HASWIN Graphics Library
  4.  *     =========================
  5.  *
  6.  *      Copyright (C) H.A.Shaw 1990.
  7.  *              Howard A. Shaw.
  8.  *              The Unit for Space Sciences,
  9.  *              Room 165,
  10.  *              Physics Building,
  11.  *              University of Kent at Canterbury.
  12.  *              Canterbury.
  13.  *              Kent.  CT2 7NJ
  14.  *      You may use and distribute this code freely, however please leave
  15.  *      it alone.  If you find bugs (and there will be many) please contact
  16.  *      me and the master source can be modified.  If you keep me informed
  17.  *      of who you give copies of this to then I can get release upgrades
  18.  *      to them.
  19.  *
  20.  *     standard definitions file.
  21.  */
  22. #include "includes.h"
  23.  
  24. /*
  25.  *     internal static global data for temp. use.  Not safe across
  26.  *     functions calls between components of the library except error.
  27.  *     routines and message display routines
  28.  */
  29. char    haswintemp[256];
  30.  
  31. /*
  32.  *     internal static global data.
  33.  */
  34.  
  35. /* internal data list gloabals */
  36. window  *haswin_topwindow=0;         /* pointer to list of windows         */
  37. icon    *haswin_baricons=0;          /* pointer to icons on icon bar       */
  38. int     haswin_activewindowmax = 0;  /* number of items in activewindow[]  */
  39. int     haswin_activewindow[HASWIN_ACTIVEMAX];
  40.                                      /* list of active windows handles     */
  41.                                      /* ie: those that the library will    */
  42.                                      /* respond to.  The last item in the  */
  43.                                      /* list is handle 0.  The iconbars    */
  44.                                      /* cannot be in the list.             */
  45. /* general things we have to remember */
  46. int     haswin_version=HASWIN_UNKNOWN;
  47.                                      /* WIMP version number                */
  48. int     haswin_flags=0;              /* Global WIMP flags                  */
  49. char    *haswin_commline=0;          /* pointer to command line tail       */
  50. int     *haswin_starttime=0;         /* pointer to program start real-time */
  51.  
  52. /* sprite control variables */
  53. int     *haswin_usersprites=0;       /* user sprite buffer                 */
  54. int     *haswin_haswinsprites=0;     /* haswin internal sprite buffer      */
  55.  
  56. /* template control globals */
  57. int     haswin_templatefsize=0;      /* size of template file              */
  58. char    *haswin_templatewspace=0;    /* WIMP template indirected data area */
  59. char    *haswin_templateptr=0;       /* current place in 'templatewspace'  */
  60. char    *haswin_templateend=0;       /* end of 'templatewspace'            */
  61. char    haswin_fontarray[256];       /* font reference count array         */
  62.  
  63. /* menu variables */
  64. menu    haswin_menu;                 /* current menu (actual==0 if none)   */
  65.  
  66. /* window dragging globals */
  67. window  *haswin_dragwindow=0;        /* window drag started from           */
  68. icon    *haswin_dragicon=0;          /* icon drag started from             */
  69. pointer haswin_dragmouse;            /* pointer state at drag start        */
  70.  
  71. /* automatic file handling globals - loading files */
  72. int     (*haswin_loadfileroutine)(char *, buffer *)=0;
  73.                                      /* user load file routine             */
  74. char    haswin_defaultloadfile[256] = "";
  75.                                      /* default load filename              */
  76. window  *haswin_loadingwindow=0;     /* window to ask loading in.          */
  77. icon    *haswin_loadicon=0;          /* icon for filetype picture.         */
  78. icon    *haswin_loadiconname=0;      /* icon for filename string.          */
  79. icon    *haswin_loadicontype=0;      /* icon for filetype string.          */
  80. int     haswin_loadfiletype=0;       /* filetype of load file              */
  81.  
  82. /* automatic file handling globals - saving files */
  83. int     (*haswin_savefileroutine)(char *, buffer *)=0;
  84.                                      /* user save file routine             */
  85. char    haswin_defaultsavefile[256] = "";
  86.                                      /* default save filename              */
  87. window  *haswin_saveingwindow=0;     /* window to ask saving in.           */
  88. icon    *haswin_saveicon=0;          /* icon for filetype picture.         */
  89. icon    *haswin_saveiconname=0;      /* icon for filename string.          */
  90. icon    *haswin_saveicontype=0;      /* icon for filetype string.          */
  91. int     haswin_savefiletype=0;       /* filetype of save file              */
  92. int     haswin_fileoptions=0;        /* global file control options        */
  93.  
  94. /* automatic file handling globals - auto loading of files */
  95. int     (*haswin_autoloadroutine)(char *, buffer *)=0;
  96.                                      /* user autoload routine              */
  97. int     haswin_autoloadtype=0;       /* filetype of autoload file          */
  98.  
  99. /* automatic file handling globals - ram transfer of files */
  100. int     (*haswin_ramtxroutine)(void *, int, int, buffer *)=0;
  101.                                      /* user RAM transmit routine          */
  102. void    *haswin_ramtxbuffer=0;       /* address of TX transfer buffer      */
  103. int     haswin_ramtxlength=0;        /* length of haswin_ramtxbuffer       */
  104. int     haswin_ramtxbytes=0;         /* number of bytes transferred        */
  105. int     (*haswin_ramrxroutine)(void *, int, int, buffer *)=0;
  106.                                      /* user RAM receive routine           */
  107. void    *haswin_ramrxbuffer=0;       /* address of RX transfer buffer      */
  108. int     haswin_ramrxlength=0;        /* length of haswin_ramrxbuffer       */
  109. int     haswin_ramrxbytes=0;         /* number of bytes transferred        */
  110.  
  111. /* task variables */
  112. int     haswin_taskid = 0;           /* this task id number                */
  113. char    haswin_taskname[TASK_MAXNAME];
  114.                                      /* this task name                     */
  115. /* task name searching variables */
  116. char    *haswin_tasknameis;          /* pointer to taskname                */
  117.  
  118. /* task quit control variables */
  119. window  *haswin_quitwin=0;           /* window quit is prompted in         */
  120. int     haswin_quitfrom=0;           /* id of task quit request came from  */
  121. int     (*haswin_exittrap)(int) = 0;
  122.                                      /* routine to call on clean exit      */
  123.  
  124. /* memory management variables */
  125. int     haswin_programtop=0;         /* top of program memory              */
  126.  
  127. /* special variable to store sprite information for switching VDU driver
  128.    output to a sprite.  This is used to put window contents in a sprite.   */
  129. spritejob  haswin_spritejob = { 0, 0, 0, 0, 0, 0, 0};
  130.  
  131. /* special variable to store printer driver information for switching VDU
  132.  driver output to a printer driver job.  This is used to print window
  133.  contents.                                                                 */
  134.  
  135. int     (*haswin_printfileroutine)(char *, buffer *)=0;
  136.                                      /* user print file routine            */
  137.  
  138.