iconmgr.h revision 3e747e6d
1/*
2 *
3Copyright 1989, 1998  The Open Group
4
5Permission to use, copy, modify, distribute, and sell this software and its
6documentation for any purpose is hereby granted without fee, provided that
7the above copyright notice appear in all copies and that both that
8copyright notice and this permission notice appear in supporting
9documentation.
10
11The above copyright notice and this permission notice shall be included in
12all copies or substantial portions of the Software.
13
14THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE
17OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
18AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
19CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
20
21Except as contained in this notice, the name of The Open Group shall not be
22used in advertising or otherwise to promote the sale, use or other dealings
23in this Software without prior written authorization from The Open Group.
24 * */
25/* $XFree86: xc/programs/twm/iconmgr.h,v 1.5 2001/08/27 21:11:39 dawes Exp $ */
26
27/***********************************************************************
28 *
29 * $Xorg: iconmgr.h,v 1.4 2001/02/09 02:05:36 xorgcvs Exp $
30 *
31 * Icon Manager includes
32 *
33 * 09-Mar-89 Tom LaStrange		File Created
34 *
35 ***********************************************************************/
36
37#ifndef _ICONMGR_
38#define _ICONMGR_
39
40typedef struct WList
41{
42    struct WList *next;
43    struct WList *prev;
44    struct TwmWindow *twm;
45    struct IconMgr *iconmgr;
46    Window w;
47    Window icon;
48    int x, y, width, height;
49    int row, col;
50    int me;
51    Pixel fore, back, highlight;
52    unsigned top, bottom;
53    short active;
54    short down;
55} WList;
56
57typedef struct IconMgr
58{
59    struct IconMgr *next;		/* pointer to the next icon manager */
60    struct IconMgr *prev;		/* pointer to the previous icon mgr */
61    struct IconMgr *lasti;		/* pointer to the last icon mgr */
62    struct WList *first;		/* first window in the list */
63    struct WList *last;			/* last window in the list */
64    struct WList *active;		/* the active entry */
65    TwmWindow *twm_win;			/* back pointer to the new parent */
66    struct ScreenInfo *scr;		/* the screen this thing is on */
67    Window w;				/* this icon manager window */
68    char *geometry;			/* geometry string */
69    char *name;
70    char *icon_name;
71    int x, y, width, height;
72    int columns, cur_rows, cur_columns;
73    int count;
74} IconMgr;
75
76extern int iconmgr_textx;
77extern WList *DownIconManager;
78extern int iconifybox_width, iconifybox_height;
79
80extern void ActiveIconManager ( WList *active );
81extern WList *AddIconManager ( TwmWindow *tmp_win );
82extern IconMgr *AllocateIconManager ( char *name, char *icon_name, char *geom, int columns );
83extern void CreateIconManagers ( void );
84extern void DrawIconManagerBorder ( WList *tmp );
85extern void InsertInIconManager ( IconMgr *ip, WList *tmp, TwmWindow *tmp_win );
86extern void JumpIconManager ( int dir );
87extern void MoveIconManager ( int dir );
88extern void NotActiveIconManager ( WList *active );
89extern void PackIconManager ( IconMgr *ip );
90extern void RemoveFromIconManager ( IconMgr *ip, WList *tmp );
91extern void RemoveIconManager ( TwmWindow *tmp_win );
92extern void SortIconManager ( IconMgr *ip );
93
94#endif /* _ICONMGR_ */
95