1/* 2 * Icon Manager includes 3 * 4 * 5 * Copyright 1989 Massachusetts Institute of Technology 6 * 7 * $XConsortium: iconmgr.h,v 1.11 89/12/10 17:47:02 jim Exp $ 8 * 9 * 09-Mar-89 Tom LaStrange File Created 10 * 11 * Copyright 1992 Claude Lecommandeur. 12 */ 13 14#ifndef _CTWM_ICONMGR_H 15#define _CTWM_ICONMGR_H 16 17struct WList { 18 struct WList *next; 19 struct WList *prev; 20 struct WList *nextv; /* pointer to the next virtual Wlist C.L. */ 21 struct TwmWindow *twm; 22 struct IconMgr *iconmgr; 23 Window w; 24 Window icon; 25 int x, y, width, height; 26 int row, col; 27 int me; 28 ColorPair cp; 29 Pixel highlight; 30 Pixmap iconifypm; 31 unsigned top, bottom; 32 bool active; 33 bool down; 34}; 35 36struct IconMgr { 37 struct IconMgr *next; ///< Next iconmgr in this workspace 38 struct IconMgr *prev; ///< Prev iconmgr in this workspace 39 struct IconMgr *lasti; ///< Last iconmgr in this workspace 40 struct IconMgr *nextv; ///< Next workspace's icon manager head 41 42 struct WList *first; /* first window in the list */ 43 struct WList *last; /* last window in the list */ 44 struct WList *active; /* the active entry */ 45 TwmWindow *twm_win; /* back pointer to the new parent */ 46 struct ScreenInfo *scr; /* the screen this thing is on */ 47 int vScreen; /* the virtual screen this thing is on */ 48 Window w; /* this icon manager window */ 49 char *geometry; /* geometry string */ 50 char *name; 51 char *icon_name; 52 int x, y, width, height; 53 int columns, cur_rows, cur_columns; 54 int count; 55}; 56 57extern WList *DownIconManager; 58 59void CreateIconManagers(void); 60IconMgr *AllocateIconManager(char *name, char *geom, char *icon_name, 61 int columns); 62void AllocateOtherIconManagers(void); 63void MoveIconManager(int dir); 64void MoveMappedIconManager(int dir); 65void JumpIconManager(int dir); 66WList *AddIconManager(TwmWindow *tmp_win); 67void InsertInIconManager(IconMgr *ip, WList *tmp, TwmWindow *tmp_win); 68void RemoveFromIconManager(IconMgr *ip, WList *tmp); 69void RemoveIconManager(TwmWindow *tmp_win); 70void CurrentIconManagerEntry(WList *current); 71void ActiveIconManager(WList *active); 72void NotActiveIconManager(WList *active); 73void DrawIconManagerBorder(WList *tmp, bool fill); 74void SortIconManager(IconMgr *ip); 75void PackIconManager(IconMgr *ip); 76void PackIconManagers(void); 77void dump_iconmanager(IconMgr *mgr, char *label); 78void DrawIconManagerIconName(TwmWindow *tmp_win); 79void ShowIconifiedIcon(TwmWindow *tmp_win); 80 81 82/* Spacing between the text and the outer border. */ 83#define ICON_MGR_IBORDER 3 84/* Thickness of the outer border (3d or not). */ 85#define ICON_MGR_OBORDER \ 86 (Scr->use3Diconmanagers ? Scr->IconManagerShadowDepth : 2) 87 88 89#endif /* _CTWM_ICONMGR_H */ 90