Seeking resize solutions

Dean Arnold <[email protected]>
Newsgroups gmane.comp.lang.perl.tk
Message-ID <[email protected]>
(WinXP, AS 5.8.3, TK 804.027 + patches)

Hoping someone can help; this is a bit of a repost of an issue
I had with DynaTabFrame back during the Tk804 beta that has reared
its head again. Note that the issue occured on both WinXP and
Linux, so I'm inclined to believe its either something silly
in my code, or something odd in pTk itself.

I'm trying to redraw the tabs for DTF when the window is resized,
stacking/unstacking as needed. Initially, I was having an issue with
just the width being incremented by 12 pixels in a vicious cycle,
ie,

- get the Config event
- post a debounce timer (so I'm not redrawing everything all the time), 
- then redraw when the timer fires.

All well and good, except after the initial redraw, even when there
are no tabs to draw, I get "phantom" Config events that seem to
recycle the same width/height increments,
which causes my redraws to keep expanding the window ad nauseum,
even if there are no tabs defined.
I managed to solve this by using a width threshold of 13 pixels,
so these phantoms would be ignored (tho I think that's been
causing another issue).

Now I'm trying to implement support for tabs on the sides, which
would require redrawing when the window height changes, and I'm
getting the phantoms again, except that the recycled heights
don't seem quite as predictable as the width, and are relatively
large (50 - 80 pixels).

Does anyone have a solution to this issue that will
clamp the Config events ? My debouncer doesn't seem to help,
regardless of the delay I use. As far as sample code, I can
only point to the current Tk::DynaTabFrame - just look
at ConfigDebounce() and reduce the width threshold below
13.

TIA,
Dean Arnold
Presicient Corp.
-++**==--++**==--++**==--++**==--++**==--++**==--++**==
This message was posted through the Stanford campus mailing list
server.  If you wish to unsubscribe from this mailing list, send the
message body of "unsubscribe ptk" to [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.