nanogui: Resize/move window


Previous by date: 11 Jun 2001 23:54:08 -0000 Re: Problem in repaint, Jordan Crouse
Next by date: 11 Jun 2001 23:54:08 -0000 Re: Problem in repaint, Greg Haerr
Previous in thread: 11 Jun 2001 23:54:08 -0000 Re: Resize/move window, Jordan Crouse
Next in thread:

Subject: Re: [nanogui] Resize/move window
From: "Greg Haerr" ####@####.####
Date: 11 Jun 2001 23:54:08 -0000
Message-Id: <04ee01c0f2d1$8cfdbde0$3aba46a6@xmission.com>

: How to catch an event of resizing/moving window? It seems that
GR_EVENT_TYPE_UPDATE is not doing that. For resizing, it works in
GR_EVENT_TYPE_EXPOSURE, but it doesn't help for moving.

Update events are sent for both moves and resizes, but the setup
can change depending on whether you're running the window
manager, and whether you know the window id or not.

For the basic case, GrSelectEvents(wid, GR_EVENT_MASK_UPDATE)
is called.  This works only in the event loop of the window creating
the window, since you've got to know the window id.  If you're
wanting to catch resize/move events for other windows, select for
child update events on the root window, which will catch the window
manager's windows:  GrSelectEvents(1, GR_EVENT_MASK_CHLD_UPDATE).
You then catch child update events, rather than update events.

In 0.89pre7 and above, Microwindows sends update events recursively
to all child windows as well.

Exposure events are only sent when the screen needs repainting, which
occurs in the resize case only when the window is resized larger.

Regards,

Greg


Previous by date: 11 Jun 2001 23:54:08 -0000 Re: Problem in repaint, Jordan Crouse
Next by date: 11 Jun 2001 23:54:08 -0000 Re: Problem in repaint, Greg Haerr
Previous in thread: 11 Jun 2001 23:54:08 -0000 Re: Resize/move window, Jordan Crouse
Next in thread:


Powered by ezmlm-browse 0.20.