summaryrefslogtreecommitdiffstats
path: root/generic/tkStubInit.c
diff options
context:
space:
mode:
Diffstat (limited to 'generic/tkStubInit.c')
-rw-r--r--generic/tkStubInit.c291
1 files changed, 72 insertions, 219 deletions
diff --git a/generic/tkStubInit.c b/generic/tkStubInit.c
index e175a99..03c794e 100644
--- a/generic/tkStubInit.c
+++ b/generic/tkStubInit.c
@@ -1,40 +1,33 @@
-/*
+/*
* tkStubInit.c --
*
* This file contains the initializers for the Tk stub vectors.
*
* Copyright (c) 1998-1999 by Scriptics Corporation.
*
- * See the file "license.terms" for information on usage and redistribution
- * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
+ * See the file "license.terms" for information on usage and redistribution of
+ * this file, and for a DISCLAIMER OF ALL WARRANTIES.
*/
#include "tkInt.h"
-#include "tkPort.h"
-#if !(defined(__WIN32__) && defined(MAC_TCL) || defined(MAC_OSX_TK))
+#if !(defined(__WIN32__) || defined(MAC_OSX_TK))
/* UNIX */
#define UNIX_TK
+#include "tkUnixInt.h"
#endif
#ifdef __WIN32__
#include "tkWinInt.h"
#endif
-#if defined(MAC_TCL)
-/* set this locally .. we could have used _TKMACINT */
-#define MAC_TK
-#include "tkMacInt.h"
-#endif
#if defined(MAC_OSX_TK)
-/* set this locally .. we could have used _TKMACINT */
+/* we could have used _TKMACINT */
#include "tkMacOSXInt.h"
#endif
-#include "tkDecls.h"
+/* TODO: These ought to come in some other way */
#include "tkPlatDecls.h"
-#include "tkIntDecls.h"
-#include "tkIntPlatDecls.h"
#include "tkIntXlibDecls.h"
#ifdef __WIN32__
@@ -65,11 +58,19 @@ doNothing(void)
# define TkWmCleanup (void (*) (TkDisplay *)) doNothing
# define TkSendCleanup (void (*) (TkDisplay *)) doNothing
# define TkFreeXId (void (*) (TkDisplay *)) doNothing
+# define TkpTestsendCmd 0
#else
/*
* Remove macros that will interfere with the definitions below.
*/
+
+MODULE_SCOPE TkIntStubs tkIntStubs;
+MODULE_SCOPE TkIntPlatStubs tkIntPlatStubs;
+MODULE_SCOPE TkIntXlibStubs tkIntXlibStubs;
+MODULE_SCOPE TkPlatStubs tkPlatStubs;
+MODULE_SCOPE TkStubs tkStubs;
+
# undef TkClipBox
# undef TkCreateRegion
# undef TkDestroyRegion
@@ -109,8 +110,6 @@ doNothing(void)
# ifdef __CYGWIN__
# define Tk_GetHINSTANCE TkPlatGetHINSTANCE
-# define TkSetPixmapColormap TkPlatSetPixmapColormap
-# define TkpPrintWindowId TkPlatpPrintWindowId
/*
* Trick, so we don't have to include <windows.h> here, which in any
@@ -120,8 +119,6 @@ doNothing(void)
#define GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS 0x00000004
int __stdcall GetModuleHandleExW(unsigned int, const char *, void *);
-TkIntStubs tkIntStubs;
-
static void *Tk_GetHINSTANCE()
{
void *hInstance = NULL;
@@ -131,14 +128,14 @@ static void *Tk_GetHINSTANCE()
return hInstance;
}
-static void
+void
TkSetPixmapColormap(pixmap, colormap)
Pixmap pixmap;
Colormap colormap;
{
}
-static void
+void
TkpPrintWindowId(buf, window)
char *buf; /* Pointer to string large enough to hold
* the hex representation of a pointer. */
@@ -185,7 +182,6 @@ TkpPrintWindowId(buf, window)
# define TkWinSetHINSTANCE 0
# define TkWinGetPlatformTheme 0
# define TkWinChildProc 0
-
# endif /* __CYGWIN__ */
# endif /* !MAC_TCL && !MACC_OSX_TCL */
#endif /* !__WIN32__ */
@@ -322,41 +318,35 @@ TkIntStubs tkIntStubs = {
TkSetRegion, /* 118 */
TkUnionRectWithRegion, /* 119 */
NULL, /* 120 */
-#if !defined(__WIN32__) && !defined(MAC_TCL) /* UNIX */
+#if !(defined(__WIN32__) || defined(MAC_OSX_TK)) /* X11 */
NULL, /* 121 */
-#endif /* UNIX */
+#endif /* X11 */
#if defined(__WIN32__) /* WIN */
NULL, /* 121 */
#endif /* WIN */
-#ifdef MAC_TCL
- TkpCreateNativeBitmap, /* 121 */
-#endif /* MAC_TCL */
#ifdef MAC_OSX_TK /* AQUA */
+ NULL, /* 121 */ /* Dummy entry for stubs table backwards compatibility */
TkpCreateNativeBitmap, /* 121 */
#endif /* AQUA */
-#if !defined(__WIN32__) && !defined(MAC_TCL) /* UNIX */
+#if !(defined(__WIN32__) || defined(MAC_OSX_TK)) /* X11 */
NULL, /* 122 */
-#endif /* UNIX */
+#endif /* X11 */
#if defined(__WIN32__) /* WIN */
NULL, /* 122 */
#endif /* WIN */
-#ifdef MAC_TCL
- TkpDefineNativeBitmaps, /* 122 */
-#endif /* MAC_TCL */
#ifdef MAC_OSX_TK /* AQUA */
+ NULL, /* 122 */ /* Dummy entry for stubs table backwards compatibility */
TkpDefineNativeBitmaps, /* 122 */
#endif /* AQUA */
NULL, /* 123 */
-#if !defined(__WIN32__) && !defined(MAC_TCL) /* UNIX */
+#if !(defined(__WIN32__) || defined(MAC_OSX_TK)) /* X11 */
NULL, /* 124 */
-#endif /* UNIX */
+#endif /* X11 */
#if defined(__WIN32__) /* WIN */
NULL, /* 124 */
#endif /* WIN */
-#ifdef MAC_TCL
- TkpGetNativeAppBitmap, /* 124 */
-#endif /* MAC_TCL */
#ifdef MAC_OSX_TK /* AQUA */
+ NULL, /* 124 */ /* Dummy entry for stubs table backwards compatibility */
TkpGetNativeAppBitmap, /* 124 */
#endif /* AQUA */
NULL, /* 125 */
@@ -384,9 +374,37 @@ TkIntStubs tkIntStubs = {
TkStylePkgFree, /* 147 */
TkToplevelWindowForCommand, /* 148 */
TkGetOptionSpec, /* 149 */
- NULL, /* 150 */
- NULL, /* 151 */
+ TkMakeRawCurve, /* 150 */
+ TkMakeRawCurvePostscript, /* 151 */
TkpDrawFrame, /* 152 */
+ TkCreateThreadExitHandler, /* 153 */
+ TkDeleteThreadExitHandler, /* 154 */
+ NULL, /* 155 */
+ TkpTestembedCmd, /* 156 */
+ TkpTesttextCmd, /* 157 */
+ NULL, /* 158 */
+ NULL, /* 159 */
+ NULL, /* 160 */
+ NULL, /* 161 */
+ NULL, /* 162 */
+ NULL, /* 163 */
+ NULL, /* 164 */
+ NULL, /* 165 */
+ NULL, /* 166 */
+ NULL, /* 167 */
+ NULL, /* 168 */
+ TkStateParseProc, /* 169 */
+ TkStatePrintProc, /* 170 */
+ TkCanvasDashParseProc, /* 171 */
+ TkCanvasDashPrintProc, /* 172 */
+ TkOffsetParseProc, /* 173 */
+ TkOffsetPrintProc, /* 174 */
+ TkPixelParseProc, /* 175 */
+ TkPixelPrintProc, /* 176 */
+ TkOrientParseProc, /* 177 */
+ TkOrientPrintProc, /* 178 */
+ TkSmoothParseProc, /* 179 */
+ TkSmoothPrintProc, /* 180 */
};
TkIntPlatStubs tkIntPlatStubs = {
@@ -441,76 +459,8 @@ TkIntPlatStubs tkIntPlatStubs = {
TkWmCleanup, /* 45 */
TkSendCleanup, /* 46 */
TkFreeXId, /* 47 */
+ TkpTestsendCmd, /* 48 */
#endif /* WIN */
-#ifdef MAC_TCL
- TkGenerateActivateEvents, /* 0 */
- NULL, /* 1 */
- NULL, /* 2 */
- TkpGetMS, /* 3 */
- NULL, /* 4 */
- TkPointerDeadWindow, /* 5 */
- TkpSetCapture, /* 6 */
- TkpSetCursor, /* 7 */
- TkpWmSetState, /* 8 */
- NULL, /* 9 */
- TkAboutDlg, /* 10 */
- NULL, /* 11 */
- NULL, /* 12 */
- TkGetTransientMaster, /* 13 */
- TkGenerateButtonEvent, /* 14 */
- NULL, /* 15 */
- TkGenWMDestroyEvent, /* 16 */
- NULL, /* 17 */
- TkMacButtonKeyState, /* 18 */
- TkMacClearMenubarActive, /* 19 */
- NULL, /* 20 */
- TkMacDispatchMenuEvent, /* 21 */
- TkMacInstallCursor, /* 22 */
- NULL, /* 23 */
- TkMacHandleTearoffMenu, /* 24 */
- NULL, /* 25 */
- NULL, /* 26 */
- TkMacDoHLEvent, /* 27 */
- NULL, /* 28 */
- TkMacGenerateTime, /* 29 */
- NULL, /* 30 */
- TkMacGetScrollbarGrowWindow, /* 31 */
- TkMacGetXWindow, /* 32 */
- TkMacGrowToplevel, /* 33 */
- TkMacHandleMenuSelect, /* 34 */
- NULL, /* 35 */
- NULL, /* 36 */
- NULL, /* 37 */
- TkMacInvalidateWindow, /* 38 */
- TkMacIsCharacterMissing, /* 39 */
- TkMacMakeRealWindowExist, /* 40 */
- TkMacMakeStippleMap, /* 41 */
- TkMacMenuClick, /* 42 */
- TkMacRegisterOffScreenWindow, /* 43 */
- TkMacResizable, /* 44 */
- NULL, /* 45 */
- TkMacSetHelpMenuItemCount, /* 46 */
- TkMacSetScrollbarGrow, /* 47 */
- TkMacSetUpClippingRgn, /* 48 */
- TkMacSetUpGraphicsPort, /* 49 */
- TkMacUpdateClipRgn, /* 50 */
- TkMacUnregisterMacWindow, /* 51 */
- TkMacUseMenuID, /* 52 */
- TkMacVisableClipRgn, /* 53 */
- TkMacWinBounds, /* 54 */
- TkMacWindowOffset, /* 55 */
- NULL, /* 56 */
- TkSetMacColor, /* 57 */
- TkSetWMName, /* 58 */
- TkSuspendClipboard, /* 59 */
- NULL, /* 60 */
- TkMacZoomToplevel, /* 61 */
- Tk_TopCoordsToWindow, /* 62 */
- TkMacContainerId, /* 63 */
- TkMacGetHostToplevel, /* 64 */
- TkMacPreprocessMenu, /* 65 */
- TkpIsWindowFloating, /* 66 */
-#endif /* MAC_TCL */
#ifdef MAC_OSX_TK /* AQUA */
TkGenerateActivateEvents, /* 0 */
NULL, /* 1 */
@@ -567,7 +517,7 @@ TkIntPlatStubs tkIntPlatStubs = {
NULL, /* 52 */
TkpGetMS, /* 53 */
#endif /* AQUA */
-#if !(defined(__WIN32__) || defined(__CYGWIN__) || defined(MAC_TCL) || defined(MAC_OSX_TK)) /* X11 */
+#if !(defined(__WIN32__) || defined(__CYGWIN__) || defined(MAC_OSX_TK)) /* X11 */
TkCreateXEventSource, /* 0 */
TkFreeWindowId, /* 1 */
TkInitXId, /* 2 */
@@ -581,6 +531,7 @@ TkIntPlatStubs tkIntPlatStubs = {
TkSendCleanup, /* 10 */
TkFreeXId, /* 11 */
TkpWmSetState, /* 12 */
+ TkpTestsendCmd, /* 13 */
#endif /* X11 */
};
@@ -696,99 +647,6 @@ TkIntXlibStubs tkIntXlibStubs = {
XWarpPointer, /* 105 */
XFillRectangle, /* 106 */
#endif /* WIN */
-#ifdef MAC_TCL
- XSetDashes, /* 0 */
- XGetModifierMapping, /* 1 */
- XCreateImage, /* 2 */
- XGetImage, /* 3 */
- XGetAtomName, /* 4 */
- XKeysymToString, /* 5 */
- XCreateColormap, /* 6 */
- XGContextFromGC, /* 7 */
- XKeycodeToKeysym, /* 8 */
- XStringToKeysym, /* 9 */
- XRootWindow, /* 10 */
- XSetErrorHandler, /* 11 */
- XAllocColor, /* 12 */
- XBell, /* 13 */
- XChangeProperty, /* 14 */
- XChangeWindowAttributes, /* 15 */
- XConfigureWindow, /* 16 */
- XCopyArea, /* 17 */
- XCopyPlane, /* 18 */
- XCreateBitmapFromData, /* 19 */
- XDefineCursor, /* 20 */
- XDestroyWindow, /* 21 */
- XDrawArc, /* 22 */
- XDrawLines, /* 23 */
- XDrawRectangle, /* 24 */
- XFillArc, /* 25 */
- XFillPolygon, /* 26 */
- XFillRectangles, /* 27 */
- XFreeColormap, /* 28 */
- XFreeColors, /* 29 */
- XFreeModifiermap, /* 30 */
- XGetGeometry, /* 31 */
- XGetWindowProperty, /* 32 */
- XGrabKeyboard, /* 33 */
- XGrabPointer, /* 34 */
- XKeysymToKeycode, /* 35 */
- XMapWindow, /* 36 */
- XMoveResizeWindow, /* 37 */
- XMoveWindow, /* 38 */
- XQueryPointer, /* 39 */
- XRaiseWindow, /* 40 */
- XRefreshKeyboardMapping, /* 41 */
- XResizeWindow, /* 42 */
- XSelectInput, /* 43 */
- XSendEvent, /* 44 */
- XSetIconName, /* 45 */
- XSetInputFocus, /* 46 */
- XSetSelectionOwner, /* 47 */
- XSetWindowBackground, /* 48 */
- XSetWindowBackgroundPixmap, /* 49 */
- XSetWindowBorder, /* 50 */
- XSetWindowBorderPixmap, /* 51 */
- XSetWindowBorderWidth, /* 52 */
- XSetWindowColormap, /* 53 */
- XUngrabKeyboard, /* 54 */
- XUngrabPointer, /* 55 */
- XUnmapWindow, /* 56 */
- TkPutImage, /* 57 */
- XParseColor, /* 58 */
- XCreateGC, /* 59 */
- XFreeGC, /* 60 */
- XInternAtom, /* 61 */
- XSetBackground, /* 62 */
- XSetForeground, /* 63 */
- XSetClipMask, /* 64 */
- XSetClipOrigin, /* 65 */
- XSetTSOrigin, /* 66 */
- XChangeGC, /* 67 */
- XSetFont, /* 68 */
- XSetArcMode, /* 69 */
- XSetStipple, /* 70 */
- XSetFillRule, /* 71 */
- XSetFillStyle, /* 72 */
- XSetFunction, /* 73 */
- XSetLineAttributes, /* 74 */
- _XInitImageFuncPtrs, /* 75 */
- XCreateIC, /* 76 */
- XGetVisualInfo, /* 77 */
- XSetWMClientMachine, /* 78 */
- XStringListToTextProperty, /* 79 */
- XDrawSegments, /* 80 */
- XForceScreenSaver, /* 81 */
- XDrawLine, /* 82 */
- XFillRectangle, /* 83 */
- XClearWindow, /* 84 */
- XDrawPoint, /* 85 */
- XDrawPoints, /* 86 */
- XWarpPointer, /* 87 */
- XQueryColor, /* 88 */
- XQueryColors, /* 89 */
- XQueryTree, /* 90 */
-#endif /* MAC_TCL */
#ifdef MAC_OSX_TK /* AQUA */
XSetDashes, /* 0 */
XGetModifierMapping, /* 1 */
@@ -896,19 +754,6 @@ TkPlatStubs tkPlatStubs = {
Tk_PointerEvent, /* 4 */
Tk_TranslateWinEvent, /* 5 */
#endif /* WIN */
-#ifdef MAC_TCL
- Tk_MacSetEmbedHandler, /* 0 */
- Tk_MacTurnOffMenus, /* 1 */
- Tk_MacTkOwnsCursor, /* 2 */
- TkMacInitMenus, /* 3 */
- TkMacInitAppleEvents, /* 4 */
- TkMacConvertEvent, /* 5 */
- TkMacConvertTkEvent, /* 6 */
- TkGenWMConfigureEvent, /* 7 */
- TkMacInvalClipRgns, /* 8 */
- TkMacHaveAppearance, /* 9 */
- TkMacGetDrawablePort, /* 10 */
-#endif /* MAC_TCL */
#ifdef MAC_OSX_TK /* AQUA */
Tk_MacOSXSetEmbedHandler, /* 0 */
Tk_MacOSXTurnOffMenus, /* 1 */
@@ -1082,9 +927,9 @@ TkStubs tkStubs = {
Tk_PhotoPutZoomedBlock_NoComposite, /* 145 */
Tk_PhotoGetImage, /* 146 */
Tk_PhotoBlank, /* 147 */
- Tk_PhotoExpand, /* 148 */
+ Tk_PhotoExpand_Panic, /* 148 */
Tk_PhotoGetSize, /* 149 */
- Tk_PhotoSetSize, /* 150 */
+ Tk_PhotoSetSize_Panic, /* 150 */
Tk_PointToChar, /* 151 */
Tk_PostscriptFontName, /* 152 */
Tk_PreserveColormap, /* 153 */
@@ -1180,8 +1025,8 @@ TkStubs tkStubs = {
Tk_SetInternalBorderEx, /* 243 */
Tk_SetMinimumRequestSize, /* 244 */
Tk_SetCaretPos, /* 245 */
- Tk_PhotoPutBlock, /* 246 */
- Tk_PhotoPutZoomedBlock, /* 247 */
+ Tk_PhotoPutBlock_Panic, /* 246 */
+ Tk_PhotoPutZoomedBlock_Panic, /* 247 */
Tk_CollapseMotionEvents, /* 248 */
Tk_RegisterStyleEngine, /* 249 */
Tk_GetStyleEngine, /* 250 */
@@ -1199,10 +1044,18 @@ TkStubs tkStubs = {
Tk_GetElementBox, /* 262 */
Tk_GetElementBorderWidth, /* 263 */
Tk_DrawElement, /* 264 */
+ Tk_PhotoExpand, /* 265 */
+ Tk_PhotoPutBlock, /* 266 */
+ Tk_PhotoPutZoomedBlock, /* 267 */
+ Tk_PhotoSetSize, /* 268 */
+ Tk_GetUserInactiveTime, /* 269 */
+ Tk_ResetUserInactiveTime, /* 270 */
+ Tk_Interp, /* 271 */
+ Tk_CreateOldImageType, /* 272 */
+ Tk_CreateOldPhotoImageFormat, /* 273 */
};
/* !END!: Do not edit above this line. */
#undef UNIX_TK
-#undef MAC_TK
#undef MAC_OSX_TK