Subject: | Tk::Wm::attributes does not work |
There are reports in the comp.lang.perl.tk newsgroup that $mw->attributes(-topmost) does not work on Windows. On Linux I get the following error:
$ /usr/perl5.8.4d/bin/perl -MTk -e 'tkinit->attributes(-topmost)'
bad window path name "-topmost" at /usr/perl5.8.4d/lib/site_perl/5.8.3/i686-linux/Tk/Submethods.pm line 37.
Exit 255
It seems that the problem is due to the argument reordering in XStoSubCmd. The reordering is done so that the widget reference is put after the first option. This is correct for Tk::grab, but incorrect for Tk::wm("attributes"). Possible solution: create a XStoWmCmd function which does simple reordering without looking at options.
Regards,
Slaven