Hello.  It seems that between build 340 and 425 some of the Win32::GUI::*
  stuff broke.

  Below is a small program that prints values under 340 but not under 425.
  Specifically, these items don't work or don't work the way they use to:
  
        $Win->GetWindowRect();
        Win32::GUI::GetWindowRect($Win->{$child});
        Win32::GUI::GetClassName($Win->{$child});
        Win32::GUI::Height($Win->{$child});
        Win32::GUI::Width($Win->{$child});
        Win32::GUI::Text($Win->{$child});

  --------------------------------------------------------------------

use Win32::GUI;

$Win = new Win32::GUI::Window(
        -left   => 10,
        -top    => 10,
        -width  => 50,
        -height => 100,
        -name   => "Window",
        -text   => "Test"
);

$Win->Show();

$w = $Win->AddButton(
      -text => "OK",
      -name => "OK",
      -left => 30,
      -top  => 20,
     );

Win32::GUI::Dialog();

#----------------------------------------------------
sub OK_Click {

   ($w_left,$w_top,$w_right,$w_bottom) = $Win->GetWindowRect();

   foreach $child (keys %{$Win}) {
      if ($child =~ /^-/) {
         next;
      }
      else {
         ($left,$top,$right,$bottom) = Win32::GUI::GetWindowRect($Win->{$child});

         ($classname) = Win32::GUI::GetClassName($Win->{$child});

         ($height) = Win32::GUI::Height($Win->{$child});
         ($width) = Win32::GUI::Width($Win->{$child});

         ($text) = Win32::GUI::Text($Win->{$child});
 
         print "
child     = $child 

left      = $left
top       = $top
right     = $right
bottom    = $bottom
classname = $classname
height    = $height
width     = $width
text      = $text
";
        }
     }
}

Reply via email to