Re: geometry calculation delayed until ... when?



On Sun, Jul 28, 2002 at 05:10:03PM -0700, Frank Cusack wrote:
On Sat, Jul 27, 2002 at 10:22:25AM +0100, Axel Simon wrote:
Or is the above just fine?  I don't actually see it displayed in the 
incorrect location then moved.
Redrawing is done in an idle handler in the main loop. So this moving of 
windows will never show AFAIK.

I tried both widget_realize() and widget_size_request().  Both get the
width correct but the height wrong.

So I'll just do the show() which gets both correct.

BTW,

    show_all(box) ;
    [ get geometry, calculcate new position ]
    set_position(box, POS_NONE);
    set_uposition(box, x, y);
    show_all(box)

does display the widget and then you see it move.

If I move the set_position(POS_NONE) call before the first show_all(),
then you don't see the box until the new location is set.  (In the
original email with sample code, that's what I had which is why I didn't
notice this behavior before.)

/fc



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