Jump to content
Sign in to follow this  
Nahuel

Help with magnifier function

Recommended Posts

Nahuel

I'm using this brilliant script by Larry to make a script. I'd like to know if I can make the magnifier window just like the one that Autoit window info tool has:

Posted Image

I need it like that because it would give me more accuracy for what I want to do.

here's Larry's script:

Global $SRCCOPY = 0x00CC0020
Global $leave = 0

HotKeySet("{PAUSE}","leave")

SplashTextOn ( "AU3MAG", "" , 100 , 100 , 0, 0, 1 )
$MyhWnd = WinGetHandle("AU3MAG")

While Not $leave
  Sleep(25)
  MAG()
WEnd

Func MAG()
  $MyHDC = DLLCall("user32.dll","int","GetDC","hwnd",$MyhWnd)
  If @error Then Return
  $DeskHDC = DLLCall("user32.dll","int","GetDC","hwnd",0)
  If Not @error Then
     $xy = MouseGetPos()
     If Not @error Then
        $l = $xy[0]-10
        $t = $xy[1]-10
        DLLCall("gdi32.dll","int","StretchBlt","int",$MyHDC[0],"int",_
                    0,"int",0,"int",100,"int",100,"int",$DeskHDC[0],"int",_
                    $l,"int",$t,"int",20,"int",20,"long",$SRCCOPY)
     EndIf
     DLLCall("user32.dll","int","ReleaseDC","int",$DeskHDC[0],"hwnd",0)
  EndIf
  DLLCall("user32.dll","int","ReleaseDC","int",$MyHDC[0],"hwnd",$MyhWnd)
EndFunc

Func leave()
  $leave = 1
EndFunc

Share this post


Link to post
Share on other sites
Fossil Rock

I think SmoKe_N made one like that ... don't remember where it is. Look in the Example scripts.


Agreement is not necessary - thinking for one's self is!

My-Colors.jpg

cuniform2.gif

Share this post


Link to post
Share on other sites
Nahuel

Thanks. I'll see if I can find it. Maybe I'll ask Larry, he must know.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×