Re: I need tiling of windows...



Hi Pat,

 Pat> On 01/02/2010 06:52 PM, dmg wrote:
 >> All i need is to be able to tile 2 windows. More than that, I dont'
 >> really see how useful it would be.
 >> I have been using my quadrants hack, and it works well, but sometimes
 >> it would be easier to just
 >> tile all windows at once instaed of one at a time.

 Pat> I'm working on something related.  I've been using a big ugly home
 Pat> made script that accomplished something similar to your
 Pat> dmg-quadrants.jl.

 Pat> I have the left 1/3 (or so) of my screen divided into 3 quadrants.
 Pat> One of my primary uses for those particular quadrants is Pidgin chat
 Pat> windows.  I have two problems with this.  It is fairly manually, I
 Pat> have to choose a quadrant for each new chat.  It also breaks down when
 Pat> I (rarely) need to have more than 3 chat windows open...

You got me thinking...

the problem with my quadrants mode is that it is absolute coordinates,
But proportional coordinates seem to be more adequate some times. 

ANother enhancement to quadrants would be to save the quadrant in the
window, so if the quadrants get resized then the window can be
resized. Even more, to be able to get a window to a quadrant by class or
title (this is trickier, though, as sometimes we want windows of the
same application to different quadrants).

So it would be nice to have quadrants defined (say the 3, one third
each) and then ask sawfish to send the current windows to the closest
quadrant, effectively tiling.n


 Pat> What I think I want to do is define a single vertically "tiled"
 Pat> quadrant instead.  I figure I'd assign one binding for the quadrant.
 Pat> Every time a window is pushed into that quadrant it should resize any
 Pat> window that is already there to fit.

I do something like this with dmg-quad-send. You are asked for a quad, and
the current window sent to it and resized to fill it.


 Pat> My ugly script already half way accomplishes this.  My script lets me
 Pat> assign multiple quadrants to the same bind.  With my current script,
 Pat> if a window is already in the top-corner 1/3 by 1/3 quadrant and I hit
 Pat> the bind for that quadrant again...  It expands out to the next
 Pat> quadrant which is 1/3 by 1/2.  The lower corner bind does the same
 Pat> thing in that corner.

 Pat> I'm horrible at lisp.  I started writing this out from scratch but I'm
 Pat> realizing that I would probably do better grafting this on to your
 Pat> dmg-quadrants.

I am not much better, but I like the idea to get quadrants better. It is
a quick hack as it stands.

 Pat> My ugly script does one other unrelated, but interesting, thing.  It
 Pat> sets the font size of my terminals based on quadrant.  I find
 Pat> terminals under 80x25 and too far over 80 columns wide to be pretty
 Pat> useless most of the time.

Mmm, I guess we can have hooks for after a window is sent to a quad,
they are executed. I kind of like that.

 Pat> I've only been thinking about this and throwing code around for the
 Pat> last couple of days.  I figured that since I saw that you're
 Pat> interested in something similar that now would be a good time to throw
 Pat> my thoughts out here :)

 Pat> Pat


-- 
--
Daniel M. German                  
http://turingmachine.org/
http://silvernegative.com/
dmg (at) uvic (dot) ca
replace (at) with @ and (dot) with .


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]