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

NAME

8       Tk_SetClass, Tk_Class - set or retrieve a window's class
9

SYNOPSIS

11       #include <tk.h>
12
13       Tk_SetClass(tkwin, class)
14
15       Tk_Uid
16       Tk_Class(tkwin)
17

ARGUMENTS

19       Tk_Window tkwin (in)           Token for window.
20
21       char *class (in)               New class name for window.
22_________________________________________________________________
23
24

DESCRIPTION

26       Tk_SetClass  is  called  to associate a class with a particular window.
27       The class string identifies the type of the window;  all  windows  with
28       the same general class of behavior (button, menu, etc.) should have the
29       same class.  By convention all class names start with a capital letter,
30       and there exists a Tcl command with the same name as each class (except
31       all in lower-case) which can be used to create and  manipulate  windows
32       of that class.  A window's class string is initialized to NULL when the
33       window is created.
34
35       For main windows, Tk automatically propagates the name and class to the
36       WM_CLASS  property used by window managers.  This happens either when a
37       main window is actually created (e.g. in Tk_MakeWindowExist),  or  when
38       Tk_SetClass  is  called,  whichever occurs later.  If a main window has
39       not been assigned a class then Tk will not set  the  WM_CLASS  property
40       for the window.
41
42       Tk_Class  is  a  macro that returns the current value of tkwin's class.
43       The value is returned as a Tk_Uid, which may be used just like a string
44       pointer  but  also  has  the properties of a unique identifier (see the
45       manual entry for Tk_GetUid for details).  If tkwin  has  not  yet  been
46       given a class, then Tk_Class will return NULL.
47
48

KEYWORDS

50       class, unique identifier, window, window manager
51
52
53
54Tk                                                              Tk_SetClass(3)
Impressum