📄 managegeom.3
字号:
'\"'\" 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 NAMETk_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 inToken for window to be managed..AP Tk_GeomMgr *mgrPtr inPointer to data structure containing information about thegeometry manager, or NULL to indicate that \fItkwin\fR's geometryshouldn'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 inArbitrary 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 geometryof 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..PPThe structure pointed to by \fImgrPtr\fR contains information aboutthe geometry manager:.CStypedef struct { char *\fIname\fR; Tk_GeomRequestProc *\fIrequestProc\fR; Tk_GeomLostSlaveProc *\fIlostSlaveProc\fR;} Tk_GeomMgr;.CEThe \fIname\fR field is the textual name for the geometry manager,such as \fBpack\fR or \fBplace\fR; this value will be returnedby the command \fBwinfo manager\fR..PP\fIrequestProc\fR is a procedure in the geometry manager thatwill be invoked whenever \fBTk_GeometryRequest\fR is called by theslave to change its desired geometry.\fIrequestProc\fR should have arguments and results that match thetype \fBTk_GeomRequestProc\fR:.CStypedef void Tk_GeomRequestProc( ClientData \fIclientData\fR, Tk_Window \fItkwin\fR);.CEThe parameters to \fIrequestProc\fR will be identical to thecorresponding parameters passed to \fBTk_ManageGeometry\fR.\fIclientData\fR usually points to a datastructure containing application-specific information abouthow to manage \fItkwin\fR's geometry..PPThe \fIlostSlaveProc\fR field of \fImgrPtr\fR points to anotherprocedure in the geometry manager.Tk will invoke \fIlostSlaveProc\fR if some other managercalls \fBTk_ManageGeometry\fR to claim\fItkwin\fR away from the current geometry manager.\fIlostSlaveProc\fR is not invoked if \fBTk_ManageGeometry\fR iscalled with a NULL value for \fImgrPtr\fR (presumably the currentgeometry manager has made this call, so it already knows that thewindow is no longer managed), nor is it called if \fImgrPtr\fRis the same as the window's current geometry manager.\fIlostSlaveProc\fR should havearguments and results that match the following prototype:.CStypedef void Tk_GeomLostSlaveProc( ClientData \fIclientData\fR, Tk_Window \fItkwin\fR);.CEThe parameters to \fIlostSlaveProc\fR will be identical to thecorresponding parameters passed to \fBTk_ManageGeometry\fR..SH KEYWORDScallback, geometry, managed, request, unmanaged
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -