[416] in Zephyr_Bugs

home help back first fref pref prev next nref lref last post

Re: [Dave Glowacki: Re: [Marc Horowitz: Re: zwgc vs. tvtwm] ]

daemon@ATHENA.MIT.EDU (Dave Glowacki)
Tue Oct 6 21:59:55 1992

From: dglo@CS.Berkeley.EDU (Dave Glowacki)
To: Marc Horowitz <marc@MIT.EDU>
Cc: John T Kohl <jtkohl@cs.berkeley.edu>, zephyr-bugs@MIT.EDU
In-Reply-To: Your message of "Sat, 03 Oct 92 04:36:53 CDT."
Date: Tue, 06 Oct 92 18:59:17 PDT

> >> After Mr. Horowitz' message, it became a point of honor to find the
> >> problem :-)
> 
> I don't even remember what I said :-)  Could you send me a copy?

I don't have the message any more ... but you were impugning my
window manager, so I felt honor-bound to clear its name...

> >> 'zwgc' is setting size and position hints for the window manager but
> >> claiming that they're from the *user* instead of from a *program*.
> >> Obviously, vtwm doesn't distinguish between the two but tvtwm does.
> 
> vtwm *does* distinguish between the two.  empirically (determined by
> playing around, not reading source), if the location is
> user-specified, then the wm just puts the window there, and if it's
> program-specified, then the wm rubber-bands for the location.  That's
> for a normal top-level window; transients may be different.

It's quite probable that tvtwm behaves that way as well (after all,
it's using the same base as vtwm.)  Does 'RandomPlacement' affect
this?  

> >> A more X-ish solution might be to have a resource, something subtle
> >> like 'wm-is-spineless', which could be set if the window manager
> >> didn't handle program-positioned windows.  zwgc could check this
> >> resource to decide which type of hint to give...
> 
> It's a little more complicated than that.  One could claim that zwgc
> should tell the absolute truth: always set PSize, and set USPosition
> if the geometry of the zgram is derived from the user, via a resource
> or desc file variable, or PPosition if it's just using the default.
> But one could also claim that zgrams should always map w/o user
> intervention, which would mean setting USSize|USPosition.
> 
> So, the real questions are:
> 
> 1) what is tvtwm's behavior for different hints?

First some background ... from my minimal understanding of tvtwm,
it creates a virtual root window of whatever size the user
specifies, and then maps windows onto that.  Thus there are two
roots:  the normal X root window (which I'll refer to as the
absolute root window) and tvtwm's virtual root window.  The
displayed root window is just an offset into this virtual root.

If it's a program-specified position, tvtwm assumes that the program
*really* wants create a visible window, so it'll bring it up at the
specified position, but relative to the displayed root window.
If it's a user-specified position, however, tvtwm assumes that the
user REALLY, REALLY wanted the window at that position, so it'll
bring up the window at that position relative to the absolute root
window.

To me, this seems like a reasonable use of those hints...

> 2) what behavior (independent of wm) do you want zwgc to have?

I guess I'd like to see zwgc default to PPosition.  It seems like
it's the window manager's fault if it ignores perfectly good
position hints.

But then, this is the behavior that'd be most beneficial to me.
I'm sure current Zephyr users who'd get hosed by this change would
have a different opinion :-)

I guess at a minimum, I'd like the position hint type to be
settable in *some* way.  X resource or command line option, doesn't
matter to me.  I just want a way to make zwgc useable under tvtwm.

> The answers to these questions (modulated by my whims as the
> programmer ;-) determines if a new resource is appropriate.

How do bribes factor into the equation? :-)

home help back first fref pref prev next nref lref last post