http://qs321.pair.com?node_id=1058275


in reply to Perl tk gui hangs when large data thrown to it

G'day ghosh123,

"I can not put the entire code here, but i am putting some snippets of it to explain you better :"

Please post a minimal example which reproduces your problem. Creating such an example will often highlight the problem and possibly even present a solution.

Putting bits of code here doesn't really help. For instance, I could say that "[ \&checkData, $self, $server, $readable_handles ]" is problematic because "sub checkData { ... }" doesn't accept any arguments. I have no way of knowing whether that subroutine really doesn't accept any arguments or if that was just some of the code you chose to omit.

"It also using Tk's repeat to continuously check whether any data has arrived to update the gui."

Tk::fileevent is probably a more appropriate tool for this task.

-- Ken