Re: globalx/globaly

Charles Goodwin <[email protected]> Wed, 24 Mar 2004 14:41:56 +0000
Newsgroups gmane.comp.java.xwt.core
Organization XWT Foundation
Message-ID <[email protected]>
On Fri, 2004-03-19 at 07:32 +1000, David Crawshaw wrote:
> Big fan of relativistic thinking, but I you still need to be able to 
> find your position relative to your root box. This serves more purpose 
> than the difference between two boxes, it represents the 'active 
> visible surface'.
> 
> That said, if a function did give you the relative position between two 
> boxes, we could then build a globalx, gloably, globalwidth, 
> globalheight into the surface object in the widget library by comparing 
> the root (be it real or fake) with that of the child.

It'd be just as easy to produce a 'relative' approach using globalx/y
as it would using a relative approach to give globalx/y.

The main problem would be making globalx/y work with fake root windows,
which would force the same kind of approach as you'd take with dx/dy -
providing some form of overlay for the default box template.  I suggest
that we do the same thing for box that we do for surface:

Preapply a default template, the obvious choice being ibex.theme.box
(since we use ibex.theme.surface), to all instances of ui:box.

Having gotten bored of waiting ;) I'm fixing a few Box.java issues and
will make globalx/globaly work properly as a stop-gap.
-- 
- Charlie

Charles Goodwin <[email protected]>
Online @ http://www.charlietech.com