31#include <X11/extensions/shape.h>
34#include "ctwm_atoms.h"
98static Window CreateCaptiveRootWindow(
int x,
int y,
99 unsigned int width,
unsigned int height);
102 unsigned int crootw,
unsigned int crooth);
172 int numManaged, firstscrn, lastscrn;
174 bool takeover =
true;
175 bool nodpyok =
false;
177 setlocale(LC_ALL,
"");
204 if(
CLarg.is_captive) {
228 Home = getenv(
"HOME");
247 XtToolkitInitialize();
256 NULL, 0, &zero, NULL);
260 if(!
dpy && !nodpyok) {
261 fprintf(stderr,
"%s: unable to open display \"%s\"\n",
266 if(
dpy && fcntl(ConnectionNumber(
dpy), F_SETFD, FD_CLOEXEC) == -1) {
268 "%s: unable to mark display connection as close-on-exec\n",
275 fprintf(stderr,
"%s: Can't connect to X server, proceeding anyway...\n",
283 if(
CLarg.restore_filename) {
301 XInternAtoms(
dpy, XCTWMAtomNames, NUM_CTWM_XATOMS, False,
XCTWMAtom);
328 if(
CLarg.MultiScreen) {
333 firstscrn = lastscrn = 0;
336 firstscrn = lastscrn = DefaultScreen(
dpy);
342 fprintf(stderr,
"%s: Unable to allocate memory for screen list, exiting.\n",
365 for(
int scrnum = firstscrn ; scrnum <= lastscrn; scrnum++) {
368 unsigned int crootw, crooth;
380 else if(
CLarg.is_captive) {
382 XWindowAttributes wa;
383 if(
CLarg.capwin && XGetWindowAttributes(
dpy,
CLarg.capwin, &wa)) {
385 croot =
CLarg.capwin;
388 XTranslateCoordinates(
dpy,
CLarg.capwin, wa.root, 0, 0, &crootx, &crooty,
395 crootx = crooty = 100;
398 croot = CreateCaptiveRootWindow(crootx, crooty, crootw, crooth);
408 croot = RootWindow(
dpy, scrnum);
409 crootw = DisplayWidth(
dpy, scrnum);
410 crooth = DisplayHeight(
dpy, scrnum);
426 crootx, crooty, crootw, crooth);
429 "%s: unable to allocate memory for ScreenInfo structure"
436 Scr->ShowWelcomeWindow =
CLarg.ShowWelcomeWindow;
449 if(
Scr->Layout == NULL) {
460 fprintf(stderr,
"Layout: ");
464 fprintf(stderr,
"Error: No monitors found on screen %d!\n", scrnum);
472 Scr->d_depth = DefaultDepth(
dpy, scrnum);
473 Scr->d_visual = DefaultVisual(
dpy, scrnum);
474 Scr->RealRoot = RootWindow(
dpy, scrnum);
477 Screen *tscr = ScreenOfDisplay(
dpy, scrnum);
478 Scr->mm_w = tscr->mwidth;
479 Scr->mm_h = tscr->mheight;
484 Scr->d_visual = calloc(1,
sizeof(Visual));
485 Scr->d_visual->bits_per_rgb = 8;
486 Scr->d_visual->class = TrueColor;
491 Scr->XORvalue = (((
unsigned long) 1) <<
Scr->d_depth) - 1;
496 if(
CLarg.is_captive) {
497 Scr->CaptiveRoot = croot;
499 if(
Scr->captivename) {
500 XmbSetWMProperties(
dpy, croot,
501 Scr->captivename,
Scr->captivename,
502 NULL, 0, NULL, NULL, NULL);
513 Scr->RootColormaps.number_cwins = 1;
517 Scr->RootColormaps.cwins[0]->visibility = VisibilityPartiallyObscured;
520 Scr->cmapInfo.cmaps = NULL;
522 Scr->cmapInfo.maxCmaps = MaxCmapsOfScreen(ScreenOfDisplay(
dpy,
525 Scr->cmapInfo.root_pushes = 0;
529 Scr->StdCmapInfo.head =
Scr->StdCmapInfo.tail
530 =
Scr->StdCmapInfo.mru = NULL;
531 Scr->StdCmapInfo.mruindex = 0;
539 if(
CLarg.Monochrome || (
dpy && DisplayCells(
dpy, scrnum) < 3)) {
540 Scr->Monochrome = MONOCHROME;
543 Scr->Monochrome = COLOR;
552 Scr->MenuShadowColor =
Scr->Black;
553 Scr->IconBorderColor =
Scr->Black;
554 Scr->IconManagerHighlight =
Scr->Black;
556#define SETFB(fld) Scr->fld.fore = Scr->Black; Scr->fld.back = Scr->White;
565 SETFB(workSpaceMgr.windowcp)
566 SETFB(workSpaceMgr.curColors)
567 SETFB(workSpaceMgr.defColors)
573 if(
dpy && FirstScreen) {
592 screenmasked =
false;
593 if(
dpy && takeover &&
Scr->ShowWelcomeWindow
594 && (welcomefile = getenv(
"CTWM_WELCOME_FILE"))) {
611 fprintf(stderr,
"%d: No errors found\n", scrnum);
614 fprintf(stderr,
"%d: Errors found\n", scrnum);
656 if(
Scr->ShowWelcomeWindow && !screenmasked) {
667 if(
Scr->ClickToFocus) {
668 Scr->FocusRoot =
false;
669 Scr->TitleFocus =
false;
672 if(
Scr->use3Dborders) {
673 Scr->ClientBorderWidth =
false;
680 Scr->BorderLeft,
Scr->BorderRight,
681 Scr->BorderTop,
Scr->BorderBottom);
682 if(
Scr->BorderedLayout == NULL) {
683 Scr->BorderedLayout =
Scr->Layout;
685 else if(
Scr->BorderedLayout->monitors->len == 0) {
687 "Borders too large! correct BorderLeft, BorderRight, BorderTop and/or BorderBottom parameters\n");
691 fprintf(stderr,
"Bordered: ");
705 EwmhInitVirtualRoots(
Scr);
721#define SETDEF(fld, num) if(Scr->fld == -100) { Scr->fld = num; }
722 if(
Scr->use3Dtitles) {
738 if(!
Scr->use3Dtitles) {
739 Scr->TitleShadowDepth = 0;
740 Scr->TitleButtonShadowDepth = 0;
742 if(!
Scr->use3Dborders) {
743 Scr->BorderShadowDepth = 0;
745 if(!
Scr->use3Dmenus) {
746 Scr->MenuShadowDepth = 0;
748 if(!
Scr->use3Diconmanagers) {
749 Scr->IconManagerShadowDepth = 0;
751 if(!
Scr->use3Dborders) {
752 Scr->ThreeDBorderWidth = 0;
756 if(!
Scr->BeNiceToColormap) {
761 if(
Scr->use3Dtitles) {
764 if(
Scr->use3Dmenus) {
767 if(
Scr->use3Dmenus) {
770 if(
Scr->use3Dborders) {
777 if(ir->TitleJustification ==
TJ_UNDEF) {
778 ir->TitleJustification =
Scr->IconJustification;
781 ir->Justification =
Scr->IconRegionJustification;
784 ir->Alignement =
Scr->IconRegionAlignement;
792#define DEFCURSOR(name, val) if(!Scr->name) NewFontCursor(&Scr->name, val)
793 DEFCURSOR(FrameCursor,
"top_left_arrow");
794 DEFCURSOR(TitleCursor,
"top_left_arrow");
796 DEFCURSOR(IconMgrCursor,
"top_left_arrow");
804 DEFCURSOR(AlterCursor,
"question_arrow");
817 if(!
Scr->HaveFonts) {
823 Scr->TitleBarFont.y +=
Scr->FramePadding;
824 Scr->TitleHeight =
Scr->TitleBarFont.height +
Scr->FramePadding * 2;
825 if(
Scr->use3Dtitles) {
826 Scr->TitleHeight += 2 *
Scr->TitleShadowDepth;
829 if(!(
Scr->TitleHeight & 1)) {
898 Window parent, *children;
899 unsigned int nchildren;
901 XQueryTree(
dpy,
Scr->Root, &croot, &parent, &children, &nchildren);
904 for(
int i = 0; i < nchildren; i++) {
906 XWMHints *wmhintsp = XGetWMHints(
dpy, children[i]);
909 if(wmhintsp->flags & IconWindowHint) {
910 for(
int j = 0; j < nchildren; j++) {
911 if(children[j] == wmhintsp->icon_window) {
928 for(
int i = 0; i < nchildren; i++) {
930 XUnmapWindow(
dpy, children[i]);
948 if(
Scr->ShowWorkspaceManager &&
Scr->workSpaceManagerActive) {
950 if(
Scr->WindowMask) {
951 XRaiseWindow(
dpy,
Scr->WindowMask);
953 for(vs =
Scr->vScreenList; vs != NULL; vs = vs->
next) {
971 unsigned long valuemask;
972 XSetWindowAttributes attributes;
974 attributes.border_pixel =
Scr->DefaultC.fore;
975 attributes.background_pixel =
Scr->DefaultC.back;
976 attributes.event_mask = (ExposureMask | ButtonPressMask |
977 KeyPressMask | ButtonReleaseMask);
979 valuemask = (CWBorderPixel | CWBackPixel | CWEventMask | CWCursor);
980 Scr->InfoWindow.win =
981 XCreateWindow(
dpy,
Scr->Root, 0, 0,
984 CopyFromParent, CopyFromParent,
985 valuemask, &attributes);
1004 XRectangle ink_rect;
1005 XRectangle logical_rect;
1006 unsigned long valuemask;
1007 XSetWindowAttributes attributes;
1009 XmbTextExtents(
Scr->SizeFont.font_set,
1010 " 8888 x 8888 ", 13,
1011 &ink_rect, &logical_rect);
1012 Scr->SizeStringWidth = logical_rect.width;
1013 valuemask = (CWBorderPixel | CWBackPixel | CWBitGravity);
1014 attributes.bit_gravity = NorthWestGravity;
1016 if(
Scr->SaveUnder) {
1017 attributes.save_under = True;
1018 valuemask |= CWSaveUnder;
1021 Scr->SizeWindow = XCreateWindow(
dpy,
Scr->Root,
1023 Scr->SizeStringWidth,
1024 (
Scr->SizeFont.height +
1029 valuemask, &attributes);
1033 Scr->ShapeWindow = XCreateSimpleWindow(
dpy,
Scr->Root, 0, 0,
1034 Scr->rootw,
Scr->rooth, 0, 0, 0);
1038 if(
Scr->ShowWelcomeWindow) {
1044 Scr->FirstTime =
false;
1056 if(numManaged == 0) {
1058 fprintf(stderr,
"%s: unable to find any unmanaged screens\n",
1086 fprintf(stderr,
"Shouldn't return from HandleEvents()!\n");
1113 unsigned int crootw,
unsigned int crooth)
1125#define Scr StupidProgrammer
1132 scr->
rootx = crootx;
1133 scr->
rooty = crooty;
1134 scr->
rootw = crootw;
1135 scr->
rooth = crooth;
1138 scr->crootx = crootx;
1139 scr->crooty = crooty;
1140 scr->crootw = crootw;
1141 scr->crooth = crooth;
1298 scr->PreferredIconWidth = 48;
1299 scr->PreferredIconHeight = 48;
1301 scr->ewmh_CLIENT_LIST_used = 0;
1302 scr->ewmh_CLIENT_LIST_size = 16;
1303 scr->ewmh_CLIENT_LIST = calloc(scr->ewmh_CLIENT_LIST_size,
1304 sizeof(scr->ewmh_CLIENT_LIST[0]));
1305 if(scr->ewmh_CLIENT_LIST == NULL) {
1332#define DEFAULT_NICE_FONT "-*-helvetica-bold-r-normal-*-*-120-*"
1333#define DEFAULT_FAST_FONT "-misc-fixed-medium-r-semicondensed--13-120-75-75-c-60-*"
1334#define SETFONT(fld, var) (scr->fld##Font.basename = DEFAULT_##var##_FONT)
1343 "-adobe-courier-medium-r-normal--10-100-75-75-m-60-iso8859-1";
1346#undef DEFAULT_FAST_FONT
1347#undef DEFAULT_NICE_FONT
1371CreateCaptiveRootWindow(
int x,
int y,
1372 unsigned int width,
unsigned int height)
1378 scrnum = DefaultScreen(
dpy);
1379 ret = XCreateSimpleWindow(
dpy, RootWindow(
dpy, scrnum),
1380 x,
y, width, height, 2, WhitePixel(
dpy, scrnum),
1381 BlackPixel(
dpy, scrnum));
1382 wmhints.initial_state = NormalState;
1383 wmhints.input = True;
1384 wmhints.flags = InputHint | StateHint;
1386 XmbSetWMProperties(
dpy, ret,
"Captive ctwm", NULL, NULL, 0, NULL,
1388 XChangeProperty(
dpy, ret, XA_WM_CTWM_ROOT, XA_WINDOW, 32,
1389 PropModeReplace, (
unsigned char *) &ret, 1);
1390 XSelectInput(
dpy, ret, StructureNotifyMask);
1391 XMapWindow(
dpy, ret);
1406 XWindowAttributes wa;
1408 XGetWindowAttributes(
dpy, w, &wa);
1409 return ((wa.map_state != IsUnmapped) && (wa.override_redirect != True));
void StartAnimation(void)
char * AddToCaptiveList(const char *cptname)
void clargs_parse(int argc, char *argv[])
bool InstallColormaps(int type, Colormaps *cmaps)
ColormapWindow * CreateColormapWindow(Window w, bool creating_parent, bool property_window)
void LocateStandardColormaps(void)
bool RestartPreviousState
int NumScreens
How many Screens are on our display.
int ctwm_main(int argc, char *argv[])
Start up ctwm.
bool ctwm_test
Magic flag for tests. Nothing else should touch this!
Atom XCTWMAtom[NUM_CTWM_XATOMS]
Our various common atoms.
static bool cfgerrs
Whether there were config parsing errors.
static bool MappedNotOverride(Window w)
Return true if a window is not set to override_redirect ("Hey!
#define SETFONT(fld, var)
#define DEFCURSOR(name, val)
ScreenInfo ** ScreenList
List of ScreenInfo structs for each Screen.
ScreenInfo * InitScreenInfo(int scrnum, Window croot, int crootx, int crooty, unsigned int crootw, unsigned int crooth)
Initialize ScreenInfo for a Screen.
int(* ctwm_test_postparse)(void)
Magic callback for tests.
bool takeover_screen(ScreenInfo *scr)
Take over as WM for a screen.
void NewFontCursor(Cursor *cp, const char *str)
void SimulateMapRequest(Window w)
void EwmhInitScreenLate(ScreenInfo *scr)
short DarkShadowContrast
The contrast of the dark shadow.
short ClearShadowContrast
The contrast of the clear shadow.
TitleJust IconJustification
How icon images/titles are aligned.
IcStyle IconifyStyle
How to animate window iconification, if any.
IRJust IconRegionJustification
How icons are laid out horizontally inside a region.
IRAlignement IconRegionAlignement
How icons are laid out vertically inside a region.
int MaxIconTitleWidth
Limit on icon title size. From MaxIconTitleWidth config var.
Window XineramaRoot
Root window holding our vscreens.
Window RealRoot
The actual X root window of the display.
Window Root
Root window for the current vscreen.
Window frame
The X window for the overall frame.
IconMgr * AllocateIconManager(char *name, char *icon_name, char *geom, int columns)
void AllocateOtherIconManagers(void)
void CreateIconManagers(void)
void MaskScreen(char *file)
void CreateOccupyWindow(void)
void OtpScrInitData(ScreenInfo *scr)
bool LoadTwmrc(const char *filename)
Principal entry point from top-level code to parse the config file.
void assign_var_savecolor(void)
void chk_keytable_order(void)
RArea * RAreaNewStatic(int x, int y, int width, int height)
Return a pointer to a static newly constructed RArea.
RAreaList * RAreaListNew(int cap,...)
Create an RAreaList from a set of RArea's.
int RLayoutNumMonitors(const RLayout *self)
How many monitors does a given RLayout contain?
void RLayoutPrint(const RLayout *self)
Pretty-print an RLayout.
RArea RLayoutGetAreaIndex(const RLayout *self, int index)
Return the index'th RArea in an RLayout, or RAreaInvalid() with an out of range index.
RLayout * RLayoutNew(RAreaList *monitors)
Create an RLayout for a given set of monitors.
RLayout * RLayoutCopyCropped(const RLayout *self, int left_margin, int right_margin, int top_margin, int bottom_margin)
Create a copy of an RLayout with given amounts cropped off the sides.
#define SIZE_VINDENT
Internal padding in the size window.
void ReadWinConfigFile(char *filename)
void ConnectToSessionManager(char *previous_id)
void setup_signal_handlers(void)
Setup signal handlers (run during startup).
void sound_load_list(void)
void play_startup_sound(void)
A particular extent of space.
Info and control for each X Screen we control.
bool BackingStore
BackingStore config var.
bool DecorateTransients
DecorateTransients config var.
int TitlePadding
TitlePadding config var. Distance between items in titlebar.
bool NoRaiseMove
NoRaiseOnMove config var.
bool IconManagerDontShow
IconManagerDontShow config var.
bool use3Dmenus
UseThreeDMenus config var.
bool NoWarpToMenuTitle
NoWarpToMenuTitle config var.
bool SloppyFocus
SloppyFocus config var.
bool use3Dtitles
UseThreeDTitles config var.
bool AutoFocusToTransients
AutoFocusToTransients config var.
bool BeNiceToColormap
BeNiceToColormap config var.
unsigned short OpaqueResizeThreshold
OpaqueResizeThreshold config var.
bool AutoRaiseIcons
AutoRaiseIcons config var.
bool NoIconManagers
NoIconManagers config var.
short IconManagerShadowDepth
IconManagerShadowDepth config var.
bool AutoOccupy
AutoOccupy config var.
int TransientOnTop
TransientOnTop config var.
bool NoGrabServer
NoGrabServer config var.
bool IgnoreCaseInMenuSelection
IgnoreCaseInMenuSelection config var.
bool ClickToFocus
ClickToFocus config var.
short MoveDelta
MoveDelta config var. Number of pixels before f.move starts.
int BorderTop
BorderTop config var.
bool use3Dborders
UseThreeDBorders config var.
short MenuShadowDepth
MenuShadowDepth config var.
bool DontWarpCursorInWMap
DontWarpCursorInWMap config var.
bool DontPaintRootWindow
DontPaintRootWindow config var.
int MaxWindowWidth
Largest window width to allow.
bool OpaqueResize
Whether we're in the midst of an opaque resizing.
int NumAutoRaises
Number of autoraise windows on screen.
bool WindowRingAll
WindowRing config var.
bool ForceFocus
ForceFocus config var.
bool InterpolateMenuColors
InterpolateMenuColors config var.
short BorderShadowDepth
BorderShadowDepth config var.
bool NoRaiseDeicon
NoRaiseOnDeiconify config var.
bool FocusRoot
Whether focus is allowed to move.
short RandomDisplacementY
RandomPlacement config var (2nd arg).
short TitleButtonShadowDepth
TitleButtonShadowDepth config var.
int MaxWindowHeight
Largest window height to allow.
WorkSpaceMgr workSpaceMgr
Info about the WorkSpaceManager (and Occupy window) for the screen.
int BorderBottom
BorderBottom config var.
int BorderRight
BorderRight config var.
short RandomDisplacementX
RandomPlacement config var (2nd arg).
short WMgrVertButtonIndent
WMgrVertButtonIndent config var.
int SizeStringOffset
X offset in size window for drawing.
bool use3Diconmanagers
UseThreeDIconManagers config var.
short WMgrButtonShadowDepth
WMgrButtonShadowDepth config var.
int ButtonIndent
ButtonIndent config var. Amount to shrink titlebar buttons.
bool FirstTime
Some sort of attempt to determine whether this is the first config file we've parsed for this screen ...
bool SqueezeTitle
SqueezeTitle and/or DontSqueezeTitle config vars.
bool DoZoom
Whether we're animating [de]iconification zooms.
bool WarpCursor
WarpCursor config var.
int NumAutoLowers
Number of autolower windows on screen.
int IconBorderWidth
IconBorderWidth config var.
bool ForceIcon
ForceIcons config var.
short OpenWindowTimeout
OpenWindowTimeout config var.
bool NoDefaults
NoDefaults config var.
int BorderLeft
BorderLeft config var.
int ThreeDBorderWidth
ThreeDBorderWidth config var.
int MovePackResistance
MovePackResistence config var.
RandPlac RandomPlacement
RandomPlacement config var (1st arg).
int FramePadding
FramePadding config var.
bool WarpUnmapped
WarpUnmapped config var.
int rootx
The x coordinate of the root window relative to RealRoot.
int rooty
The y coordinate of the root window relative to RealRoot.
bool ReallyMoveInWorkspaceManager
ReallyMoveInWorkspaceManager config var.
bool WarpToDefaultMenuEntry
WarpToDefaultMenuEntry config var.
bool RaiseOnClick
RaiseOnClick config var.
UsePPoss UsePPosition
UsePPosition config var.
bool Shadow
NoMenuShadows config var (inverse).
char * PixmapDirectory
PixmapDirectory config var.
bool TransientHasOccupation
TransientHasOccupation config var.
bool UseSunkTitlePixmap
UseSunkTitlePixmap config var.
bool Highlight
NoHighlight config var (inverse).
bool ShrinkIconTitles
ShrinkIconTitles config var.
bool DontMoveOff
DontMoveOff config var.
short ZoomCount
Zoom config var. Number of animated steps in [de]iconifying.
struct ScreenInfo::_TBInfo TBInfo
Various titlebar buttons that will be put in the window decorations for the screen....
int mm_h
Physical mm height of the root.
int rootw
Copy of DisplayWidth(dpy, screen).
int d_depth
Copy of DefaultDepth(dpy, screen).
bool ShowWinWhenMovingInWmgr
AlwaysShowWindowWhenMovingFromWorkspaceManager config var.
bool StackMode
NoStackMode config var (inverse).
bool NoIconTitlebar
NoIconTitle config var.
int screen
Which screen (i.e., the x after the dot in ":0.x").
bool ShowIconManager
ShowIconManager config var.
bool use3Dwmap
UseThreeDWMap config var.
int BorderWidth
BorderWidth config var.
bool AlwaysSqueezeToGravity
AlwaysSqueezeToGravity config var.
bool DoOpaqueMove
OpaqueMove config var.
int rooth
Copy of DisplayHeight(dpy, screen).
TitleJust TitleJustification
How title text is aligned in window titlebars.
unsigned int IgnoreModifier
IgnoreModifier config var.
bool HaveFonts
Whether fonts have been loaded yet in the startup process.
bool BorderCursors
BorderResizeCursors config var.
bool RaiseWhenAutoUnSqueeze
RaiseWhenAutoUnSqueeze config var.
bool ShowWorkspaceManager
ShowWorkSpaceManager config var.
bool SaveWorkspaceFocus
SaveWorkspaceFocus config var.
bool NameDecorations
DontNameDecorations config var (inverse).
bool DontToggleWorkspaceManagerState
DontToggleWorkspaceManagerState config var.
int Monochrome
Is the display monochrome?
bool ShortAllWindowsMenus
ShortAllWindowsMenus config var.
short XMoveGrid
XMoveGrid config var.
bool SaveUnder
NoSaveUnders config var (inverse).
bool PackNewWindows
PackNewWindows config var.
bool RaiseOnWarp
NoRaiseOnWarp config var (inverse).
unsigned short OpaqueMoveThreshold
OpaqueMoveThreshold config var.
int MoveOffResistance
MoveOffResistence config var.
short WMgrHorizButtonIndent
WMgrHorizButtonIndent config var.
short RaiseOnClickButton
RaiseOnClickButton config var.
bool ClientBorderWidth
ClientBorderWidth config var.
bool NoTitlebar
NoTitle config var.
bool WarpRingAnyWhere
WarpRingOnScreen config var (inverse).
bool TitleFocus
NoTitleFocus config var (inverse).
bool SortIconMgr
SortIconManager config var.
short TitleShadowDepth
TitleShadowDepth config var.
bool OpaqueMove
Whether we're doing a window opaque move.
bool TitleHighlight
NoTitleHighlight config var (inverse).
short YMoveGrid
YMoveGrid config var.
bool CaseSensitive
NoCaseSensitive config var (inverse).
bool ReverseCurrentWorkspace
ReverseCurrentWorkspace config var.
bool IconManagerFocus
NoIconManagerFocus config var (inverse).
bool NoRaiseResize
NoRaiseOnResize config var.
bool CenterFeedbackWindow
CenterFeedbackWindow config var.
bool DoOpaqueResize
OpaqueResize config var.
bool SunkFocusWindowTitle
SunkFocusWindowTitle config var.
bool StayUpMenus
StayUpMenus config var.
bool IconifyByUnmapping
IconifyByUnmapping config var.
int mm_w
Physical mm width of the root.
bool mapped
Is the window mapped ?
struct VirtualScreen * next
struct WorkSpaceWindow * wsw
struct OccupyWindow * occupyWindow
void GetColor(int kind, Pixel *what, const char *name)
Get info from the server about a given color.
void GetShadeColors(ColorPair *cp)
Try and create a 'shaded' version of a color for prettier UI.
void CreateFonts(ScreenInfo *scr)
Load up our various defined fonts.
void InitVirtualScreens(ScreenInfo *scr)
void InitTitlebarButtons(void)
void Squeeze(TwmWindow *tmp_win)
void SetFocus(TwmWindow *tmp_win, Time tim)
void CreateWindowRegions(void)
void SetMapStateProp(TwmWindow *tmp_win, int state)
void createWindowBoxes(void)
void InitWorkSpaceManagerContext(void)
void CreateWorkSpaceManager(void)
void ConfigureWorkSpaceManager(ScreenInfo *scr)
Prep up structures for WSM windows in each VS.
RLayout * XrandrNewLayout(Display *disp, Window rootw)
Use XRANDR to figure out how our monitors are laid out.