in reply to manipulating window positions on Win7

.. i would like to see some working code about the topic, if you have the time to share it LanX.
In fact this is the only code i 've ever done with Win32::GuiTest, a simple screen grabber, but i'm reather interested by the topic.
L*
#!/usr/bin/env perl use strict; use warnings; use Const::Fast; use Imager; use Imager::Screenshot qw( screenshot ); use Win32::GuiTest qw( FindWindowLike SetForegroundWindow ); const my $TYPE => 'bmp'; #my $TYPE = 'bmp'; my @windows = FindWindowLike(0, '(?:Chrome)|(?:Firefox)|(?:Opera)' ); for my $hwnd (@windows) { warn "$hwnd\n"; SetForegroundWindow $hwnd; sleep 1; my $img = screenshot(hwnd => $hwnd, decor => 1); die Imager->errstr unless $img; $img->write(file => "$hwnd.$TYPE", type => $TYPE) or die $img->errstr; }
There are no rules, there are no thumbs..
Reinvent the wheel, then learn The Wheel; may be one day you reinvent one of THE WHEELS.

Replies are listed 'Best First'.
Re^2: manipulating window positions on Win7
by LanX (Saint) on May 15, 2015 at 10:55 UTC
    Thanks that's a start. My minimal goal is to switch between snapshots of certain windows.

    I'm on holiday, gonna try it from Monday on. :)

    Cheers Rolf
    (addicted to the Perl Programming Language and ☆☆☆☆ :)
    Je suis Charlie!