| [reply] |
A question for you, how far does your program go before the Tcl error shows up? Devel::Trace
Reminds me of Re^3: TKX and closing windows (bug) ..
L'anana ne parlais pas .... so this is the way I'd structure the program to avoid any Tkx noise .... I don't see an use for Thread::Semaphore
As you can see, the more well named subs you have, the less comments you need
See also Ask - ask your users about stuff / ask-introduction.pod
You can use utf8 to signal to perl that your file is written in utf8, so you don't have to decode("utf8" all over the place
Also see Win32::Unicode::Native since I assume you're on win32 ... for unicode version of mkdir/open... so you don't have to encode("iso-8859-1" ...
Also, if you still need to encode("iso-8859-1" .... don't do it all over the place (repetition hurts your fingers), do it in one helper subroutine, say in recup_fic or MyMkdir ...
I would also consider my $answer = YesNo( "question", "title" ); and ReadThis( $msg, $title ); ... although Info( $msg, $title ); sounds good .... there is a Ask::Tk, a Ask::Tkx should be only a few tweaks to that
| [reply] [d/l] [select] |
| [reply] |
PS
the use of Semaphore is in the "sub recup_fic" to avoid more than 5 threads when i save the nearly 30 files of the "@lst_log"
| [reply] |
While I'm working on some code, take a look at these, I believe they deal with same problem (not enough subs, too many comments, pattern for using threads, que, gui toolkit) ... Re: Win32::GUI window freezing, even with threading. (win32-gui-tk-thread-dequeue.pl, Thread::Queue::popnow/push) + Re^4: Win32::GUI window freezing, even with threading. (Wrong solution), Re: Tk: Creating label in hash, Re: perl Tk thread help, Re: error on file open, Re^4: Query the height of Tk::Text widget with word wrap
| [reply] |