1 |
/* |
2 |
* tkConsole.h -- |
3 |
* |
4 |
* This file implements a Tcl console for systems that may not |
5 |
* otherwise have access to a console. It uses the Text widget |
6 |
* and provides special access via a console command. |
7 |
* |
8 |
* Copyright (c) 1995-1996 Sun Microsystems, Inc. |
9 |
* |
10 |
* See the file "TclTk.license.terms" for information on usage and |
11 |
* redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES. |
12 |
* |
13 |
* SCCS: @(#) tkConsole.c 1.51 97/04/25 16:52:39 |
14 |
*/ |
15 |
|
16 |
/** @file |
17 |
* This file implements a Tcl console for systems that may not |
18 |
* otherwise have access to a console. It uses the Text widget |
19 |
* and provides special access via a console command.<br><br> |
20 |
* |
21 |
* TkConsoleCreate() and TkConsoleInit() are not exported functions |
22 |
* in the Tcl/Tk 8.0 distribution. We've pulled them into our |
23 |
* application because we need some sort of command line when running |
24 |
* ASCEND under Windows.<br><br> |
25 |
* |
26 |
* To build with the TkConsole, you'll need to |
27 |
* - define the CPP macro ASC_USE_TK_CONSOLE |
28 |
* - make sure the ``generic'' subdirectory in the |
29 |
* Tk source distribution is on your include path. |
30 |
*/ |
31 |
|
32 |
#ifndef _TKCONSOLE_H |
33 |
# define _TKCONSOLE_H |
34 |
|
35 |
# ifndef ASC_USE_TK_CONSOLE |
36 |
# ifdef __WIN32__ |
37 |
/* # define ASC_USE_TK_CONSOLE */ |
38 |
# endif |
39 |
# endif |
40 |
|
41 |
extern void TkConsoleCreate(void); |
42 |
/**< |
43 |
* <!-- TkConsoleCreate -- --> |
44 |
* |
45 |
* Create the console channels and install them as the standard |
46 |
* channels. All I/O will be discarded until TkConsoleInit is |
47 |
* called to attach the console to a text widget.<br><br> |
48 |
* |
49 |
* Results: None. |
50 |
* |
51 |
* Side effects: Creates the console channel and installs it as |
52 |
* the standard channels. |
53 |
*/ |
54 |
|
55 |
extern int TkConsoleInit(Tcl_Interp *interp); |
56 |
/**< |
57 |
* <!-- int TkConsoleInit(interp); --> |
58 |
* <!-- Tcl_Interp *interp; // Interpreter to use for prompting. --> |
59 |
* |
60 |
* Initialize the console. This code actually creates a new |
61 |
* application and associated interpreter. This effectivly hides |
62 |
* the implementation from the main application. |
63 |
* |
64 |
* Results: None. |
65 |
* |
66 |
* Side effects: A new console it created. |
67 |
*/ |
68 |
|
69 |
#endif /* _TKCONSOLE_H */ |
70 |
|