Help for this page

Select Code to Download


  1. or download this
    my $server = IO::Socket::INET->new(
        LocalPort => 7777,
    ...
        Listen => 10
    );
    $mw->Tkx::fileevent($server, 'readable', sub { new_connection($server)
    + });
    
  2. or download this
    my $fh = Tkx::open("| @cmds <$null 2>\@1");
    Tkx::fconfigure($fh, -blocking => 0);
    Tkx::fileevent($fh, readable => [\&readdata, $fh]);