changeset: 1453:0082921983cb
tag: tip
user: Anselm R Garbe <garbeam_AT_gmail.com>
date: Thu Jul 09 11:21:06 2009 +0100
files: config.def.h dwm.c
description:
restricting number of mons by length of monsyms
diff -r 769fb14ae867 -r 0082921983cb config.def.h
--- a/config.def.h Wed Jul 08 18:59:20 2009 +0100
+++ b/config.def.h Thu Jul 09 11:21:06 2009 +0100
@@ -14,7 +14,7 @@
static const Bool topbar = True; /* False means bottom bar */
/* monitor(s) symbols */
-static const char *monsyms[] = { "<1>", "<2>", "<3>", "<4>", "<5>" };
+static const char *monsyms[] = { "<1>", "<2>", "<3>", "<4>" };
/* tagging */
static const char *tags[] = { "1", "2", "3", "4", "5", "6", "7", "8", "9" };
diff -r 769fb14ae867 -r 0082921983cb dwm.c
--- a/dwm.c Wed Jul 08 18:59:20 2009 +0100
+++ b/dwm.c Thu Jul 09 11:21:06 2009 +0100
@@ -1690,6 +1690,8 @@
if(XineramaIsActive(dpy))
info = XineramaQueryScreens(dpy, &n);
#endif /* XINERAMA */
+ if(n > LENGTH(monsyms))
+ n = LENGTH(monsyms);
/* allocate monitor(s) for the new geometry setup */
for(i = 0; i < n; i++) {
if(!(m = (Monitor *)malloc(sizeof(Monitor))))
Received on Thu Jul 09 2009 - 10:21:11 UTC
This archive was generated by hypermail 2.2.0 : Thu Jul 09 2009 - 10:24:05 UTC