On Thu, May 8, 2008 at 2:56 PM, Glenn Linderman <[EMAIL PROTECTED]> wrote: > On approximately 5/8/2008 6:05 AM, came the following characters from the > keyboard of Geoffrey Spear: >> >> On Thu, May 8, 2008 at 12:25 AM, Sylvain Thibault <[EMAIL PROTECTED]> >> wrote: >>> >>> When debugging inside EMACS, the gui never appears. Somehow win32::gui >>> is >>> not happy with STDOUT being redirected to EMACS instead of a console >>> window. Perl tk gui programs work fine from inside EMACS. Any >>> workaround ? >>> >>> Thanks. >> >> I've never had any problem at all running Win32::GUI programs from a >> *shell* buffer (with cmd.exe as the shell). Have you done any unusual >> emacs customization? > > > I marked the OPs message as interesting, because I thought I have had that > problem too... > > Because the perl debugger didn't seem to work with emacs for GUI programs > (or maybe I was too dumb to figure out how), I have mostly not used the perl > debugger, but instead have used the old "printf" style of debugging, when > needed... > > I was surprised, after you message to learn that I could run > win32-gui-demos.pl from the shell window, so then I launched it in the > debugger. Doing a single "c" command takes me to the point in perl5db.pl > where it says "Debugged program terminated". No win32-gui-demos.pl window > appeared on the screen (but it did when running from the *shell* buffer). > > So I don't know if the problem is: > > 1) my ignorance of the perl debugger > 2) my ignorance of how to use the perl debugger with Win32-GUI > 3) a limit in Win32-GUI > 4) a limit in perldb > 5) a limit in emacs > > Because of the plethora of choices there, and given the alternative of using > brains and printf to compensate, I've never pursued figuring out whether or > not it is possible to get this combination working. > > Help welcome.
I missed the OP's mention of "debugging" and didn't even think of perldb, but it's definitely the case that Win32::GUI doesn't care where the script's output is going (which isn't surprising because AKAIK Win32::GUI itself never sends anything to STDOUT and if having it redirected broke things that would be incredibly weird.) Using perl -d in a shell buffer seems to work ok, except that the debugger stops the program if I close an MDI child window in my program. The GUI certainly appears, though. Trying M-x perldb myself seems to consistently fail just because it's unable to figure out what to do with a path containing spaces, which is kind of annoying since every other emacs function dealing with files works perfectly fine in those cases. ------------------------------------------------------------------------- This SF.net email is sponsored by the 2008 JavaOne(SM) Conference Don't miss this year's exciting event. There's still time to save $100. Use priority code J8TL2D2. http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone _______________________________________________ Perl-Win32-GUI-Users mailing list Perl-Win32-GUI-Users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/perl-win32-gui-users http://perl-win32-gui.sourceforge.net/