1XConfigureWindow(3X11)          XLIB FUNCTIONS          XConfigureWindow(3X11)
2
3
4

NAME

6       XConfigureWindow, XMoveWindow, XResizeWindow, XMoveResizeWindow,
7       XSetWindowBorderWidth, XWindowChanges - configure windows and window
8       changes structure
9

SYNTAX

11       int XConfigureWindow(Display *display, Window w, unsigned value_mask,
12              XWindowChanges *changes);
13
14       int XMoveWindow(Display *display, Window w, int x, y);
15
16       int XResizeWindow(Display *display, Window w, unsigned width, unsigned
17              height);
18
19       int XMoveResizeWindow(Display *display, Window w, int x, int y,
20              unsigned width, unsigned height);
21
22       int XSetWindowBorderWidth(Display *display, Window w, unsigned width);
23

ARGUMENTS

25       display   Specifies the connection to the X server.
26
27       value_mask
28                 Specifies which values are to be set using information in the
29                 values structure.  This mask is the bitwise inclusive OR of
30                 the valid configure window values bits.
31
32       values    Specifies the XWindowChanges structure.
33
34       w         Specifies the window to be reconfigured, moved, or resized..
35
36       width     Specifies the width of the window border.
37
38       width
39       height    Specify the width and height, which are the interior dimen‐
40                 sions of the window.
41
42
43
44       x
45       y         Specify the x and y coordinates, which define the new loca‐
46                 tion of the top-left pixel of the window's border or the win‐
47                 dow itself if it has no border or define the new position of
48                 the window relative to its parent.
49

DESCRIPTION

51       The XConfigureWindow function uses the values specified in the XWin‐
52       dowChanges structure to reconfigure a window's size, position, border,
53       and stacking order.  Values not specified are taken from the existing
54       geometry of the window.
55
56       If a sibling is specified without a stack_mode or if the window is not
57       actually a sibling, a BadMatch error results.  Note that the computa‐
58       tions for BottomIf, TopIf, and Opposite are performed with respect to
59       the window's final geometry (as controlled by the other arguments
60       passed to XConfigureWindow), not its initial geometry.  Any backing
61       store contents of the window, its inferiors, and other newly visible
62       windows are either discarded or changed to reflect the current screen
63       contents (depending on the implementation).
64
65       XConfigureWindow can generate BadMatch, BadValue, and BadWindow errors.
66
67       The XMoveWindow function moves the specified window to the specified x
68       and y coordinates, but it does not change the window's size, raise the
69       window, or change the mapping state of the window.  Moving a mapped
70       window may or may not lose the window's contents depending on if the
71       window is obscured by nonchildren and if no backing store exists.  If
72       the contents of the window are lost, the X server generates Expose
73       events.  Moving a mapped window generates Expose events on any formerly
74       obscured windows.
75
76       If the override-redirect flag of the window is False and some other
77       client has selected SubstructureRedirectMask on the parent, the X
78       server generates a ConfigureRequest event, and no further processing is
79       performed.  Otherwise, the window is moved.
80
81       XMoveWindow can generate a BadWindow error.
82
83       The XResizeWindow function changes the inside dimensions of the speci‐
84       fied window, not including its borders.  This function does not change
85       the window's upper-left coordinate or the origin and does not restack
86       the window.  Changing the size of a mapped window may lose its contents
87       and generate Expose events.  If a mapped window is made smaller, chang‐
88       ing its size generates Expose events on windows that the mapped window
89       formerly obscured.
90
91       If the override-redirect flag of the window is False and some other
92       client has selected SubstructureRedirectMask on the parent, the X
93       server generates a ConfigureRequest event, and no further processing is
94       performed.  If either width or height is zero, a BadValue error
95       results.
96
97       XResizeWindow can generate BadValue and BadWindow errors.
98
99       The XMoveResizeWindow function changes the size and location of the
100       specified window without raising it.  Moving and resizing a mapped win‐
101       dow may generate an Expose event on the window.  Depending on the new
102       size and location parameters, moving and resizing a window may generate
103       Expose events on windows that the window formerly obscured.
104
105       If the override-redirect flag of the window is False and some other
106       client has selected SubstructureRedirectMask on the parent, the X
107       server generates a ConfigureRequest event, and no further processing is
108       performed.  Otherwise, the window size and location are changed.
109
110       XMoveResizeWindow can generate BadValue and BadWindow errors.
111
112       The XSetWindowBorderWidth function sets the specified window's border
113       width to the specified width.
114
115       XSetWindowBorderWidth can generate a BadWindow error.
116

STRUCTURES

118       The XWindowChanges structure contains:
119
120       /∗ Configure window value mask bits */
121
122       #define   CWX                         (1<<0)
123       #define   CWY                         (1<<1)
124       #define   CWWidth                     (1<<2)
125       #define   CWHeight                    (1<<3)
126       #define   CWBorderWidth               (1<<4)
127       #define   CWSibling                   (1<<5)
128       #define   CWStackMode                 (1<<6)
129       /∗ Values */
130
131       typedef struct {
132            int x, y;
133            int width, height;
134            int border_width;
135            Window sibling;
136            int stack_mode;
137       } XWindowChanges;
138
139       The x and y members are used to set the window's x and y coordinates,
140       which are relative to the parent's origin and indicate the position of
141       the upper-left outer corner of the window.  The width and height mem‐
142       bers are used to set the inside size of the window, not including the
143       border, and must be nonzero, or a BadValue error results.  Attempts to
144       configure a root window have no effect.
145
146       The border_width member is used to set the width of the border in pix‐
147       els.  Note that setting just the border width leaves the outer-left
148       corner of the window in a fixed position but moves the absolute posi‐
149       tion of the window's origin.  If you attempt to set the border-width
150       attribute of an InputOnly window nonzero, a BadMatch error results.
151
152       The sibling member is used to set the sibling window for stacking oper‐
153       ations.  The stack_mode member is used to set how the window is to be
154       restacked and can be set to Above, Below, TopIf, BottomIf, or Opposite.
155

DIAGNOSTICS

157       BadMatch  An InputOnly window is used as a Drawable.
158
159       BadMatch  Some argument or pair of arguments has the correct type and
160                 range but fails to match in some other way required by the
161                 request.
162
163       BadValue  Some numeric value falls outside the range of values accepted
164                 by the request.  Unless a specific range is specified for an
165                 argument, the full range defined by the argument's type is
166                 accepted.  Any argument defined as a set of alternatives can
167                 generate this error.
168
169       BadWindow A value for a Window argument does not name a defined Window.
170

SEE ALSO

172       XChangeWindowAttributes(3X11), XCreateWindow(3X11), XDestroyWin‐
173       dow(3X11), XMapWindow(3X11), XRaiseWindow(3X11), XUnmapWindow(3X11)
174       Xlib - C Language X Interface
175
176
177
178X Version 11                     libX11 1.0.3           XConfigureWindow(3X11)
Impressum