home *** CD-ROM | disk | FTP | other *** search
/ PC World 2002 May / PCWorld_2002-05_cd.bin / Software / TemaCD / activetcltk / ActiveTcl8.3.4.1-8.win32-ix86.exe / ActiveTcl8.3.4.1-win32-ix86 / include / tkPlatDecls.h < prev    next >
Encoding:
C/C++ Source or Header  |  2001-10-22  |  6.4 KB  |  209 lines

  1. /*
  2.  * tkPlatDecls.h --
  3.  *
  4.  *    Declarations of functions in the platform-specific public Tcl API.
  5.  *
  6.  * Copyright (c) 1998-1999 by Scriptics Corporation.
  7.  *
  8.  * See the file "license.terms" for information on usage and redistribution
  9.  * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  10.  *
  11.  * RCS: @(#) $Id: tkPlatDecls.h,v 1.4 1999/04/30 22:49:55 stanton Exp $
  12.  */
  13.  
  14. #ifndef _TKPLATDECLS
  15. #define _TKPLATDECLS
  16.  
  17. #ifdef BUILD_tk
  18. #undef TCL_STORAGE_CLASS
  19. #define TCL_STORAGE_CLASS DLLEXPORT
  20. #endif
  21.  
  22. /*
  23.  * WARNING: This file is automatically generated by the tools/genStubs.tcl
  24.  * script.  Any modifications to the function declarations below should be made
  25.  * in the generic/tk.decls script.
  26.  */
  27.  
  28.  
  29. /* !BEGIN!: Do not edit below this line. */
  30.  
  31. /*
  32.  * Exported function declarations:
  33.  */
  34.  
  35. #ifdef __WIN32__
  36. /* 0 */
  37. EXTERN Window        Tk_AttachHWND _ANSI_ARGS_((Tk_Window tkwin, 
  38.                 HWND hwnd));
  39. /* 1 */
  40. EXTERN HINSTANCE    Tk_GetHINSTANCE _ANSI_ARGS_((void));
  41. /* 2 */
  42. EXTERN HWND        Tk_GetHWND _ANSI_ARGS_((Window window));
  43. /* 3 */
  44. EXTERN Tk_Window    Tk_HWNDToWindow _ANSI_ARGS_((HWND hwnd));
  45. /* 4 */
  46. EXTERN void        Tk_PointerEvent _ANSI_ARGS_((HWND hwnd, int x, int y));
  47. /* 5 */
  48. EXTERN int        Tk_TranslateWinEvent _ANSI_ARGS_((HWND hwnd, 
  49.                 UINT message, WPARAM wParam, LPARAM lParam, 
  50.                 LRESULT * result));
  51. #endif /* __WIN32__ */
  52. #ifdef MAC_TCL
  53. /* 0 */
  54. EXTERN void        Tk_MacSetEmbedHandler _ANSI_ARGS_((
  55.                 Tk_MacEmbedRegisterWinProc * registerWinProcPtr, 
  56.                 Tk_MacEmbedGetGrafPortProc * getPortProcPtr, 
  57.                 Tk_MacEmbedMakeContainerExistProc * containerExistProcPtr, 
  58.                 Tk_MacEmbedGetClipProc * getClipProc, 
  59.                 Tk_MacEmbedGetOffsetInParentProc * getOffsetProc));
  60. /* 1 */
  61. EXTERN void        Tk_MacTurnOffMenus _ANSI_ARGS_((void));
  62. /* 2 */
  63. EXTERN void        Tk_MacTkOwnsCursor _ANSI_ARGS_((int tkOwnsIt));
  64. /* 3 */
  65. EXTERN void        TkMacInitMenus _ANSI_ARGS_((Tcl_Interp * interp));
  66. /* 4 */
  67. EXTERN void        TkMacInitAppleEvents _ANSI_ARGS_((
  68.                 Tcl_Interp * interp));
  69. /* 5 */
  70. EXTERN int        TkMacConvertEvent _ANSI_ARGS_((
  71.                 EventRecord * eventPtr));
  72. /* 6 */
  73. EXTERN int        TkMacConvertTkEvent _ANSI_ARGS_((
  74.                 EventRecord * eventPtr, Window window));
  75. /* 7 */
  76. EXTERN void        TkGenWMConfigureEvent _ANSI_ARGS_((Tk_Window tkwin, 
  77.                 int x, int y, int width, int height, 
  78.                 int flags));
  79. /* 8 */
  80. EXTERN void        TkMacInvalClipRgns _ANSI_ARGS_((TkWindow * winPtr));
  81. /* 9 */
  82. EXTERN int        TkMacHaveAppearance _ANSI_ARGS_((void));
  83. /* 10 */
  84. EXTERN GWorldPtr    TkMacGetDrawablePort _ANSI_ARGS_((Drawable drawable));
  85. #endif /* MAC_TCL */
  86.  
  87. typedef struct TkPlatStubs {
  88.     int magic;
  89.     struct TkPlatStubHooks *hooks;
  90.  
  91. #ifdef __WIN32__
  92.     Window (*tk_AttachHWND) _ANSI_ARGS_((Tk_Window tkwin, HWND hwnd)); /* 0 */
  93.     HINSTANCE (*tk_GetHINSTANCE) _ANSI_ARGS_((void)); /* 1 */
  94.     HWND (*tk_GetHWND) _ANSI_ARGS_((Window window)); /* 2 */
  95.     Tk_Window (*tk_HWNDToWindow) _ANSI_ARGS_((HWND hwnd)); /* 3 */
  96.     void (*tk_PointerEvent) _ANSI_ARGS_((HWND hwnd, int x, int y)); /* 4 */
  97.     int (*tk_TranslateWinEvent) _ANSI_ARGS_((HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam, LRESULT * result)); /* 5 */
  98. #endif /* __WIN32__ */
  99. #ifdef MAC_TCL
  100.     void (*tk_MacSetEmbedHandler) _ANSI_ARGS_((Tk_MacEmbedRegisterWinProc * registerWinProcPtr, Tk_MacEmbedGetGrafPortProc * getPortProcPtr, Tk_MacEmbedMakeContainerExistProc * containerExistProcPtr, Tk_MacEmbedGetClipProc * getClipProc, Tk_MacEmbedGetOffsetInParentProc * getOffsetProc)); /* 0 */
  101.     void (*tk_MacTurnOffMenus) _ANSI_ARGS_((void)); /* 1 */
  102.     void (*tk_MacTkOwnsCursor) _ANSI_ARGS_((int tkOwnsIt)); /* 2 */
  103.     void (*tkMacInitMenus) _ANSI_ARGS_((Tcl_Interp * interp)); /* 3 */
  104.     void (*tkMacInitAppleEvents) _ANSI_ARGS_((Tcl_Interp * interp)); /* 4 */
  105.     int (*tkMacConvertEvent) _ANSI_ARGS_((EventRecord * eventPtr)); /* 5 */
  106.     int (*tkMacConvertTkEvent) _ANSI_ARGS_((EventRecord * eventPtr, Window window)); /* 6 */
  107.     void (*tkGenWMConfigureEvent) _ANSI_ARGS_((Tk_Window tkwin, int x, int y, int width, int height, int flags)); /* 7 */
  108.     void (*tkMacInvalClipRgns) _ANSI_ARGS_((TkWindow * winPtr)); /* 8 */
  109.     int (*tkMacHaveAppearance) _ANSI_ARGS_((void)); /* 9 */
  110.     GWorldPtr (*tkMacGetDrawablePort) _ANSI_ARGS_((Drawable drawable)); /* 10 */
  111. #endif /* MAC_TCL */
  112. } TkPlatStubs;
  113.  
  114. #ifdef __cplusplus
  115. extern "C" {
  116. #endif
  117. extern TkPlatStubs *tkPlatStubsPtr;
  118. #ifdef __cplusplus
  119. }
  120. #endif
  121.  
  122. #if defined(USE_TK_STUBS) && !defined(USE_TK_STUB_PROCS)
  123.  
  124. /*
  125.  * Inline function declarations:
  126.  */
  127.  
  128. #ifdef __WIN32__
  129. #ifndef Tk_AttachHWND
  130. #define Tk_AttachHWND \
  131.     (tkPlatStubsPtr->tk_AttachHWND) /* 0 */
  132. #endif
  133. #ifndef Tk_GetHINSTANCE
  134. #define Tk_GetHINSTANCE \
  135.     (tkPlatStubsPtr->tk_GetHINSTANCE) /* 1 */
  136. #endif
  137. #ifndef Tk_GetHWND
  138. #define Tk_GetHWND \
  139.     (tkPlatStubsPtr->tk_GetHWND) /* 2 */
  140. #endif
  141. #ifndef Tk_HWNDToWindow
  142. #define Tk_HWNDToWindow \
  143.     (tkPlatStubsPtr->tk_HWNDToWindow) /* 3 */
  144. #endif
  145. #ifndef Tk_PointerEvent
  146. #define Tk_PointerEvent \
  147.     (tkPlatStubsPtr->tk_PointerEvent) /* 4 */
  148. #endif
  149. #ifndef Tk_TranslateWinEvent
  150. #define Tk_TranslateWinEvent \
  151.     (tkPlatStubsPtr->tk_TranslateWinEvent) /* 5 */
  152. #endif
  153. #endif /* __WIN32__ */
  154. #ifdef MAC_TCL
  155. #ifndef Tk_MacSetEmbedHandler
  156. #define Tk_MacSetEmbedHandler \
  157.     (tkPlatStubsPtr->tk_MacSetEmbedHandler) /* 0 */
  158. #endif
  159. #ifndef Tk_MacTurnOffMenus
  160. #define Tk_MacTurnOffMenus \
  161.     (tkPlatStubsPtr->tk_MacTurnOffMenus) /* 1 */
  162. #endif
  163. #ifndef Tk_MacTkOwnsCursor
  164. #define Tk_MacTkOwnsCursor \
  165.     (tkPlatStubsPtr->tk_MacTkOwnsCursor) /* 2 */
  166. #endif
  167. #ifndef TkMacInitMenus
  168. #define TkMacInitMenus \
  169.     (tkPlatStubsPtr->tkMacInitMenus) /* 3 */
  170. #endif
  171. #ifndef TkMacInitAppleEvents
  172. #define TkMacInitAppleEvents \
  173.     (tkPlatStubsPtr->tkMacInitAppleEvents) /* 4 */
  174. #endif
  175. #ifndef TkMacConvertEvent
  176. #define TkMacConvertEvent \
  177.     (tkPlatStubsPtr->tkMacConvertEvent) /* 5 */
  178. #endif
  179. #ifndef TkMacConvertTkEvent
  180. #define TkMacConvertTkEvent \
  181.     (tkPlatStubsPtr->tkMacConvertTkEvent) /* 6 */
  182. #endif
  183. #ifndef TkGenWMConfigureEvent
  184. #define TkGenWMConfigureEvent \
  185.     (tkPlatStubsPtr->tkGenWMConfigureEvent) /* 7 */
  186. #endif
  187. #ifndef TkMacInvalClipRgns
  188. #define TkMacInvalClipRgns \
  189.     (tkPlatStubsPtr->tkMacInvalClipRgns) /* 8 */
  190. #endif
  191. #ifndef TkMacHaveAppearance
  192. #define TkMacHaveAppearance \
  193.     (tkPlatStubsPtr->tkMacHaveAppearance) /* 9 */
  194. #endif
  195. #ifndef TkMacGetDrawablePort
  196. #define TkMacGetDrawablePort \
  197.     (tkPlatStubsPtr->tkMacGetDrawablePort) /* 10 */
  198. #endif
  199. #endif /* MAC_TCL */
  200.  
  201. #endif /* defined(USE_TK_STUBS) && !defined(USE_TK_STUB_PROCS) */
  202.  
  203. /* !END!: Do not edit above this line. */
  204.  
  205. #undef TCL_STORAGE_CLASS
  206. #define TCL_STORAGE_CLASS DLLIMPORT
  207.  
  208. #endif /* _TKPLATDECLS */
  209.