~ctwm/ctwm/trunk

503.1.62 by Matthew Fuller
Pull piles of occupation handling out of workmgr.c and into a new
1
/*
2
 * Occupation handling routines
3
 */
4
5
#ifndef _CTWM_OCCUPATION_H
6
#define _CTWM_OCCUPATION_H
7
8
9
struct OccupyWindow {
10
	Window        w;
11
	TwmWindow     *twm_win;
12
	char          *geometry;
13
	Window        *obuttonw;
14
	Window        OK, cancel, allworkspc;
15
	int           width, height;
514.1.3 by Matthew Fuller
Stash up the minimum size for the window and bail out of Resize early
16
	int           minwidth, minheight;
503.1.62 by Matthew Fuller
Pull piles of occupation handling out of workmgr.c and into a new
17
	char          *name;
18
	char          *icon_name;
19
	int           lines, columns;
20
	int           hspace, vspace;         /* space between workspaces */
21
	int           bwidth, bheight;
22
	int           owidth;                 /* oheight == bheight */
23
	ColorPair     cp;
24
	MyFont        font;
25
	int           tmpOccupation;
26
};
27
28
503.1.102 by Matthew Fuller
Rearrange the functions in occupation.c so they're ordered and grouped
29
/* Setting occupation bits */
503.1.62 by Matthew Fuller
Pull piles of occupation handling out of workmgr.c and into a new
30
void SetupOccupation(TwmWindow *twm_win, int occupation_hint);
31
void AddToWorkSpace(char *wname, TwmWindow *twm_win);
32
void RemoveFromWorkSpace(char *wname, TwmWindow *twm_win);
33
void ToggleOccupation(char *wname, TwmWindow *twm_win);
503.1.102 by Matthew Fuller
Rearrange the functions in occupation.c so they're ordered and grouped
34
void MoveToNextWorkSpace(VirtualScreen *vs, TwmWindow *twm_win);
35
void MoveToPrevWorkSpace(VirtualScreen *vs, TwmWindow *twm_win);
36
void MoveToNextWorkSpaceAndFollow(VirtualScreen *vs, TwmWindow *twm_win);
37
void MoveToPrevWorkSpaceAndFollow(VirtualScreen *vs, TwmWindow *twm_win);
503.1.62 by Matthew Fuller
Pull piles of occupation handling out of workmgr.c and into a new
38
void WmgrRedoOccupation(TwmWindow *win);
39
void WMgrRemoveFromCurrentWorkSpace(VirtualScreen *vs, TwmWindow *win);
40
void WMgrAddToCurrentWorkSpaceAndWarp(VirtualScreen *vs, char *winname);
503.1.102 by Matthew Fuller
Rearrange the functions in occupation.c so they're ordered and grouped
41
void OccupyAll(TwmWindow *twm_win);
503.1.62 by Matthew Fuller
Pull piles of occupation handling out of workmgr.c and into a new
42
503.1.102 by Matthew Fuller
Rearrange the functions in occupation.c so they're ordered and grouped
43
/* Occupation editing window */
503.1.62 by Matthew Fuller
Pull piles of occupation handling out of workmgr.c and into a new
44
void CreateOccupyWindow(void);
503.1.102 by Matthew Fuller
Rearrange the functions in occupation.c so they're ordered and grouped
45
void ResizeOccupyWindow(TwmWindow *win);
503.1.62 by Matthew Fuller
Pull piles of occupation handling out of workmgr.c and into a new
46
void PaintOccupyWindow(void);
503.1.102 by Matthew Fuller
Rearrange the functions in occupation.c so they're ordered and grouped
47
void OccupyHandleButtonEvent(XEvent *event);
48
void Occupy(TwmWindow *twm_win);
503.1.62 by Matthew Fuller
Pull piles of occupation handling out of workmgr.c and into a new
49
503.1.102 by Matthew Fuller
Rearrange the functions in occupation.c so they're ordered and grouped
50
/* Backend/util */
51
void ChangeOccupation(TwmWindow *tmp_win, int newoccupation);
52
bool AddToClientsList(char *workspace, char *client);
53
unsigned int GetMaskFromProperty(unsigned char *_prop, unsigned long len);
503.1.62 by Matthew Fuller
Pull piles of occupation handling out of workmgr.c and into a new
54
int GetPropertyFromMask(unsigned int mask, char **prop);
55
503.1.102 by Matthew Fuller
Rearrange the functions in occupation.c so they're ordered and grouped
56
57
58
/* Various other code needs to look at this */
503.1.62 by Matthew Fuller
Pull piles of occupation handling out of workmgr.c and into a new
59
extern int fullOccupation;
60
61
/* Hopefully temporary; x-ref comment in .c */
62
extern TwmWindow *occupyWin;
63
64
#endif // _CTWM_OCCUPATION_H