# Copyright (c) 1994 The Regents of the University of California. # Copyright (c) 1994 Sun Microsystems, Inc. # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. # # @(#) EventInit.3 1.4 95/05/06 15:29:22 # =head1 NAME Tk_EventInit - Use the Tk event loop without the rest of Tk =for category C Programming =head1 SYNOPSIS B<#include Etk.hE> int B(I) =head1 ARGUMENTS =over 4 =item Tcl_Interp *interp (in) Interpreter in which event-related Tk commands are to be created. =back =head1 DESCRIPTION This procedure may be invoked to use the Tk event management functions without the rest of Tk (e.g., in applications that do not have access to a display). B creates the B and B commands in I. It also creates versions of the B and B commands with reduced functionality: the B command supports only the B option, not B or $widget, and B does not check for X events. B always returns B to signal that it completed successfully. The event-management procedures in Tk are divided into two groups, those that can be used stand-alone and those that require the full Tk library to be present. The following procedures may be used stand-alone: B, B, B, B, B, B, B, B, B, and B. Note that B cannot be used without the full Tk library, since it checks to see if windows are still open. If an application uses the event procedures stand-alone, it must include its own main loop that invokes B repeatedly. B is typically called from an application's B procedure; it should not be invoked in applications that use the full Tk library (e.g., those that have already invoked B). However, it is OK for an application to start up using B, compute without X for a while, and later invoke B. When B is invoked, the full suite of windowing Tcl commands will become available, and the full-blown versions of B and B will replace the abridged versions created with B. =head1 KEYWORDS event management, Tcl_AppInit