You are not logged in.

#1 2011-09-14 00:08:46

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

dminiwm snapwm & bipolarbar

As a consequence of the catwm thread and the thread about my port of catwm to xcb we have this thread about a dynamic tiling window manager with no major bugs! smile
I saw gold in catwms' save_desktop function.
It's simple; there's no floating windows, no status bar, popups are treated like any other window etc.
There's choice in the tiling method; new window is master or attach aside.
new_window_master_small.png    new_window_stack_small.png
There's choice in the tiling mode used; Vertical, Horizontal, Fullscreen, Stacking and Grid.
horiz_small.png stacking2_small.png    grid_small.png
You can even resize the window at the top of the stack wink
vert_resize_stack.png
Changing a tiling mode or window size on one desktop doesn't effect other desktops.

Most changes can be made in the config.h file:
    Like if you want space to run a panel
    Whether to focus the window the mouse just moved to
    Whether to follow a window when you send it to another desktop
    What application to open on what desktop
    Colours, keyboard shortcuts etc, etc
It's light on resources both in filesize and memory used.
I paid for the whole screen and I'm going to use the whole screen so dynamic is the way to go. big_smile
If you want to try a light dynamic tiler it's on github.
Cheers

Update:
    There's been lots of little bugs fixed and a few enhancements along the way. The biggest additions are a bar, which has a clickable desktop switcher, shows the tiling mode and focused windows' name and has space to show external text like conky, and there's a reloadable rc file. Since dminiwm is about staying under 1000 sloc the wm with the bar goes by a different name - snapwm
Here's a pic of snapwm in action:
snapwm_in_action_small.png snapwm_dual_small.png
So this thread is now about two window managers, dminiwm and snapwm, which have the same window manager functions. The only difference between them is snapwm is dminiwm with the reloadable rc file and the bar.
Thanks to stlarch snapwm has a wiki page here.

Update2:
    There's now a multi monitor version of dminiwm, that's still under 1000 loc.
mm_dmini_small.png

Update3:
    After some good practise with some_sorta_bar I made bipolarbar(formerly splitter_bar), which is a lightweight bar for window managers that takes two inputs with different timings. It is aimed at, but not limited to, monsterwm users. Here is the first announcement of it or see the Readme on github for usage clues.
Here's a pic of it in action with dminiwm:
dmini_bipolar_small.png

Update4:
    There's now a stable release of snapwm.
    github https://github.com/moetunes/snapwm-stable
    aur    https://aur.archlinux.org/packages/snapwm-stable/

Cheers

Last edited by moetunes (2013-06-06 19:32:19)


You're just jealous because the voices only talk to me.

Offline

#2 2011-09-14 08:52:38

el mariachi
Member
Registered: 2007-11-30
Posts: 588

Re: dminiwm snapwm & bipolarbar

Great job moe! Haven't found a bug so far wink

Offline

#3 2011-09-14 09:14:34

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

el mariachi wrote:

Great job moe! Haven't found a bug so far wink

heh there'll be bugs...
I stripped it right down to have the ability to resize the window at the top of the stack take up as few lines of code as possible. I'm still building it back up to what DMiniWM is e.g. having the panel at the top.
Cheers


You're just jealous because the voices only talk to me.

Offline

#4 2011-09-15 07:59:32

mhertz
Member
From: Denmark
Registered: 2010-06-19
Posts: 664

Re: dminiwm snapwm & bipolarbar

Again, great job!

I like the resziseble top stack, and it only needs the return of the grid layout to be even more awesome!

I myself like that it dosent have a floating layer and tagging rules for it, since I never use that... Also because the apps that used to make problems like e.g. gimp, now has options for docking the toolbars, and if not, then a tiling layout still would suit me better than floating, and finally, if you cant live without it, then you can just fire up a new X session without a wm and just the app in question, i.e. 'xinit /usr/bin/appname -- :1'.

Thanks again!

Offline

#5 2011-09-15 09:39:39

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

I added the grid mode back yesterday and the gimp does look funny in it  smile

Cheers


You're just jealous because the voices only talk to me.

Offline

#6 2011-09-15 11:17:10

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

The gimp doesn't like having its' windows managed... big_smile
tYWQzNg tYWQzOA

Cheers

Last edited by moetunes (2012-02-16 19:14:09)


You're just jealous because the voices only talk to me.

Offline

#7 2011-09-15 12:20:13

Cloudef
Member
Registered: 2010-10-12
Posts: 636

Re: dminiwm snapwm & bipolarbar

Install gimp-devel and run in single window mode == profit.

Offline

#8 2011-09-15 23:46:53

el mariachi
Member
Registered: 2007-11-30
Posts: 588

Re: dminiwm snapwm & bipolarbar

it's what I'm doing and it works big_smile

Offline

#9 2011-09-16 02:27:38

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

Procrastinating again while playing with xmms wink

tYWRmYw

Cheers

Last edited by moetunes (2012-02-16 19:14:56)


You're just jealous because the voices only talk to me.

Offline

#10 2011-09-16 13:09:01

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

I've been distracted and have finally added back the option to have the panel at the top so dminiwm is pretty much at the stage DMiniWM was but with the option to resize the window at the top of the stack. I fined tuned the grid tiling mode a bit but it's not perfect (screen heights aren't evenly divisible by three..)
There's still about 150 sloc until we hit the 1000 mark big_smile

Cheers


You're just jealous because the voices only talk to me.

Offline

#11 2011-09-17 13:49:49

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

I have two apps, me-tv and xmms, that are giving me some hassles.They handle their configuration windows differently to e.g. firefox; thunar. When their configuration windows close they don't send a destroynotify event so it's hard to remove them from the window stack which leaves an empty space on the screen. I thought I had the ghost window issue thoroughly licked... I'm sure these aren't the only apps that do this so it's something I'll have to sort out sooner or later. The kill_client function does remove the empty space from the window stack but that isn't going to be a long term solution.


You're just jealous because the voices only talk to me.

Offline

#12 2011-09-18 08:37:38

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

Seems some apps don't destroy their configuration windows when you're done with them, they just put them in the withdrawn state so you can't see them. I'm not going to worry about that in such a light window manager.
Cheers


You're just jealous because the voices only talk to me.

Offline

#13 2011-09-19 07:45:21

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

edit:
Cheers

Last edited by moetunes (2011-10-15 02:39:49)


You're just jealous because the voices only talk to me.

Offline

#14 2011-10-08 00:33:20

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

It's been a rainy saturday morning here so I fixed up the grid mode to remove the useless gaps
Here's a pic:
tYXBndg
and now fullscreen mplayer fits in the window manager better.

Cheers

Last edited by moetunes (2012-02-16 19:15:56)


You're just jealous because the voices only talk to me.

Offline

#15 2011-10-08 02:34:35

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

Some more enhancements wink
Windows are borderless if there is only one on the desktop or in fullscreen mode.


You're just jealous because the voices only talk to me.

Offline

#16 2011-10-08 18:52:35

el mariachi
Member
Registered: 2007-11-30
Posts: 588

Re: dminiwm snapwm & bipolarbar

Thanks!!

Offline

#17 2011-10-08 22:27:58

hellomynameisphil
Member
From: /home/phil/Vancouver
Registered: 2009-10-02
Posts: 257
Website

Re: dminiwm snapwm & bipolarbar

Thanks for all your work on this, moe. It's fun to play with this. I love the simplicity and minimalism of it; I never thought anyone could out-minimal dwm and still have it be usable! :-)

Offline

#18 2011-10-08 23:47:18

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

I just ran cloc on the files

 9:40:22 am
 [ ~ ]$ cloc build/dminiwm-0.0.6/src/dminiwm.c build/dminiwm-0.0.6/src/config.h 
Use of qw(...) as parentheses is deprecated at /usr/bin/cloc line 1839.
       2 text files.
       2 unique files.                              
       0 files ignored.

http://cloc.sourceforge.net v 1.54  T=0.5 s (4.0 files/s, 2052.0 lines/s)
-------------------------------------------------------------------------------
Language                     files          blank        comment           code
-------------------------------------------------------------------------------
C                                1            123             79            718
C/C++ Header                     1              9             29             68
-------------------------------------------------------------------------------
SUM:                             2            132            108            786
-------------------------------------------------------------------------------

I think there's a fair bit of functionality in this for only 786 sloc smile
As a comparison I ran cloc on dwm 5.8.2 with the bstack patch

 9:40:50 am
 [ ~ ]$ cloc build/Window-managers/dwm/dwm-5.8.2/dwm.c build/Window-managers/dwm/dwm-5.8.2/config.h 
Use of qw(...) as parentheses is deprecated at /usr/bin/cloc line 1839.
       2 text files.
       2 unique files.                              
       0 files ignored.

http://cloc.sourceforge.net v 1.54  T=0.5 s (4.0 files/s, 4454.0 lines/s)
-------------------------------------------------------------------------------
Language                     files          blank        comment           code
-------------------------------------------------------------------------------
C                                1            176             64           1856
C/C++ Header                     1             12             22             97
-------------------------------------------------------------------------------
SUM:                             2            188             86           1953
-------------------------------------------------------------------------------

Cheers

edit: You do get alot more with dwm tho

Last edited by moetunes (2011-10-14 08:41:18)


You're just jealous because the voices only talk to me.

Offline

#19 2011-10-12 23:33:12

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

I found a way with just 7 lines to have popup windows not be managed by the window manager. It's still a bit rough (there's just 7 lines managing it wink ) but functional.
Here's a pic :
tYXM0bQ

Cheers

Last edited by moetunes (2012-02-16 19:17:26)


You're just jealous because the voices only talk to me.

Offline

#20 2011-10-13 07:09:23

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

I've played with how the popups are handled and now it's a bit more friendlier. If you lose one just cycle through the windows and it'll pop back up in the same spot.

Cheers

Last edited by moetunes (2011-10-13 08:55:15)


You're just jealous because the voices only talk to me.

Offline

#21 2011-10-13 09:30:18

rich_o
Member
Registered: 2008-07-28
Posts: 48

Re: dminiwm snapwm & bipolarbar

Hi,

i like dminimalwm (and would have catwm, if i've found out about it earlier). It surprised me, that ~1000 sloc can provide me with nearly everything i need.

It's also nice and readable code, so i use the chance and try to learn some C. I also forked it to github.com/richo4/dminimalwm.

rich_o

Offline

#22 2011-10-13 09:59:57

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

rich_o wrote:

Hi,

i like dminimalwm (and would have catwm, if i've found out about it earlier). It surprised me, that ~1000 sloc can provide me with nearly everything i need.

It's also nice and readable code, so i use the chance and try to learn some C. I also forked it to github.com/richo4/dminimalwm.

rich_o

That's what attracted me to it smile
I'm happy to help with any questions.

Cheers

Last edited by moetunes (2011-10-13 10:02:20)


You're just jealous because the voices only talk to me.

Offline

#23 2011-10-13 15:30:34

firecat53
Member
From: Sammamish, Wa
Registered: 2007-05-14
Posts: 1,447
Website

Re: dminiwm snapwm & bipolarbar

Hey moetunes, did you ever get a chance to test it on systems not using the full complement of tty's (you and I did some testing a month or 2 ago)? I did test it on a system with all 6 tty's and it worked fine, but both systems with only 2 tty's didn't work. Nice work!

Scott

Online

#24 2011-10-13 20:23:28

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

firecat53 wrote:

Hey moetunes, did you ever get a chance to test it on systems not using the full complement of tty's (you and I did some testing a month or 2 ago)? I did test it on a system with all 6 tty's and it worked fine, but both systems with only 2 tty's didn't work. Nice work!

Scott

No I've never tried it on systems using 2 tty's. I just went through how dwm starts and it's pretty much the same as what dminiwm does

    // Screen and root window
    screen = DefaultScreen(dis);
    root = RootWindow(dis,screen);

they both just grab the default screen so I have no idea why this won't work on your systems and wouldn't know where to start looking for clues... any errors from X like screen not available?

Cheers

Last edited by moetunes (2011-10-13 20:28:13)


You're just jealous because the voices only talk to me.

Offline

#25 2011-10-13 21:29:48

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,024

Re: dminiwm snapwm & bipolarbar

I had a bit of a play with the grid mode and now, with 3 or 4 windows open, windows can be resized in both directions using alt+h/l and alt+p/o
Here's a pic :
tYXNuYw
While hacking away I reworked things to use one less variable and I ended up using one line of code less overall by adding the grow_window option cool

Cheers

Last edited by moetunes (2012-02-16 19:18:14)


You're just jealous because the voices only talk to me.

Offline

Board footer

Powered by FluxBB