summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoruint23 <[email protected]>2025-04-19 20:57:18 +0100
committeruint23 <[email protected]>2025-04-19 20:57:18 +0100
commit29a67d193e8dbbb8985fbef4cc6f24589947b869 (patch)
tree52e5a05190348713a61ba83adb586aa4952d8d73
parent1ae8d76f4f49b6ae69844e9920b314d5c9f6b6b4 (diff)
adding workspace support
-rw-r--r--src/sxwm.c4
-rw-r--r--src/usercfg.h7
2 files changed, 10 insertions, 1 deletions
diff --git a/src/sxwm.c b/src/sxwm.c
index c2bf936..48af7ae 100644
--- a/src/sxwm.c
+++ b/src/sxwm.c
@@ -69,7 +69,9 @@ static Atom atom_net_wm_window_type_dock;
static Atom atom_net_workarea;
static Cursor c_normal, c_move, c_resize;
-static Client *clients = NULL;
+static Client *workspaces[NUM_WORKSPACES] = { NULL };
+static uint current_ws = 0;
+static Client *clients = NULL; // TO BE REMOVED TODO
static Client *drag_client = NULL;
static Client *focused = NULL;
static EventHandler evtable[LASTEvent];
diff --git a/src/usercfg.h b/src/usercfg.h
index b364540..f7cdb69 100644
--- a/src/usercfg.h
+++ b/src/usercfg.h
@@ -38,6 +38,11 @@
* How many pixels away from the screen
* until the window *snaps* to the edge
*
+ * NUM_WORKSPACES (int):
+ * This is how many workspaces you want
+ * in this window manager. Best to leave
+ * it default (9).
+ *
* ———————————————————————————————————————————*
*/
@@ -51,6 +56,8 @@
#define MOTION_THROTTLE 60
#define SNAP_DISTANCE 5
+#define NUM_WORKSPACES 9
+
/*
* ————————————< Keys & Bindins >—————————————*
*