From e8e7449d29716dbc5b1e6ed25d6af90e04c18249 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Thu, 28 Mar 2013 20:52:35 +0000 Subject: Demonstrate how the Tk_Main() macro can use Tcl_InitSubsystems(), as fully equivalent replacement of Tcl_FindExecutable/Tcl_CreateInterp. (not part of TIP #414) --- generic/tk.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/generic/tk.h b/generic/tk.h index aa9cd22..5b79e5a 100644 --- a/generic/tk.h +++ b/generic/tk.h @@ -1498,10 +1498,10 @@ typedef struct Tk_ElementSpec { /* Removed Tk_Main, use macro instead */ #if defined(__WIN32__) || defined(__CYGWIN__) #define Tk_Main(argc, argv, proc) Tk_MainEx(argc, argv, proc, \ - (Tcl_FindExecutable(0), (Tcl_CreateInterp)())) + (Tcl_InitSubsystems(TCL_INIT_CREATE, 0, NULL))) #else #define Tk_Main(argc, argv, proc) Tk_MainEx(argc, argv, proc, \ - (Tcl_FindExecutable(argv[0]), (Tcl_CreateInterp)())) + (Tcl_InitSubsystems(TCL_INIT_CREATE, 0, argv))) #endif const char * Tk_InitStubs(Tcl_Interp *interp, const char *version, int exact); -- cgit v0.12