summaryrefslogtreecommitdiffstats
path: root/doc/ManageGeom.3
diff options
context:
space:
mode:
authorrjohnson <rjohnson>1998-04-01 09:37:39 (GMT)
committerrjohnson <rjohnson>1998-04-01 09:37:39 (GMT)
commit13242623d2ff3ea02ab6a62bfb48a7dbb5c27e22 (patch)
tree3100714738a7941b590efee466a774862f9671c3 /doc/ManageGeom.3
parente4ab1102029f9ac557ff190bfb9d34408340f345 (diff)
downloadtk-13242623d2ff3ea02ab6a62bfb48a7dbb5c27e22.zip
tk-13242623d2ff3ea02ab6a62bfb48a7dbb5c27e22.tar.gz
tk-13242623d2ff3ea02ab6a62bfb48a7dbb5c27e22.tar.bz2
Initial revision
Diffstat (limited to 'doc/ManageGeom.3')
-rw-r--r--doc/ManageGeom.394
1 files changed, 94 insertions, 0 deletions
diff --git a/doc/ManageGeom.3 b/doc/ManageGeom.3
new file mode 100644
index 0000000..67ca5b4
--- /dev/null
+++ b/doc/ManageGeom.3
@@ -0,0 +1,94 @@
+'\"
+'\" Copyright (c) 1990-1994 The Regents of the University of California.
+'\" Copyright (c) 1994-1996 Sun Microsystems, Inc.
+'\"
+'\" See the file "license.terms" for information on usage and redistribution
+'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
+'\"
+'\" SCCS: @(#) ManageGeom.3 1.18 96/08/27 13:21:30
+'\"
+.so man.macros
+.TH Tk_ManageGeometry 3 4.0 Tk "Tk Library Procedures"
+.BS
+.SH NAME
+Tk_ManageGeometry \- arrange to handle geometry requests for a window
+.SH SYNOPSIS
+.nf
+\fB#include <tk.h>\fR
+.sp
+\fBTk_ManageGeometry\fR(\fItkwin, mgrPtr, clientData\fR)
+.SH ARGUMENTS
+.AS Tk_GeometryProc clientData
+.AP Tk_Window tkwin in
+Token for window to be managed.
+.AP Tk_GeomMgr *mgrPtr in
+Pointer to data structure containing information about the
+geometry manager, or NULL to indicate that \fItkwin\fR's geometry
+shouldn't be managed anymore.
+The data structure pointed to by \fImgrPtr\fR must be static:
+Tk keeps a reference to it as long as the window is managed.
+.AP ClientData clientData in
+Arbitrary one-word value to pass to geometry manager callbacks.
+.BE
+
+.SH DESCRIPTION
+.PP
+\fBTk_ManageGeometry\fR arranges for a particular geometry manager,
+described by the \fImgrPtr\fR argument, to control the geometry
+of a particular slave window, given by \fItkwin\fR.
+If \fItkwin\fR was previously managed by some other geometry manager,
+the previous manager loses control in favor of the new one.
+If \fImgrPtr\fR is NULL, geometry management is cancelled for
+\fItkwin\fR.
+.PP
+The structure pointed to by \fImgrPtr\fR contains information about
+the geometry manager:
+.CS
+typedef struct {
+ char *\fIname\fR;
+ Tk_GeomRequestProc *\fIrequestProc\fR;
+ Tk_GeomLostSlaveProc *\fIlostSlaveProc\fR;
+} Tk_GeomMgr;
+.CE
+The \fIname\fR field is the textual name for the geometry manager,
+such as \fBpack\fR or \fBplace\fR; this value will be returned
+by the command \fBwinfo manager\fR.
+.PP
+\fIrequestProc\fR is a procedure in the geometry manager that
+will be invoked whenever \fBTk_GeometryRequest\fR is called by the
+slave to change its desired geometry.
+\fIrequestProc\fR should have arguments and results that match the
+type \fBTk_GeomRequestProc\fR:
+.CS
+typedef void Tk_GeomRequestProc(
+ ClientData \fIclientData\fR,
+ Tk_Window \fItkwin\fR);
+.CE
+The parameters to \fIrequestProc\fR will be identical to the
+corresponding parameters passed to \fBTk_ManageGeometry\fR.
+\fIclientData\fR usually points to a data
+structure containing application-specific information about
+how to manage \fItkwin\fR's geometry.
+.PP
+The \fIlostSlaveProc\fR field of \fImgrPtr\fR points to another
+procedure in the geometry manager.
+Tk will invoke \fIlostSlaveProc\fR if some other manager
+calls \fBTk_ManageGeometry\fR to claim
+\fItkwin\fR away from the current geometry manager.
+\fIlostSlaveProc\fR is not invoked if \fBTk_ManageGeometry\fR is
+called with a NULL value for \fImgrPtr\fR (presumably the current
+geometry manager has made this call, so it already knows that the
+window is no longer managed), nor is it called if \fImgrPtr\fR
+is the same as the window's current geometry manager.
+\fIlostSlaveProc\fR should have
+arguments and results that match the following prototype:
+.CS
+typedef void Tk_GeomLostSlaveProc(
+ ClientData \fIclientData\fR,
+ Tk_Window \fItkwin\fR);
+.CE
+The parameters to \fIlostSlaveProc\fR will be identical to the
+corresponding parameters passed to \fBTk_ManageGeometry\fR.
+
+.SH KEYWORDS
+callback, geometry, managed, request, unmanaged