Beefy Boxes and Bandwidth Generously Provided by pair Networks Joe
The stupid question is the question not asked

Comment on


There does not appear to be a lot of examples of Tkx specific code snippets out there, especially the basics. Hopefully this helps someone.

#! /usr/bin/perl -w # # # A basic demonstration of time-based refresh using the tkx wrapper # for TK. # Includes a single text label containing an incrementing # number along with a basic progress bar. use strict; use warnings; use Tkx; my $tic = 0; my $mainwindow = Tkx::widget->new("."); my $label = $mainwindow->new_ttk__label(-textvariable => \$tic)->g_pac +k; my $progress_bar = $mainwindow->new_ttk__progressbar( -orient => "horizontal", -mode => "indeterminate", -length => "200", -maximum => "50", -variable => \$tic, )->g_pack; &tix; #first call to increment subroutine Tkx::MainLoop(); sub tix { #increment sub $tic++; Tkx::after(500, \&tix); # after 500ms re-run this sub. }

In reply to TKX Time events using After by Pherry

and:  <code> code here </code>

  • Please read these before you post! —
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Log In?

    What's my password?
    Create A New User
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others lurking in the Monastery: (7)
    As of 2014-03-14 02:54 GMT
    Find Nodes?
      Voting Booth?

      Have you used a cryptocurrency?

      Results (297 votes), past polls