Commit graph

61 commits

Author SHA1 Message Date
Marco Peereboom
40da6badcb Stray debug 2009-01-19 15:11:47 +00:00
Marco Peereboom
1df4187f5c simplify and shrink code in setup some more 2009-01-19 15:09:04 +00:00
Marco Peereboom
45ac9837d3 Shorten some variable names.
Don't leak memory and resources in setup.
2009-01-19 14:59:29 +00:00
Marco Peereboom
45ef141d5c Fix overlapping region on my fancy laptop with a big screen
Spacing
C89 variables (yes I am that old)
2009-01-19 14:15:31 +00:00
Ryan McBride
99119d8697 Cleanup; get rid of crufty cur_ws and cur_region and replace with
root_to_reginon, which will always give a non-crufty result. Pass the
region to all keystroke handlers.

To allow for workspace commands in empty workspaces without full-force
focus-follows-mouse, track mouse-clicks on root windows and make them
override cur_focus in root_to_region().

Also, examples of more descriptive debug output for some handlers.
2009-01-19 09:05:02 +00:00
Ryan McBride
367ce80e69 Major churn for multi-headed support (Xrandr and plain multi-screen).
- workspaces now per-screen (X does not let you migrate windows)
- a screen has 1 or more regions (now mapped by Xrandr, later configurable)
- current_ws is dead, long live cur_focus
	- only one window has real focus, but workspaces keep track ws->focus
	- lots of places (especially event handlers) use cur_focus but should
	  identify the correct source of the event instead
- festival of pointer management to keep track of all this.
2009-01-19 05:48:11 +00:00
Marco Peereboom
ec3c0150e3 Kill some braces and shorten code a bit 2009-01-19 03:30:39 +00:00
Marco Peereboom
ee14295710 Unscrew colors on machines that use 16 bit color. I am talking to you
zaurus and sparc!

from dwc
2009-01-18 23:53:03 +00:00
Marco Peereboom
683a0c71ea Stop farting around with dialog box potential sizes and make it a ratio.
This ratio can be configured in the .conf file.
2009-01-18 04:48:04 +00:00
Marco Peereboom
cae2f7f137 Make floaters work right. This fixes the remaining issues.
Note: firefox sucks for having that retarded "download complete" window
use "Download Statusbar" to disable that.  Really you want to.
2009-01-18 03:30:51 +00:00
Marco Peereboom
519a608c74 Correct XInput for managed windows so that mplayer syops whining about the
mouse mask.
2009-01-18 01:19:01 +00:00
Marco Peereboom
51fffe862e First attempt at doing pr0n! Mplayer now sort of works; switching between
ws while having floaters screws up.  Some more nits need to be resolved but
this is promissing enough.
2009-01-18 00:28:20 +00:00
Marco Peereboom
8ad832c092 somehow if( and for( remained in the code borrowed from dwm. Kill that dead. 2009-01-17 21:39:22 +00:00
Marco Peereboom
1ebdff4405 Fix fucking phantom windows for real this time. 2009-01-17 19:57:48 +00:00
Marco Peereboom
eb06e426f5 Fix phantom windows better by keeping transients; fixes mozilla restart
with dialog open.
2009-01-17 17:48:37 +00:00
Marco Peereboom
c721268c34 Fix stupid phantom windows during restart. 2009-01-17 17:44:10 +00:00
Marco Peereboom
04bda5eb2a Silly mcbride restarting the wm expecting it to be in the path.
Be more paranoid about managing windows.
2009-01-17 17:23:52 +00:00
Marco Peereboom
cb6004ccfa Keep focus on right window when cycling stack order. This does flicker
ugly when going to max stack.
2009-01-17 14:32:56 +00:00
Marco Peereboom
7de8cb229d When switching stacking keep focus on current win; from joris with tweaks.
This needs to be extended for all stack swtiches however the others are
being screwed up by autofocus events.  Those need to be eaten.
2009-01-17 14:17:09 +00:00
Marco Peereboom
ef4627ba2e This only took 2 days to debug :-(
But now we draw x-apps correctly like emacs, xpdf and gvim etc

Floaters need more love and mplayer is still unhappy (it worked at some
point!); getting it in so that others can get used to this.
2009-01-16 23:40:01 +00:00
Marco Peereboom
133514cd56 Cleanup and move some code to a more appropriate place. 2009-01-16 19:13:36 +00:00
Ryan McBride
fbde5d8373 Make max (maximized single window) layout handler mostly work. 2009-01-16 10:02:13 +00:00
Ryan McBride
f3aee6ce00 Allow resizing (alt-h / alt-l) the master area and resetting (alt-shift-space)
the layout to it's defaults, with per-workspace, per-layout persistence.
Also switch layout cycling to the "correct" key: alt-space
2009-01-16 07:27:26 +00:00
Ryan McBride
32a4812d88 Partly un-globalize workspace geometry.
Mostly mechanical work towards multi-head support and other goodies.
2009-01-16 05:25:13 +00:00
Marco Peereboom
fc8c63ffb7 Use hints to position and size floating windows. This is really a best
effort since a lot of these apps are a total clusterfuck.
2009-01-15 19:21:55 +00:00
Marco Peereboom
9888af9f7f When moving windows to an empty workspace make sure we focus on the window
that just moved there.
2009-01-15 17:27:34 +00:00
Marco Peereboom
eb4c85488d Forgot to remove debug. 2009-01-15 17:23:04 +00:00
Marco Peereboom
2d77968e8e Off by one pixel in horizontal stack. Some spacing. 2009-01-15 17:22:05 +00:00
Ryan McBride
0782d0971b Initial bits of support for different layouts, needs more splitting out of
common code.
Use alt-c to cycle for now, will change to alt-space once I figure that out.
2009-01-15 13:59:58 +00:00
Marco Peereboom
f5b4f5994e Probably a fat finger from mr McBride 2009-01-15 13:44:52 +00:00
Ryan McBride
4f0813c94d next/prev window swap logic that sucks less. 2009-01-15 08:27:56 +00:00
Ryan McBride
e6727e082a alt-j/alt-k = move focus to next/prev
alt-shift-j/alt-shift-k = swap focus window with next/prev
2009-01-15 06:41:06 +00:00
Marco Peereboom
0dc00b1a83 Yay fix old x apps that send events in different order. This fixes like
xclock & xcalc etc.
2009-01-15 03:50:26 +00:00
Ryan McBride
7718964fdb Reexec scrotwm on alt-q, also enumerate and manage all existing windows when
scrotwm starts.
2009-01-15 02:14:08 +00:00
Marco Peereboom
4f26b7c5ca center floaters 2009-01-14 22:21:52 +00:00
Marco Peereboom
840cd605d2 Add initial floating support and a forgotten makefile... 2009-01-14 22:06:48 +00:00
Marco Peereboom
3ddac044c0 Add unobscure event so that we can rebuild the bar after dmenu exits. 2009-01-14 19:38:24 +00:00
Marco Peereboom
58414f14f4 Add initial dmenu support with alt-p 2009-01-14 19:23:16 +00:00
Marco Peereboom
04f3b6a33c Some X apps work now such as gvim and firefox 2009-01-14 19:08:56 +00:00
Marco Peereboom
ee49baae87 Spacing 2009-01-14 17:14:05 +00:00
Marco Peereboom
b05bba3a0e Add .conf file support 2009-01-14 17:10:52 +00:00
Marco Peereboom
08c761d14b Fix last switchws bugglet where the bar appeared empty. 2009-01-14 14:25:19 +00:00
Ryan McBride
3a09255e9a Make sure all workspaces get restacked after the bar is toggled. 2009-01-14 07:24:05 +00:00
Marco Peereboom
433cf0a7cb Add alt-b for toggling tool bar. One little bug leftover when switching
between ws and toggling the bar.
2009-01-14 07:00:38 +00:00
Ryan McBride
3c32a5f62d Fix marco's fix of my pasto.
Also somewhat cleaner FOCUSPREV and FOCUSNEXT code.
2009-01-14 06:29:34 +00:00
Marco Peereboom
f28c13daf6 Fix mcbride pasto 2009-01-14 06:16:27 +00:00
Marco Peereboom
3574129dcc tick tick tick; sucks because it does it in the signal handler but i am
not smart enough to do this with a XSendEvent
2009-01-14 06:08:16 +00:00
Ryan McBride
ef5a4d70c7 Don't swap_to_main if no window has focus or main has focus. 2009-01-14 06:04:21 +00:00
Ryan McBride
0839929c3d Let mod-shift-N send a window to another workspace. 2009-01-14 05:48:18 +00:00
Ryan McBride
58096354b1 Complie with warnings, and cleanup.
- remove missing vars.
- add missing <strings.h>.
- the X11 Window type should be %lu in format strings.
2009-01-14 05:14:13 +00:00