You are not logged in.
If I am in tiling mode with exactly two windows tiled and then set one to floating either using the mouse or super key it crashes it doesn't happen in any other mode.
Offline
@livinglifeback great, thanks for the report. it was a problem in nmaster patch. it is now fixed.
@TheLemonBoy, I got '|' on windowtitles patch.
on other news I'm going over the multi-montor branch will update soon
.:[ git me! ] :.
Offline
@mhertz try this one
Ahh, that's great thinking, man Thanks alot!
I'm still having some issues, though, which I cannot understand why that's happening... ?
First, I didn't get any acpi output, and the field was just blank where it should have been shown.
Then, I changed:
if [[ $wmout =~ ^acpi|* ]]; then
To:
if [[ $wmout =~ ^acpi|.* ]]; then
(I just added a dot...)
Now it does show the acpi info to the right, but now the whole leftside is empty except this '[]' ?
Also, whenever I e.g. change desktops or something, then the acpi info to the right changes into what the wm outputs i.e. all those numbers and colons?
Anyway, you have allready helped me with this way to much, so dont think about it anymore, and again thanks alot for all your help, mate!
@others
If anybody is using some_sorta_bar(or TheLemonMan's bar) to display workspace/window status to the left, and also has conky output to the right, and no delays in the leftside-output, then I would much appreciate if you could kindly pm me with your init-script, thanks. (I'm thinking about if I should replace the acpi, date and amixer commands with just simply conky instead...)
Last edited by mhertz (2012-07-17 15:02:09)
Offline
I've just changed over to TheLemonMan's bar and so I changed cookie's some_sorta_bar initscript to use LemonMan's color and placement-codes... (It took some time experimenting, since some places one backslash where needed, whereas other places, two and also three where needed, depending on where in the script...)
ff="/tmp/monsterwm.fifo"
[[ -p $ff ]] || mkfifo -m 600 "$ff"
ds=("web" "dev" "foo" "null")
ms=("T" "M" "B" "G" "F")
while read -t 60 -r wmout || true; do
if [[ $wmout =~ ^(([[:digit:]]+:)+[[:digit:]]+ ?)+$ ]]; then
read -ra desktops <<< "$wmout" && unset r
for desktop in "${desktops[@]}"; do
IFS=':' read -r d w m c u <<< "$desktop"
((c)) && fg="\\f4" i="${ms[$m]}" || fg="\\f3"
((u)) && w+='\f5!'
r+="$fg${ds[$d]} ${w/#0/\\f8-} \\f3:: "
done
r="${r%::*}"
fi
printf "\\\l%s\\\r%s\n" "$r\\f5[\\f3$i\\f5]" "$(date +"%F %R")"
done < "$ff" | bar &
monsterwm > "$ff"
Last edited by mhertz (2012-07-21 18:47:37)
Offline
Hey, I just noticed I've never been able to use "mouse buttons" to spawn commands, I wonder if I'm doing something wrong.. I see no errors around which makes this case really interesting.
Here's the part from config.def.h
static Button buttons[] = {
{ MOD1, Button1, mousemotion, {.i = MOVE}},
{ MOD1, Button3, mousemotion, {.i = RESIZE}},
{ MOD1, Button2, spawn, {.com = menucmd}},
};
Last edited by Shinryuu (2012-07-18 19:28:42)
Offline
I started playing with monster again. I'm using the startup script from mhertz and lemonboy's bar. How would I launch conky in that script? Thanks
Offline
Thanks c00kiema5ter for this little tiling wm! It's truly amazing how much it can do with so few lines of code. Using it full time.
Offline
[...] I'm using the startup script from mhertz and lemonboy's bar. How would I launch conky in that script? Thanks
I've modified the script to use conky:
ff="/tmp/monsterwm.fifo"
[[ -p $ff ]] || mkfifo -m 600 "$ff"
ff2="/tmp/monsterwm2.fifo"
[[ -p $ff2 ]] || mkfifo -m 600 "$ff2"
conky | while read -r; do echo "$REPLY" > "$ff2"; done &
ds=("web" "dev" "foo" "null")
ms=("T" "M" "B" "G" "F")
while read -t 60 -r wmout || true; do
if [[ $wmout =~ ^(([[:digit:]]+:)+[[:digit:]]+ ?)+$ ]]; then
read -ra desktops <<< "$wmout" && unset r
for desktop in "${desktops[@]}"; do
IFS=':' read -r d w m c u <<< "$desktop"
((c)) && fg="\\f4" i="${ms[$m]}" || fg="\\f3"
((u)) && w+='\f5!'
r+="$fg${ds[$d]} ${w/#0/\\f8-} \\f3:: "
done
r="${r%::*}"
fi
printf "\\\l%s\\\r%s\n" "$r\\f5[\\f3$i\\f5]" "$(< "$ff2")"
done < "$ff" | bar &
monsterwm > "$ff"
For some reason it needed the while-loop, as just using: 'conky > "$ff2" &', or 'conky | tee -a "$ff2" &', didn't work, or atleast it didn't output anything when using '$(< "$ff2")'...
Note, of course you need to set conky to output to console and not to X, and you will have a delay of the left-side output according to whatever you have set 'update_interval' in .conkyrc to...
I don't use conky myself, but i've tested the above to work correctly...
Last edited by mhertz (2012-07-21 18:48:42)
Offline
Thanks mhertz. I'll play around with it some more.
Offline
Okey, sorry if this is a silly question to you guys, also sorry if it's wrong to post it here.
How do I get a dzen2 conky bar, is there any guide or such? I've tried to find any documentation but couldn't do so.
Offline
^create a console-only conky (by adding the options 'out_to_x no' and 'out_to_console yes' to your conkyrc and piping it into dzen like this:
conky | dzen2 &
Offline
Okey, thanks.
Do I add that "conky | dzen2 &" to my .xinitrc?
Offline
It seems I can spawn a command with mouse if I have an application like urxvt opened and have focus on it. But if I have mouse in the desktop and try to spawn a command with my mouse.. nothing happens. This would be really useful for my laptop because I use mygtkmenu to help my daily porn.
[static Button buttons[] = {
{ MOD1, Button1, mousemotion, {.i = MOVE}},
{ MOD1, Button3, mousemotion, {.i = RESIZE}},
{ CONTROL, Button3, spawn, {.com = mymenucmd}},
};
Last edited by Shinryuu (2012-07-19 19:20:30)
Offline
@Shinryuu, sorry i've been busy lately
you're right, it doesnt work, *if where you click has no window*
I noted to fix this, and will do asap, along with a new mutli-monitor branch.
thanks for reporting.
.:[ git me! ] :.
Offline
Offline
Seems I might have caused more grief than good for some people using some_sorta_bar with monsterwm. I think I have a solution.
Sorry it took so long.
You're just jealous because the voices only talk to me.
Offline
@Cloudef, heh, I understand that rebasing makes things harder for people to follow the code.
I would like to do xcb, but for now, time is not enough .. and yeah, I think eventually the xcb version will prevail.
@moetunes, that's nice
.:[ git me! ] :.
Offline
@moetunes
You rock, man! Thanks alot! Brilliant idea, and works perfectly! Finally no more delays! Thank you so much again, mate!
For others to try it out, then I have changed cookies some_sorta_bar init-script to instead use splitter_bar. I don't use conky and so the script uses date, acpi and amixer to show to the right: 'time | bat. | vol.'.
while :; do
xsetroot -name "$(date +%R) | $(acpi | cut -d ' ' -f5 | cut -d ':' -f1-2) | $(amixer get Master | tail -1 | cut -d ' ' -f6,8 | tr -d '[]')"
sleep 10
done &
ff="/tmp/monsterwm.fifo"
[[ -p $ff ]] || mkfifo -m 600 "$ff"
ds=("term" "web" "foo" "bar")
ms=("T" "M" "B" "G" "F")
while read -t 60 -r wmout || true; do
if [[ $wmout =~ ^(([[:digit:]]+:)+[[:digit:]]+ ?)+$ ]]; then
unset r
read -ra desktops <<< "$wmout"
for desktop in "${desktops[@]}"; do
IFS=':' read -r d w m c u <<< "$desktop"
((c)) && fg="&4" i="${ms[$m]}" || fg="&3"
((u)) && w+='&5!'
r+="$fg${ds[$d]} ${w/#0/&8-} &3:: "
done
r="${r%::*}"
printf "%s\n" "$r&5[&3$i&5]"
fi
done < "$ff" | splitter_bar &
monsterwm > "$ff"
Last edited by mhertz (2012-07-21 18:40:13)
Offline
Cookie helped me with a fix to his init-script which makes it work better with splitter_bar, and i've also updated the above script to include it, but now I actually see that with this fix added, then it's also possible to add no delays in LemonMan's bar and also some_sorta_bar(without the fix, you get mangled-leftside-output when changing volume with amixer)...
Here's a working no-delay init-script for LemonMan's bar, which you guys can adapt to your own preferences...
ff="/tmp/monsterwm.fifo"
[[ -p $ff ]] || mkfifo -m 600 "$ff"
while :; do
echo "$(date +%R) | $(acpi | cut -d ' ' -f5 | cut -d ':' -f1-2) | $(amixer get Master | tail -1 | cut -d ' ' -f6,8 | tr -d '[]')" > "$ff"
sleep 10
done &
ds=("term" "web" "foo" "bar")
ms=("T" "M" "B" "G" "F")
while read -t 60 -r wmout || true; do
[[ $wmout =~ ^.*\|.*\|.*$ ]] && status=$wmout
if [[ $wmout =~ ^(([[:digit:]]+:)+[[:digit:]]+ ?)+$ ]]; then
unset r
read -ra desktops <<< "$wmout"
for desktop in "${desktops[@]}"; do
IFS=':' read -r d w m c u <<< "$desktop"
((c)) && fg="\\f4" i="${ms[$m]}" || fg="\\f3"
((u)) && w+='\f5!'
r+="$fg${ds[$d]} ${w/#0/\\f8-} \\f3:: "
done
r="${r%::*}"
fi
printf "\\\l%s\\\r%s\n" "$r\\f5[\\f3$i\\f5]" "$status"
done < "$ff" | bar &
monsterwm > "$ff"
Sorry for double-posting...
Last edited by mhertz (2012-07-21 18:52:43)
Offline
Okey, thanks.
Do I add that "conky | dzen2 &" to my .xinitrc?
Well if you want it to start when X starts, then yes. You can also run it in a terminal with different options, to see what it'll look like before adding the line to xinitrc.
Offline
pushed changes. this should fix @Shinryuu report, about commands binded to mouse buttons not running when no windows are present.
I also created a new branch - xinerama-core.
this should be equivalent to core branch functionality but running on multiple monitors.
if you use it, you'll need to update your config.h. the new vars are:
#define FOLLOW_MONITOR False /* Follow the window when moved to a different monitor */
#define INFOCUS "#9c3885" /* focused window border color on unfocused monitor */
also, in the rules array one can now define on which monitor to spawn the specified app
and at last the keybinds for changing monitor focus and moving clients between monitors
at the end of the keys array; by default using WinKey(MOD4) + F{1..n}.
MONITORCHANGE( XK_F1, 0)
MONITORCHANGE( XK_F2, 1)
next will come the mater branch functionality built upon xinerama-core (will be xinerama-master).
I hope I'll get that before leaving for vacations on Tuesday night.
If you have many monitors test it! It should work well hopefully.
Xinerama support cost is 65loc (xinerama-core vs core) and it
might be possible to decrease that.
Last edited by c00kiemon5ter (2012-07-21 17:37:19)
.:[ git me! ] :.
Offline
xinerama-master is up
I need to fix some things on mousemotion, will do asap. fixed
Last edited by c00kiemon5ter (2012-07-21 20:15:22)
.:[ git me! ] :.
Offline
xinerama-master is up
I need to fix some things on mousemotion, will do asap.
ナイス、 will propably move to that when I have time.
Need to port some of my changes from personal branch though.
Offline
Nicely done, boner achieved!
Offline
Nice work! I played with the xinerama-core branch a bit and noticed two bugs. I have two monitors, right of which is the primary. Whenever I launch a program specified as floating in config.h, it shows up in the left monitor but monsterwm still thinks it's in the right one (as it should be). Also, making a client fullscreen just puts it to the top left corner of the leftmost monitor regardless of the monitor position. These fixes seem to work fine for me:
diff --git a/monsterwm.c b/monsterwm.c
index 2495aeb..426d323 100644
--- a/monsterwm.c
+++ b/monsterwm.c
@@ -778,7 +778,7 @@ void maprequest(XEvent *e) {
c = addwindow(w, (d = &(m = &monitors[newmon])->desktops[newdsk])); /* from now on, use c->win */
c->istrans = XGetTransientForHint(dis, c->win, &w);
if ((c->isfloat = (floating || d->mode == FLOAT)) && !c->istrans)
- XMoveWindow(dis, c->win, (m->w - wa.width)/2, (m->h - wa.height)/2);
+ XMoveWindow(dis, c->win, m->x + (m->w - wa.width)/2, m->y + (m->h - wa.height)/2);
int i; unsigned long l; unsigned char *state = NULL; Atom a;
if (XGetWindowProperty(dis, c->win, netatoms[NET_WM_STATE], 0L, sizeof a,
@@ -1054,7 +1054,7 @@ void setfullscreen(Client *c, Desktop *d, Monitor *m, Bool fullscrn) {
if (fullscrn != c->isfull) XChangeProperty(dis, c->win,
netatoms[NET_WM_STATE], XA_ATOM, 32, PropModeReplace, (unsigned char*)
((c->isfull = fullscrn) ? &netatoms[NET_FULLSCREEN]:0), fullscrn);
- if (fullscrn) XMoveResizeWindow(dis, c->win, 0, 0, m->w, m->h + PANEL_HEIGHT);
+ if (fullscrn) XMoveResizeWindow(dis, c->win, m->x, m->y, m->w, m->h + PANEL_HEIGHT);
XSetWindowBorderWidth(dis, c->win, (c->isfull || !d->head->next ? 0:BORDER_WIDTH));
}
Also, how would I go about having the bar visible only in the default monitor? Oh and I don't think this will work without modifying the tile function.
Offline