darendeli Posted June 28, 2017 Share Posted June 28, 2017 Gui Finder i kullanarak coordinat ve pixel rengini almak istiyorum kütüphanesinde degisiklik mi yapmak gerekli sürükleyip bırakınca biriyle coordinat biriyle renk almak istiyorum #include<GUIFinder.au3> $hGUI = GUICreate("guifinder deneme", 300, 100) $hFinder = _GUICtrlFinder_Create($hGUI, 230, 4) $Input1 = GUICtrlCreateInput("", 5, 10) $hFinder2 = _GUICtrlFinder_Create($hGUI, 230, 54) $Input1 = GUICtrlCreateInput("", 5, 60) GUISetState(@SW_SHOW) GUISetState() While True $iMsg = GUIGetMsg() Switch $iMsg Case -3 ExitLoop EndSwitch WEnd Quote Link to comment Share on other sites More sharing options...
blackman12 Posted July 16, 2017 Share Posted July 16, 2017 Merhaba, GuiFinderin örneklerinden kullanarak şöyle birşey yazdım sizin için arkaplan rengi derken pencerenin arkaplan rengi her yerde farklı olabilir o biraz sağlıksız oldu bilesiniz. #include <Array.au3> #include<GUIFinder.au3> Global $son = "" $hGUI = GUICreate("guifinder deneme", 300, 100) $hFinder1 = _GUICtrlFinder_Create($hGUI, 230, 4) $hBtn1 = GUICtrlCreateButton("Konum/Renk Bul!", 130, 4, 90, 25) $Input1 = GUICtrlCreateInput("", 4, 5,120,23) GUISetState(@SW_SHOW) GUIRegisterMsg($WM_COMMAND, "WM_COMMAND") While True $iMsg = GUIGetMsg() Switch $iMsg Case -3 ExitLoop Case $hBtn1 _GUICtrlFinder_SetLastWnd($hFinder1, $hGUI) if IsHWnd($son) and Kontrol() then $Position = WinGetPos ($son) MsgBox(0,"Sonuç: "&WinGetTitle($son),"Pencerenizin pozisyonu:"&@CRLF&@CRLF&"X: "&$Position[0]&@CRLF&"Y: "&$Position[1]&@CRLF&"Genişlik: "&$Position[2]&@CRLF&"Yükseklik: "&$Position[3]&@CRLF&@CRLF&"Arkaplan Rengi: "&Hex(PixelGetColor(1,1,$son), 6)) EndIf EndSwitch WEnd Func WM_COMMAND($hWnd, $iMsg, $wParam, $lParam) Switch _WinAPI_HiWord($wParam) Case $FN_ENDUSE $son = _GUICtrlFinder_GetLastWnd($lParam) EndSwitch EndFunc Func Kontrol() Local $aList = WinList() For $i = 1 To $aList[0][0] If $son = $aList[$i][1] Then Return True EndIf Next Return False EndFunc 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.