Re: Q: Resizing Fixeds
- From: Kenneth Albanowski <kjahds kjahds com>
- To: Owen Taylor <otaylor fresnel labs redhat com>
- cc: gtk-list redhat com
- Subject: Re: Q: Resizing Fixeds
- Date: Sat, 6 Feb 1999 16:49:16 -0500 (EST)
On 6 Feb 1999, Owen Taylor wrote:
> Hmmm, the following program works as expected for me. There
> are a few sophistications in there to get the minimum size
> to behave in a more natural way, but they won't affect
> what you are looking at.
>
> The allocate callback does get called twice, because
> gtk_widget_set_usize queues a resize and the configure
> event will also cause a resize to happen, but both
> of them occur with the correct size. Assuming that
> the GLArea doesn't do too much work in "size_allocate",
> or alternatively, checks first if the size actually
> changed, this should be pretty harmless.
Nope. Using this exact code (as well as a Perl equivalent), I do get
allocate called twice, but when I resize the window, allocate is called
again with the _same_ size, 100x100. Let me show you:
Start program you listed:
New allocation 0 x 0
New allocation 100 x 100
Resize window to triple size:
New allocation 100 x 100
Tweak window size:
New allocation 303 x 337
Halve window size:
New allocation 307 x 342
Tweak window size:
New allocation 148 x 169
It's clearly lagging one step -- but this isn't actually visible with the
drawing area. This is with Gtk+-1.1.14, and XFree86 3.something.
--
Kenneth Albanowski (kjahds@kjahds.com, CIS: 70705,126)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]