TIP #338: Embedder Access to Startup Scripts of *_Main()

Title:Embedder Access to Startup Scripts of *_Main()
Version:$Revision: 1.4 $
Author:Don Porter <dgp at users dot sf dot net>
Created:Wednesday, 22 October 2008
Keywords:Tcl, Tk, tclsh, wish


This TIP proposes to make public the routines that get and set the startup script file that Tcl_Main or Tk_Main evaluate in their non-interactive modes.


When support for the -encoding option was added to tclsh and wish TIP #137, two new internal routines were added to Tcl:

Tcl_Obj *Tcl_GetStartupScript(const char **encodingNamePtr)

void Tcl_SetStartupScript(Tcl_Obj *pathPtr, const char *encodingName)

These routines (or other weaker alternative internal routines) are used by both wish and Tclkit by way of the internal stubs table to manipulate the startup script for Tcl_Main or Tk_Main to evaluate.


The naming of these routines indicate they were always intended to be(come) public.

These are the last "private" Tcl routines used by Tk and wish. After implementation of this TIP, Tk can drop use of tclInt.h.


Make these routines public.


There will need to be some care taken for existing users of these routines via the private stubs table. The ability to compile against Tcl 8.6 headers, yet run against a pre-8.6 stubs table will likely be lost.


This document has been placed in the public domain.

Powered by Tcl[Index] [History] [HTML Format] [Source Format] [LaTeX Format] [Text Format] [XML Format] [*roff Format (experimental)] [RTF Format (experimental)]

TIP AutoGenerator - written by Donal K. Fellows