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
29

DESCRIPTION

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

KEYWORDS

48       colormap, depth, visual
49
50
51
52Tk                                    4.0                Tk_SetWindowVisual(3)
Impressum