OSDN Git Service

* cgen-asm.in: Update copyright year.
[pf3gnuchains/pf3gnuchains3x.git] / tk / doc / GeomReq.3
1 '\"
2 '\" Copyright (c) 1990-1994 The Regents of the University of California.
3 '\" Copyright (c) 1994-1996 Sun Microsystems, Inc.
4 '\"
5 '\" See the file "license.terms" for information on usage and redistribution
6 '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
7 '\" 
8 '\" 
9 '\" RCS: @(#) $Id$
10 '\" 
11 .so man.macros
12 .TH Tk_GeometryRequest 3 "8.4" Tk "Tk Library Procedures"
13 .BS
14 .SH NAME
15 Tk_GeometryRequest, Tk_SetMinimumRequestSize, Tk_SetInternalBorder, Tk_SetInternalBorderEx \- specify desired geometry or internal border for a window
16 .SH SYNOPSIS
17 .nf
18 \fB#include <tk.h>\fR
19 .sp
20 \fBTk_GeometryRequest\fR(\fItkwin, reqWidth, reqHeight\fR)
21 .sp
22 \fBTk_SetMinimumRequestSize\fR(\fItkwin, minWidth, minHeight\fR)
23 .sp
24 \fBTk_SetInternalBorder\fR(\fItkwin, width\fR)
25 .sp
26 \fBTk_SetInternalBorderEx\fR(\fItkwin, left, right, top, bottom\fR)
27 .SH ARGUMENTS
28 .AS baseHeight clientData
29 .AP Tk_Window tkwin in
30 Window for which geometry is being requested.
31 .AP int reqWidth in
32 Desired width for \fItkwin\fR, in pixel units.
33 .AP int reqHeight in
34 Desired height for \fItkwin\fR, in pixel units.
35 .AP int minWidth in
36 Desired minimum requested width for \fItkwin\fR, in pixel units.
37 .AP int minHeight in
38 Desired minimum requested height for \fItkwin\fR, in pixel units.
39 .AP int width in
40 Space to leave for internal border for \fItkwin\fR, in pixel units.
41 .AP int left in
42 Space to leave for left side of internal border for \fItkwin\fR, in pixel units.
43 .AP int right in
44 Space to leave for right side of internal border for \fItkwin\fR, in pixel units.
45 .AP int top in
46 Space to leave for top side of internal border for \fItkwin\fR, in pixel units.
47 .AP int bottom in
48 Space to leave for bottom side of internal border for \fItkwin\fR, in pixel units.
49 .BE
50
51 .SH DESCRIPTION
52 .PP
53 \fBTk_GeometryRequest\fR is called by widget code to indicate its
54 preference for the dimensions of a particular window.  The arguments
55 to \fBTk_GeometryRequest\fR are made available to the geometry
56 manager for the window, which then decides on the actual geometry
57 for the window.  Although geometry managers generally try to satisfy
58 requests made to \fBTk_GeometryRequest\fR, there is no guarantee that
59 this will always be possible.  Widget code should not assume that
60 a geometry request will be satisfied until it receives a
61 \fBConfigureNotify\fR event indicating that the geometry change has
62 occurred.  Widget code should never call procedures like
63 \fBTk_ResizeWindow\fR directly.  Instead, it should invoke
64 \fBTk_GeometryRequest\fR and leave the final geometry decisions to
65 the geometry manager.
66 .PP
67 If \fItkwin\fR is a top-level window, then the geometry information
68 will be passed to the window manager using the standard ICCCM protocol.
69 .PP
70 \fBTk_SetInternalBorder\fR is called by widget code to indicate that
71 the widget has an internal border.  This means that the widget draws
72 a decorative border inside the window instead of using the standard
73 X borders, which are external to the window's area.  For example,
74 internal borders are used to draw 3-D effects.  \fIWidth\fR
75 specifies the width of the border in pixels.  Geometry managers will
76 use this information to avoid placing any children of \fItkwin\fR
77 overlapping the outermost \fIwidth\fR pixels of \fItkwin\fR's area.
78 .PP
79 \fBTk_SetInternalBorderEx\fR works like \fBTk_SetInternalBorder\fR
80 but lets you specify different widths for different sides of the window.
81 .PP
82 \fBTk_SetMinimumRequestSize\fR is called by widget code to indicate
83 that a geometry manager should request at least this size for the
84 widget.  This allows a widget to have some control over its size when
85 a propagating geometry manager is used inside it.
86 .PP
87 The information specified in calls to \fBTk_GeometryRequest\fR,
88 \fBTk_SetMinimumRequestSize\fR, \fBTk_SetInternalBorder\fR and
89 \fBTk_SetInternalBorderEx\fR can be retrieved using the macros
90 \fBTk_ReqWidth\fR, \fBTk_ReqHeight\fR, \fBTk_MinReqWidth\fR,
91 \fBTk_MinReqHeight\fR, \fBTk_MinReqWidth\fR, \fBTk_InternalBorderLeft\fR,
92 \fBTk_InternalBorderRight\fR, \fBTk_InternalBorderTop\fR and
93 \fBTk_InternalBorderBottom\fR.
94 See the \fBTk_WindowId\fR manual entry for details.
95
96 .SH KEYWORDS
97 geometry, request