I'm still learning perl/Tk myself, but ran into something similar recently. I wasn't sure which "entry widgets" you were referring to, but could think of two things that may be of help for you. For both, I will refer to this example:

my $myscale = $mw->Scale( -from => 2, -to => ( $dx - 1 ), -orient => 'horizontal', -label => 'Drawn X:', -variable => \$a_dx )->grid();

First thing you may wish to look at is that several types of widgets have the property of being able to be associated to a variable reference (such as the -variable option above, or the -textvariable option for Entry widgets), so that (as I understand it) updating the contents of the variable results in an update of the value displayed for them.

Another thing you may want to look at the configure function for Tk widgets. For instance, say you have a scale object defined as follows: and you update $dx, and want the maximum scale for it to change as well. In that case, you could do the following:

$myscale->configure( -to => ($dx - 1) );
which would change the -to configuration item for that scale.

Hope that helps....

Update: (2004-04-30) - Reorganized order suggestions were presented, after re-reading and seeing that the original latter seemed potentially more applicable to the OP.


In reply to Re: Problem refreshing TK window after file update by atcroft
in thread Problem refreshing TK window after file update by CorpusDawg

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.