home *** CD-ROM | disk | FTP | other *** search
/ Delphi 5 for Professionals / DELPHI5.iso / AddOns / Components / RealTime Graphics ActiveX / DATA.3 / Examples / CPP / QCWRT.H < prev   
Encoding:
C/C++ Source or Header  |  1997-04-11  |  26.3 KB  |  555 lines

  1. /*************************************************************************/
  2. /*                                                                       */
  3. /*     Copyright (C) QUINN-CURTIS, Inc, 1994 - 1996                      */
  4. /*                                                                       */
  5. /*************************************************************************/
  6. /**                                                                      */
  7. /**   Filename :   qcwrt.h                                               */
  8. /**   Author   :   MS                                                    */
  9. /**   Revision :   2.52                                                  */
  10. /**   Date     :   March 7, 1996                                         */
  11. /**                                                                      */
  12. /**   Product  :   Windows Real Time Tools                               */
  13. /**   Description: QC Windows Real Time Tools Definitions and            */
  14. /**                Function Prototypes                                   */
  15. /**                                                                      */
  16. /*************************************************************************/
  17.  
  18. #ifndef  _QCRTH
  19. #define  _QCRTH        1
  20.  
  21. #ifdef __cplusplus
  22. extern  "C" {
  23. #endif
  24.  
  25. #define AXU_SEC     0       // time units codes for time axes
  26. #define AXU_MIN     1
  27. #define AXU_HOUR    2
  28.  
  29. // staircase style
  30.  
  31. #define NO_STEP    0
  32. #define STEP_START 1
  33. #define STEP_END   2
  34.  
  35.               // alarm types 
  36. #define ALM_OK    0
  37. #define ALM_SETP  0
  38. #define ALM_HIGH  1
  39. #define ALM_LOW   2
  40. #define ALM_HH    3
  41. #define ALM_LL    4
  42. #define ALM_RATE  5
  43. #define ALM_DEV   6
  44. #define ALM_FAIL  7
  45.  
  46. // meter subtypes
  47. #define GOD_SUBT_NEEDLE   0       /* needle meter  */
  48. #define GOD_SUBT_PIE      1       /* pie meter  */
  49. #define GOD_SUBT_ARC      2       /* arc meter  */
  50.  
  51. /**********************************************************************/
  52. /* Direction definitions                                              */
  53. /**********************************************************************/
  54.  
  55. #define DYN_LEFT    0       // scroll or move from right to left
  56. #define DYN_RIGHT   1 
  57. #define DYN_UP      2 
  58. #define DYN_DOWN    3 
  59.  
  60. /**************************************************************************/
  61. /* Meter definitions*******************************************************/
  62. /**************************************************************************/
  63. // needle types
  64.  
  65. #define NEEDLE_LINE       0  // simple line
  66. #define NEEDLE_THICK      1  // thick lline with circle
  67. #define NEEDLE_SHORTF     2  // triangle with base at center - filled
  68. #define NEEDLE_SHORTH     3  // triangle with base at center - hollow
  69. #define NEEDLE_LONGF      4  // triangle with back plane - filled
  70. #define NEEDLE_LONGH      5  // triangle with back plane - hollow
  71.  
  72. #define MET_NOBORDER     0
  73. #define MET_RECT         1
  74. #define MET_CIRC         2
  75. #define MET_RD_RECT      3
  76.  
  77. /**************************************************************************/
  78. /* Dynamic label types ****************************************************/
  79. /**************************************************************************/
  80. #define  DLB_NUMERIC   0
  81. #define  DLB_HMS       1    // time format, hh:mm:ss. Prec ignored
  82. #define  DLB_HM        2    // time format, hh:mm
  83. #define  DLB_MS        4 
  84.  
  85. // CONTROL STYLES
  86.          // logic
  87. #define  BC_STYLE_PUSH       0       // like standard push button
  88. #define  BC_STYLE_ONOFF      1       // 2 state
  89. #define  BC_STYLE_XOR        2       // radio button logic
  90. #define  BC_STYLE_PASSIVE    3       // cannot be pressed
  91.          // appearance
  92. #define  BC_LOOK_LOW    0            // standard pushbutton look
  93. #define  BC_LOOK_HIGH   1            // "deep" pushbutton
  94. #define  BC_LOOK_RADIO  2            // standard radio button
  95. #define  BC_LOOK_CHECK  3            // "deep" check box
  96. #define  BC_LOOK_LED    4            // LED
  97.  
  98.  /**************************************************************************/
  99. /* Algorithm Definitions **************************************************/
  100. /**************************************************************************/
  101. #define  MAX_CBLOCKS 128
  102.  
  103. #define ALG_NONE    0
  104. #define ALG_PID     1
  105.  
  106. // PID bargraph
  107. // order of handles: 
  108. #define PIDH_TITLE   0           // graph title  
  109. #define PIDH_LEFTYAX 1           // left (measurement) Y axis
  110. #define PIDH_LEFTLAB 2           // left (measurement) Y axis labels
  111. #define PIDH_LEFTTIT 3           // left (measurement) Y axis title
  112. #define PIDH_BARINP  4           // input (meas and setp) bargraph
  113. #define PIDH_RIGHTYAX 5          // right (output) Y axis
  114. #define PIDH_RIGHTLAB 6          // right (output) Y axis labels 
  115. #define PIDH_RIGHTTIT 7          // right (output) Y axis title
  116. #define PIDH_BAROUT   8          // output bargraph
  117. #define PIDH_AM       9          // auto/manual message
  118. #define PIDH_INPTEXT 10          // live text for measurement and setpoint
  119. #define PIDH_INPTAGS 11          // tags for measurement and setpoint
  120. #define PIDH_INPALMS 12          // alarm text for measurement and setpoint
  121. #define PIDH_OUTTEXT 13          // live text for output
  122. #define PIDH_OUTTAG  14          // tag for output
  123. #define PIDH_OUTALMS 15          // alarm text for output
  124.  
  125. #define PID_NH       16   
  126.  
  127. // Auto bar objects
  128. // order of handles: 
  129. #define ABH_TITLE     0          // graph title  
  130. #define ABH_FIRSTAX   1          // left (bottom) axis
  131. #define ABH_FIRSTLAB  2          // left (bottom) axis labels
  132. #define ABH_AXTIT     3          // left (bottom) axis title
  133. #define ABH_BAR       4          // bargraph
  134. #define ABH_LASTAX    5          // right (top)  axis
  135. #define ABH_LASTLAB   6          // right (top) axis labels
  136. #define ABH_TAGS      7          // tags 
  137. #define ABH_TEXT      8          // live text 
  138. #define ABH_ALMMARKS  9          // alarm marks
  139. #define ABH_ALMTEXT  10          // alarm text 
  140.  
  141. #define AB_NH   11
  142.  
  143. // Auto scroll objects
  144. // order of handles: 
  145. #define ASH_TITLE     0          // graph title  
  146. #define ASH_XAX       1          // X axis
  147. #define ASH_XLAB      2          // X axis labels
  148. #define ASH_XTIT      3          // X axis title
  149. #define ASH_YAX       4          // Y axis
  150. #define ASH_YLAB      5          // Y axis labels
  151. #define ASH_YTIT      6          // Y axis title
  152. #define ASH_SCROLL    7          // scrolling graph
  153. #define ASH_TAGS      8          // tags 
  154. #define ASH_TEXT      9          // live text 
  155. #define ASH_ALMLINES 10          // alarm lines 
  156.  
  157. #define AS_NH   11
  158.  
  159. // Auto Text objects
  160. // order of handles: 
  161. #define ATH_TITLE     0          // graph title  
  162. #define ATH_TAGS      1          // tags 
  163. #define ATH_VALUES    2          // live text 
  164. #define ATH_ALMTEXT   3          // alarm text 
  165.  
  166. #define AT_NH   4
  167.  
  168. /**************************************************************************/
  169. /* FUNCTION PROTOTYPES ****************************************************/
  170. /**************************************************************************/
  171. /* Data functions *********************************************************/
  172. /**************************************************************************/
  173. HDATA WINAPI _export WRDefineDynDataSet (LPSTR lpTitle,
  174.     int nNumChans, LPSTR lpUnits, LPSTR lpTags, int nHistSize);
  175.  
  176. BOOL WINAPI _export WRFreeDynDataSet (HDATA hData);
  177. void WINAPI _export WRDrawScroll (PGRAPH_DEF pGrDesc, HGOBJ hDynObj);
  178. void WINAPI _export WRUpdateData (HDATA hData, LPREAL lprNewValues, 
  179.     PGRAPH_DEF pGrDesc);
  180. void WINAPI _export WRUpdateBlockData (HDATA hData, LPREAL lprNewValues, 
  181.     int nSamp, PGRAPH_DEF pGrDesc);
  182. void WINAPI _export WRGetLastData (HDATA hData, LPREAL lprNewValues,
  183.     LPREAL lprPrevValues);
  184. int WINAPI _export WRGetHistData (HDATA hData, int nChan, 
  185.     HPREAL lprUser, int nFirst, int nNumSamples);
  186. void WINAPI _export WRUpdateBinaryData (HDATA hData, UINT wBinVal,
  187.     PGRAPH_DEF pGrDesc);
  188. UINT WINAPI _export WRGetBinData (HDATA hData);
  189. void WINAPI _export WRSetBit (HDATA hData, int nChanNum, 
  190.         BOOL bOn, PGRAPH_DEF pGrDesc);
  191. void WINAPI _export WRSetBitExclusive (HDATA hData, int nChanNum, 
  192.         PGRAPH_DEF pGrDesc);
  193. BOOL WINAPI _export WRGetMinMaxValues (HDATA hData, int nChan, 
  194.     LPREAL lprMin, LPREAL lprMax);
  195. BOOL WINAPI _export WRReconnectDynDataSet (PGRAPH_DEF pGrDesc, HGOBJ hObj,
  196.     HDATA hData);
  197. void WINAPI _export WRResetHistBuffer (HDATA hData);
  198.  
  199. /**************************************************************************/
  200. /* Dynamic graphical objects **********************************************/
  201. /**************************************************************************/
  202. HGOBJ WINAPI _export WRSetScrollGraph (PGRAPH_DEF pGrDesc,
  203.     HDATA hData, realtype rSampleInt, realtype rRelResetInt, int nDir,    
  204.     int nStep, LPINT lpLineStyle, LPINT lpLineWidth, LPINT lpLineColor);
  205.  
  206. ///////////////NEW OBJECT
  207. HGOBJ WINAPI _export WRSetVarScroll (PGRAPH_DEF pGrDesc,
  208.     HDATA hData, realtype rRelResetInt, int nDir,    
  209.     int nStep, LPINT lpLineStyle, LPINT lpLineWidth, LPINT lpLineColor);
  210.  
  211. HGOBJ WINAPI _export WRSetAlarmLines (PGRAPH_DEF pGrDesc, HDATA hData,
  212.     int nUpdateSec, int nDir, BOOL FAR *lpbFlags, 
  213.     LPINT lpLineStyle, LPINT lpLineWidth, LPINT lpLineColor);
  214.  
  215. HGOBJ WINAPI _export WRSetAlarmMarks (PGRAPH_DEF pGrDesc, HDATA hData,
  216.     HGOBJ hAxis, int nPos, int nMarkSize, BOOL FAR *lpbFlags, 
  217.     int nLineWidth, LPINT lpLineColor, LPSTR lpNames);
  218.  
  219. HGOBJ WINAPI _export WRSetAlarmText (PGRAPH_DEF pGrDesc,
  220.      HDATA hData, int nChan, realtype  rX1, realtype rY1, realtype rX2, 
  221.      realtype rY2, int nBorderColor, int nBorderWidth, 
  222.      int nBackColor, LPSTR lpNormMes, LPINT lpTextColor, UINT wAlign, int nLayout);
  223.  
  224. HGOBJ WINAPI _export WRDynGrid (PGRAPH_DEF pGrDesc, HGOBJ hAxis,
  225.     int nGridType, int nUpdateSec);
  226.  
  227. HGOBJ WINAPI _export WRSetXYGraph (PGRAPH_DEF pGrDesc, HDATA hData,
  228.     int nNumPoints, 
  229.     LPINT lpLineStyle, LPINT lpLineWidth, LPINT lpLineColor);
  230. HGOBJ WINAPI _export WRSetStackedGraph (PGRAPH_DEF pGrDesc, HDATA hData,
  231.     realtype rSampleInt, realtype rRelResetInt, int nDir, int nStep, 
  232.     realtype rRelSize,
  233.     LPINT lpLineStyle, LPINT lpLineWidth, LPINT lpLineColor);
  234.  
  235. HGOBJ WINAPI _export WRSetLogicGraph (PGRAPH_DEF pGrDesc, HDATA hData,
  236.     realtype rSampleInt, realtype rRelResetInt, int nDir, int nNumChannels,
  237.     realtype rRelSize, LPINT lpLineStyle, LPINT lpLineWidth, 
  238.     LPINT lpLineColor);
  239.  
  240. HGOBJ WINAPI _export WRSetDynText (PGRAPH_DEF pGrDesc,
  241.      HDATA hData, int nChan, realtype rX1, realtype rY1,
  242.      realtype  rX2, realtype rY2, int nBorderColor,
  243.      int nBorderWidth, LPINT lpTextColor, int  nBackColor,  
  244.      int nLayout, int nChar, int nPrec, HGOBJ hDynObj, int n3D);
  245.  
  246. HGOBJ WINAPI _export WRLogicTags (PGRAPH_DEF pGrDesc,
  247.      int nBorderColor, int nBorderWidth, int nTextColor, 
  248.      int nBackColor, HGLOBAL hStr, HGOBJ hLogObj);
  249.  
  250. HGOBJ WINAPI _export WRLogicTagsPtr (PGRAPH_DEF pGrDesc,
  251.      int nBorderColor, int nBorderWidth, int nTextColor, 
  252.      int nBackColor, LPSTR lpStr, HGOBJ hLogObj);
  253.  
  254. BOOL WINAPI _export WRAutoRescale (PGRAPH_DEF pGrDesc, HGOBJ hAxis,
  255.     HDATA hData, int nChan, LPREAL lprMin, LPREAL lprMax, BOOL bUpdate);
  256. HGOBJ WINAPI _export WRDrawTimeAxis (PGRAPH_DEF pGrDesc, 
  257.     realtype rTickSpace, int nSmallTicks,
  258.     int nTickPos, int nDir,  int nTimeUnits);
  259. HGOBJ WINAPI _export WRLabelTimeAxis (PGRAPH_DEF pGrDesc, 
  260.     HGOBJ hAxis, int nLabelPos, int nFormat,
  261.     int nPrec, int nStartHour, int nStartMin, int nStartSec,
  262.     realtype rStartNum, int nLast, LPSTR lpTextLast);
  263. HGOBJ WINAPI _export WRDynLegend (PGRAPH_DEF pGrDesc, 
  264.      realtype  rX1, realtype  rY1, realtype  rX2, realtype  rY2,
  265.      int  nBorderColor, int nBorderWidth, int nTextColor,  int  nBackColor, 
  266.      int nLayout, HGLOBAL hStr, HGOBJ hDynObj, BOOL bSymbols);
  267. HGOBJ WINAPI _export WRDynLegendPtr (PGRAPH_DEF pGrDesc, 
  268.      realtype  rX1, realtype  rY1, realtype  rX2, realtype  rY2,
  269.      int  nBorderColor, int nBorderWidth, int nTextColor,  int  nBackColor, 
  270.      int nLayout, LPSTR lpStr, HGOBJ hDynObj, BOOL bSymbols);
  271. HGOBJ WINAPI _export WRSetScrollBargraph (PGRAPH_DEF pGrDesc,
  272.     HDATA hData, int nChan, realtype rSampleInt, realtype rRelResetInt, int nDir,
  273.     realtype rWidth, COLORREF rgbBarColor,
  274.     int nBorderColor);
  275. BOOL WINAPI _export WRResetScroll (PGRAPH_DEF pGrDesc, HGOBJ hScroll);
  276.  
  277. HGOBJ WINAPI _export WRSetSweepGraph (PGRAPH_DEF pGrDesc, HDATA hData,
  278.     realtype rSampleInt, int nDir,    
  279.     int nStep, int nSweepLineColor,
  280.     LPINT lpLineStyle, LPINT lpLineWidth, LPINT lpLineColor);
  281.  
  282. HGOBJ WINAPI _export WRSetBargraph (PGRAPH_DEF pGrDesc, HDATA hData,
  283.     realtype rCenterPoint, int nDir, 
  284.     realtype rFirst, realtype rLast, realtype rWidth,
  285.     COLORREF FAR *lpBarColor, LPINT lpHatchStyle, LPINT lpBorderColor);
  286.  
  287. HGOBJ WINAPI _export WRSetAutoBargraph (PGRAPH_DEF pGrDesc,
  288.     HDATA hData, realtype rMin, realtype rMax, realtype rCenterPoint,
  289.     int nDir, int nPrec, realtype rSetp, realtype rHighAlm,
  290.     realtype rLowAlm, LPSTR lpHighAlmMes, LPSTR lpLowAlmMes,
  291.     COLORREF FAR *lpBarColor, PHGOBJ lphAutoBar);
  292.  
  293. HGOBJ WINAPI _export WRSetAutoBargraph2 (PGRAPH_DEF pGrDesc,
  294.     HDATA hData, realtype rMin, realtype rMax, realtype rCenterPoint,
  295.     int nDir, int nPrec, int nFontSize, realtype rSetp, realtype rHighAlm,
  296.     realtype rLowAlm, LPSTR lpHighAlmMes, LPSTR lpLowAlmMes,
  297.     COLORREF FAR *lpBarColor, PHGOBJ lphAutoBar);
  298.  
  299. HGOBJ WINAPI _export WRSetAutoScrollGraph (PGRAPH_DEF pGrDesc,
  300.     HDATA hData, realtype rSampleInt, realtype rRelResetInt, 
  301.     realtype rMinVal, realtype rMaxVal, realtype rXRange, 
  302.     int nType, int nPrec, realtype rSetp, realtype rHighAlm,
  303.     realtype rLowAlm, LPSTR    lpXTitle, int nPlotColor, 
  304.     LPINT lpLineColor, BOOL bText,PHGOBJ lphAutoScroll);
  305.  
  306. HGOBJ WINAPI _export WRSetAutoScrollGraph2 (PGRAPH_DEF pGrDesc,
  307.     HDATA hData, realtype rSampleInt, realtype rRelResetInt, 
  308.     realtype rMinVal, realtype rMaxVal, realtype rXRange, 
  309.     int nType, int nPrec, int nFontSize, realtype rSetp, realtype rHighAlm,
  310.     realtype rLowAlm, LPSTR    lpXTitle, int nPlotColor, 
  311.     LPINT lpLineColor, BOOL bText,PHGOBJ lphAutoScroll);
  312.  
  313. HGOBJ WINAPI _export WRSetPIDBargraph (PGRAPH_DEF pGrDesc,
  314.     HCONT hPID, realtype rCenterPointMeas,
  315.     realtype rCenterPointOut, int nPrecMeas, int nPrecOut,              
  316.     LPSTR lpNorm, LPSTR lpAuto, LPSTR lpMan, 
  317.     COLORREF FAR *lpBarColor, PHGOBJ lphPidBar);  
  318.  
  319. HGOBJ WINAPI _export WRSetPIDBargraph2 (PGRAPH_DEF pGrDesc,
  320.     HCONT hPID, realtype rCenterPointMeas,
  321.     realtype rCenterPointOut, int nPrecMeas, int nPrecOut, int nFontSize,
  322.     LPSTR lpNorm, LPSTR lpAuto, LPSTR lpMan, 
  323.     COLORREF FAR *lpBarColor, PHGOBJ lphPidBar);
  324.  
  325. HGOBJ WINAPI _export WRSetAutoText (PGRAPH_DEF pGrDesc,
  326.     HDATA hData, int nValWidth, int nPrec, LPINT lpColors,
  327.     LPSTR lpDesc, BOOL FAR *lpFlags, PHGOBJ lphAutoText);
  328.  
  329. HGOBJ WINAPI _export WRSetAutoText2 (PGRAPH_DEF pGrDesc,
  330.     HDATA hData, int nValWidth, int nPrec, int nFontSize, LPINT lpColors,
  331.     LPSTR lpDesc, BOOL FAR *lpFlags, PHGOBJ lphAutoText);
  332.  
  333. HGOBJ WINAPI _export WRSetAnnun (PGRAPH_DEF pGrDesc,
  334.     HDATA hData, int nValWidth, int nPrec, LPINT lpChanColors,
  335.     COLORREF FAR *lpRgbBackColors, COLORREF rgbBackAlmColor,
  336.     int nNumRows, int nNumColumns, BOOL FAR *lpFlags, int n3D);
  337.  
  338. HGOBJ WINAPI _export WRSetAnnun2 (PGRAPH_DEF pGrDesc,
  339.     HDATA hData, int nValWidth, int nPrec, int nFontSize, LPINT lpChanColors,
  340.     COLORREF FAR *lpRgbBackColors, COLORREF rgbBackAlmColor,
  341.     int nNumRows, int nNumColumns, BOOL FAR *lpFlags, int n3D);
  342. void WINAPI _export WRSetMeterAlarmStartStop(PGRAPH_DEF pGrDesc,
  343.      HGOBJ  hMeter, realtype  rStart, 
  344.      realtype  rStop);           
  345.  
  346. HGOBJ WINAPI _export WRSetMeter (PGRAPH_DEF pGrDesc,
  347.      HDATA hData, int  nChan, realtype  rMin, realtype rMax,    
  348.      realtype  rXCenter, realtype rYCenter,   
  349.      realtype  rDiam, int nStartAngle,
  350.      int     nEndAngle, int nNeedleType, LPINT lpNeedleColor,  
  351.      realtype  rTickRelSize, realtype  rTickSpace, int nSmallTicks, int nTickPos, 
  352.      int nLabelPos, int nLabelPrec, BOOL bText, int nValPrec,
  353.      BOOL bArc, BOOL bUnits, BOOL bAlarms, realtype rAlmRelThick, LPINT lpAlmColor);
  354.  
  355. HGOBJ WINAPI _export WRSetArcMeter (PGRAPH_DEF pGrDesc,
  356.      HDATA hData, int nChan,      
  357.      realtype  rMin,  realtype rMax, realtype  rCenterPoint,
  358.      realtype  rXCenter, realtype rYCenter, realtype  rDiam, int nStartAngle, 
  359.      int nEndAngle, int nArcColor, int nArcBackColor, realtype rArcRelThick,
  360.      realtype  rTickRelSize, realtype  rTickSpace, int nSmallTicks, int nTickPos, 
  361.      int nLabelPrec, BOOL bText, int nValPrec, BOOL bArc,      
  362.      BOOL bUnits, BOOL bAlarms, realtype  rAlmRelThick, LPINT lpAlmColor);
  363.  
  364. HGOBJ WINAPI _export WRSetPieMeter (PGRAPH_DEF pGrDesc,
  365.      HDATA hData, int  nChan,      
  366.      realtype  rMin,  realtype rMax, realtype  rCenterPoint,
  367.      realtype  rXCenter, realtype rYCenter, realtype rDiam, int nStartAngle,
  368.      int  nEndAngle, int nPieColor,  int nPieBackColor, 
  369.      realtype  rTickRelSize, realtype rTickSpace, int nSmallTicks, int nTickPos, 
  370.      int  nLabelPrec, BOOL bArc, 
  371.      BOOL bAlarms, realtype rAlmRelThick, LPINT lpAlmColor);
  372.  
  373. void WINAPI _export WRSetMeterBorder (PGRAPH_DEF pGrDesc,
  374.     HGOBJ hMeter, realtype  rXCenter, realtype  rYCenter,
  375.     realtype rXWidth, realtype rYHeight, 
  376.     COLORREF rgbBackColor, int nBorderType,
  377.     int nBorderColor, int nBorderWidth);
  378.  
  379. HGOBJ WINAPI _export WRSetScrBarControl (PGRAPH_DEF pGrDesc, 
  380.     FARPROC ScBarControlProc, realtype rX1, realtype rY1, 
  381.     realtype rX2, realtype rY2, COLORREF rgbBkColor,
  382.     realtype rScrollMin, realtype rScrollMax, realtype rSingleStep, 
  383.     realtype rPageStep, realtype rInitPos);
  384.  
  385. HGOBJ WINAPI _export WRSetButtonControl (PGRAPH_DEF pGrDesc, 
  386.     FARPROC ButControlProc, int nStyle, int nLook,
  387.     realtype rX1, realtype rY1, realtype rX2, realtype rY2, 
  388.     COLORREF rgbBkColor, LPSTR lpText, BOOL bTextLeft);
  389.  
  390. HGOBJ WINAPI _export WRSetButtonGroup (PGRAPH_DEF pGrDesc, 
  391.     FARPROC ButControlProc, int nLook,    
  392.     realtype rX1, realtype rY1, realtype rX2, realtype rY2, COLORREF rgbBkColor,
  393.     int nNumBut, int nDir, LPSTR lpText, BOOL bTextLeft);
  394.  
  395. HGOBJ WINAPI _export WRSetLEDControl (PGRAPH_DEF pGrDesc, 
  396.     realtype rX, realtype rY, realtype rDiam, COLORREF rgbBkColor,  
  397.     int nOnColor, int nOffColor);
  398.  
  399. HGOBJ WINAPI _export WRSetMessage (PGRAPH_DEF pGrDesc, HDATA hData,       
  400.     int     nBinChanNum, realtype  rX, realtype rY,
  401.     int     nBorderColor, int nBorderWidth, int nBackColor,  
  402.     int     nNumMes, LPSTR lpMes, LPINT lpMesColor);
  403.  
  404. /**************************************************************************/
  405. /* Update */
  406. /**************************************************************************/
  407. BOOL WINAPI _export WRStopObjTimeUpdate (PGRAPH_DEF pGrDesc, HGOBJ hObj);
  408. BOOL WINAPI _export WRStartTimeLabelsUpdate (PGRAPH_DEF pGrDesc,
  409.     HGOBJ hLab, HGOBJ hScrollObj);
  410. BOOL WINAPI _export WRStopTimeLabelsUpdate (PGRAPH_DEF pGrDesc,
  411.     HGOBJ hLab, HGOBJ hScrollObj);
  412. void WINAPI _export WRUpdateTimeLabels (PGRAPH_DEF pGrDesc,
  413.     HGOBJ hLab, realtype rTimeInc);
  414. void WINAPI _export WRResetTimeLabels (PGRAPH_DEF pGrDesc,
  415.     HGOBJ hLab, realtype rNewStart);
  416. BOOL WINAPI _export WRChangeTimeLabelsFormat (PGRAPH_DEF pGrDesc,
  417.     HGOBJ hLab, int nNewFormat);
  418. void WINAPI _export WRUpdateObj (PGRAPH_DEF pGrDesc, HGOBJ hDynObj);
  419. BOOL WINAPI _export WRShowHist (PGRAPH_DEF pGrDesc, 
  420.     HGOBJ hScroll, realtype rBack, realtype rRange, LPREAL lprActualBack);
  421.  
  422. /************************************************************************/
  423. /* Alarms                                                               */
  424. /************************************************************************/
  425. BOOL WINAPI _export WRSetAlarm (HDATA hData, int nAlarmType,
  426.     realtype rAlmVal, LPSTR lpAlmMessage);
  427.  
  428. BOOL WINAPI _export WRSetSetpoint (HDATA hData, realtype rSetp);
  429. void WINAPI _export WREnableAlarmCheck (HDATA hData, BOOL bOn);
  430. void WINAPI _export WRSetAlarmProc (FARPROC AlarmEventProc);
  431. void WINAPI _export WRSetAlarmHyst (HDATA hData, realtype rHyst,
  432.     realtype rDevHyst);
  433. BOOL WINAPI _export WRGetAlarm (HDATA hData, int nAlarmType, 
  434.     LPREAL lprAlmVal, BOOL FAR *lpbOn, LPSTR FAR *lpAlmMessage);
  435. BOOL WINAPI _export WRChangeAlarm (HDATA hData, int nAlarmType,
  436.     realtype rAlmVal, BOOL bOn, LPSTR lpAlmMessage);
  437.  
  438. /************************************************************************/
  439. /* Control */
  440. /************************************************************************/
  441. void WINAPI _export WRChangePIDSetp (HCONT hPID, realtype rNewSetp);
  442. BOOL WINAPI _export WRGetPIDSetp (HCONT hPID, LPREAL lprSetp);
  443. BOOL WINAPI _export WRGetPIDAutoState (HCONT hPID);
  444. void WINAPI _export WRChangePIDAutoState (HCONT hPID, BOOL bAuto);
  445. BOOL WINAPI _export WRChangePIDOut (HCONT hPID, realtype rOut);
  446.  
  447. HCONT WINAPI _export WRDefinePID (HDATA hMeasData, HDATA hOutData, 
  448.      LPSTR  lpTitle, realtype rSetp, realtype rProp, 
  449.      realtype rIntg, realtype rDeriv, realtype rSteadyState, realtype rMeasHigh, 
  450.      realtype rMeasLow, realtype rHighRange, realtype rLowRange, realtype rHighLimit, 
  451.      realtype rLowLimit, realtype rRateLim, realtype rSamplePer, 
  452.      realtype rFiltConst, BOOL bIncInc);
  453.  
  454. BOOL WINAPI _export WRCalcPID (HCONT hPID, realtype rMeas, LPREAL lprOut);
  455.  
  456. void WINAPI _export WRChangePIDConstants (HCONT hPID, realtype rNewProp,
  457.     realtype rNewIntg, realtype rNewDeriv);
  458. BOOL WINAPI _export WRGetPIDConstants (HCONT hPID, LPREAL lprProp,
  459.     LPREAL lprIntg, LPREAL lprDeriv);
  460. void WINAPI _export WRChangePIDSteadyState (HCONT hPID, realtype rNewSteadyState);
  461. void WINAPI _export WRDeletePID (HCONT hPID, BOOL bFreeData);
  462. BOOL WINAPI _export WREditPIDDlg (HCONT hPID);
  463.  
  464. /**************************************************************************/
  465. /* User interface functions ***********************************************/
  466. /**************************************************************************/
  467.  
  468. BOOL WINAPI _export WRGetAlarmLineState (PGRAPH_DEF pGrDesc, HGOBJ hObj, 
  469.     int nAlarmType);
  470. BOOL WINAPI _export WREnableAlarmLine (PGRAPH_DEF pGrDesc, HGOBJ hObj, 
  471.      int nAlarmType, BOOL bOn);
  472. BOOL WINAPI _export WRChangeAlarmMarks (PGRAPH_DEF pGrDesc, HGOBJ hObj,
  473.     LPSTR lpAlmName, int nAlarmType, BOOL bOn);
  474. BOOL WINAPI _export WRGetAlarmMarks (PGRAPH_DEF pGrDesc, HGOBJ hObj,
  475.     LPSTR FAR *lpAlmName, int nAlarmType);
  476. BOOL WINAPI _export WRGetScrollGraphParams (PGRAPH_DEF pGrDesc, HGOBJ hObj,
  477.     LPREAL lpSampleInt, LPREAL lpResetInt, LPINT lpStep);
  478. BOOL WINAPI _export WRChangeScrollGraph (PGRAPH_DEF pGrDesc, HGOBJ hObj,
  479.     realtype rSampleInt, realtype rRelResetInt, int nStep);
  480. BOOL WINAPI _export WRGetMessageParams (PGRAPH_DEF pGrDesc, HGOBJ hObj,
  481.     LPSTR FAR *lpMessage, LPINT lpColor, int n);
  482. BOOL WINAPI _export WRChangeMessage (PGRAPH_DEF pGrDesc, HGOBJ hObj,
  483.     LPSTR lpMessage, int nColor, int n);
  484. int WINAPI _export WRGetDynTextColor (PGRAPH_DEF pGrDesc, 
  485.     HGOBJ hObj, int n);
  486. BOOL WINAPI _export WRChangeDynTextColor (PGRAPH_DEF pGrDesc, HGOBJ hObj,
  487.     int nColor, int n);
  488. HGOBJ WINAPI _export WRGetAnnVal (PGRAPH_DEF pGrDesc, HGOBJ hAnn, 
  489.     int n);
  490. HGOBJ WINAPI _export WRGetAnnAlm (PGRAPH_DEF pGrDesc, HGOBJ hAnn, 
  491.     int n);
  492. HGOBJ WINAPI _export WRGetAnnUnits (PGRAPH_DEF pGrDesc, HGOBJ hAnn, 
  493.     int n);
  494. HGOBJ WINAPI _export WRGetAnnTitle (PGRAPH_DEF pGrDesc, HGOBJ hAnn);
  495. HGOBJ WINAPI _export WRGetAnnTag (PGRAPH_DEF pGrDesc, HGOBJ hAnn, 
  496.     int n);
  497. BOOL WINAPI _export WRResumeScroll (PGRAPH_DEF pGrDesc, HGOBJ hScroll);
  498. BOOL WINAPI _export WRMoveHistScroll (PGRAPH_DEF pGrDesc, 
  499.     HGOBJ  hScroll, realtype rInc, LPREAL lprActualInc);
  500. BOOL WINAPI _export WRSetScrollPos (PGRAPH_DEF pGrDesc, 
  501.    HGOBJ hScBar, realtype rPos);
  502. void WINAPI _export WRGetScrollPos (PGRAPH_DEF pGrDesc, HGOBJ hScBar, 
  503.     LPREAL lprPos);
  504. BOOL WINAPI _export WRGetScrBar (PGRAPH_DEF pGrDesc, HGOBJ hScBar, 
  505.     LPREAL lprMin, LPREAL lprMax, LPREAL lprSingleStep, LPREAL lprPageStep);
  506. BOOL WINAPI _export WRChangeScrBar (PGRAPH_DEF pGrDesc, HGOBJ hScBar, 
  507.     realtype rScrollMin, realtype rScrollMax, realtype rSingleStep, 
  508.     realtype rPageStep);
  509. int WINAPI _export WRGetButtonState (PGRAPH_DEF pGrDesc, HGOBJ hBut);
  510. int WINAPI _export WRChangeButtonState (PGRAPH_DEF pGrDesc, 
  511.     HGOBJ hBut, int nSel);
  512. void WINAPI _export WRChangeButtonColor (PGRAPH_DEF pGrDesc, 
  513.     HGOBJ hBut, COLORREF rgbNewColor, int nSel);
  514. COLORREF WINAPI _export WRGetButtonColor (PGRAPH_DEF pGrDesc, 
  515.     HGOBJ hBut, int nSel);
  516. BOOL WINAPI _export WRChangeMeterRange (PGRAPH_DEF pGrDesc, HGOBJ hMeter,
  517.     realtype rMin, realtype rMax, realtype rCenterPoint, BOOL bUpdate);
  518. BOOL WINAPI _export WRGetMeterRange (PGRAPH_DEF pGrDesc, HGOBJ hMeter,
  519.     LPREAL lprMin, LPREAL lprMax, LPREAL lprCenter);
  520. BOOL WINAPI _export WRChangeMeterTicks (PGRAPH_DEF pGrDesc, HGOBJ hMeter,
  521.     realtype rTickRelSize, realtype rTickSpace, int nSmallTicks, 
  522.     int nTickPos, BOOL bUpdate);
  523. BOOL WINAPI _export WRGetMeterTicks (PGRAPH_DEF pGrDesc, HGOBJ hMeter,
  524.     LPREAL lprTickRelSize, LPREAL lprTickSpace, 
  525.     LPINT lpSmallTicks, LPINT lpTickPos);
  526. BOOL WINAPI _export WRGetMeterCenter (PGRAPH_DEF pGrDesc, HGOBJ hMeter,
  527.     LPREAL lprXCenter, LPREAL lprYCenter, LPREAL lprDiam);
  528. BOOL WINAPI _export WRChangeMeterCenter (PGRAPH_DEF pGrDesc, HGOBJ hMeter,
  529.     realtype rXCenter, realtype rYCenter, realtype rDiam, BOOL bUpdate);
  530. BOOL WINAPI _export WRGetMeterAngles (PGRAPH_DEF pGrDesc, HGOBJ hMeter,
  531.     LPINT lpStartAngle, LPINT lpEndAngle);
  532. BOOL WINAPI _export WRChangeMeterAngles (PGRAPH_DEF pGrDesc, HGOBJ hMeter,
  533.      int nStartAngle, int nEndAngle, BOOL bUpdate);
  534. HWND WINAPI _export WRGetButtonWindow (PGRAPH_DEF pGrDesc, HGOBJ hObj, int n);
  535.  
  536. /**************************************************************************/
  537. /* Miscellaneous **********************************************************/
  538. /**************************************************************************/
  539. void WINAPI _export WRDeleteRTGraph (PGRAPH_DEF pGrDesc);
  540. void WINAPI _export WRDeleteRTObject (PGRAPH_DEF pGrDesc, HGOBJ hObj);
  541.  
  542. int WINAPI _export WRGetDynTypeSize (int nObjType);
  543. void WINAPI _export InitRTDll (LPVOID lpTop);
  544.  
  545. void WINAPI WRCleanup (BOOL bFreeData);
  546. /**************************************************************************/
  547.  
  548. #ifdef __cplusplus
  549. }
  550. #endif
  551. /**************************************************************************/
  552. #endif
  553.  
  554.  
  555.