1Tk_SetWindowVisual(3)        Tk Library Procedures       Tk_SetWindowVisual(3)
2
3
4
5______________________________________________________________________________
6

NAME

8       Tk_SetWindowVisual - change visual characteristics of window
9

SYNOPSIS

11       #include <tk.h>
12
13       int
14       Tk_SetWindowVisual(tkwin, visual, depth, colormap)
15

ARGUMENTS

17       Tk_Window tkwin (in)                 Token for window.
18
19       Visual *visual (in)                  New visual type to use for tkwin.
20
21       int depth (in)                       Number  of  bits per pixel desired
22                                            for tkwin.
23
24       Colormap colormap (in)               New colormap for tkwin, which must
25                                            be   compatible  with  visual  and
26                                            depth.
27______________________________________________________________________________
28

DESCRIPTION

30       When Tk creates a new window it assigns it the default  visual  charac‐
31       teristics  (visual,  depth,  and  colormap) for its screen.  Tk_SetWin‐
32       dowVisual may be called to change  them.   Tk_SetWindowVisual  must  be
33       called  before  the  window has actually been created in X (e.g. before
34       Tk_MapWindow or Tk_MakeWindowExist has been invoked  for  the  window).
35       The  safest thing is to call Tk_SetWindowVisual immediately after call‐
36       ing  Tk_CreateWindow.   If  tkwin  has  already  been  created   before
37       Tk_SetWindowVisual  is  called  then it returns 0 and does not make any
38       changes;  otherwise it returns 1 to signify  that  the  operation  com‐
39       pleted successfully.
40
41       Note:   Tk_SetWindowVisual  should  not  be  called if you just want to
42       change a window's colormap without changing its visual or  depth;  call
43       Tk_SetWindowColormap instead.
44

KEYWORDS

46       colormap, depth, visual
47
48
49
50Tk                                    4.0                Tk_SetWindowVisual(3)
Impressum