1TICKIT_WINDOW_NEW(3) Library Functions Manual TICKIT_WINDOW_NEW(3)
2
3
4
6 tickit_window_new - create a new sub-window
7
9 #include <tickit.h>
10
11 TickitWindow *tickit_window_new(TickitWindow *parent, TickitRect rect,
12 TickitWindowFlags flags);
13
14 Link with -ltickit.
15
17 tickit_window_new() creates a new sub-window as a child of the given
18 parent, using the given rectangle as its initial geometry relative to
19 its parent. The flags argument is a bitmask of flags influencing the
20 initial behaviour of the child window.
21
22 TICKIT_WINDOW_HIDDEN
23 The new child window will be created in the hidden state ini‐
24 tially. No pending expose event will occur because of it. It can
25 later be shown by calling tickit_window_show(3).
26
27 TICKIT_WINDOW_LOWEST
28 Normally the most recently-added child window is ordered at the
29 top of the list in its parent, making it appear front-most in
30 the display. This flag causes it to be added at the bottom of
31 the list, appearing lowest-most instead.
32
33 TICKIT_WINDOW_ROOT_PARENT
34 The new child window will have the root window of the window
35 tree as its parent, instead of the given window. The position
36 will be automatically adjusted so that the new window still
37 appears at the given geometry position relative to the window
38 passed as the parent argument.
39
40 TICKIT_WINDOW_STEAL_INPUT
41 The new child window will initially be set to steal input
42 events; see tickit_window_set_steal_input(3).
43
44 This flag is not useful when combined with TICKIT_WINDOW_LOWEST,
45 as the input-stealing behaviour only applies while the window is
46 front-most within its parent.
47
48 TICKIT_WINDOW_POPUP
49 A convenient shortcut to specifying both TICKIT_WINDOW_ROOT_PAR‐
50 ENT and TICKIT_WINDOW_STEAL_INPUT flags. This is useful for
51 implementing popup dialog windows, menus, and other such UI be‐
52 haviours.
53
54 The reference count of a newly-constructed window instance will be one.
55 This can be incremented or decremented using tickit_window_ref(3) and
56 tickit_window_unref(3). When its reference count reaches zero it is
57 destroyed.
58
60 If successful, tickit_window_new() returns a pointer to the new
61 instance.
62
64 tickit_window_new_root(3), tickit_window_bind_event(3), tickit_win‐
65 dow_expose(3), tickit_window_close(3), tickit_window(7), tickit(7)
66
67
68
69 TICKIT_WINDOW_NEW(3)