themax90 Posted November 4, 2007 Posted November 4, 2007 Local $Pos = MouseGetPos() $ColorGUI = GUICreate("Color", @DesktopWidth/8, @DesktopHeight/8, $Pos[0], $Pos[1]) _GuiRoundCorners ($ColorGUI, 0, 0, @DesktopWidth/4, @DesktopHeight/4) _GuiHole($ColorGUI, 10, 10, @DesktopWidth/4) GUISetState() expandcollapse popupFunc _GuiHole($h_win, $i_x, $i_y, $i_size) Dim $pos, $outer_rgn, $inner_rgn, $wh, $combined_rgn, $ret $pos = WinGetPos($h_win) $outer_rgn = DllCall("gdi32.dll", "long", "CreateRectRgn", "long", 0, "long", 0, "long", $pos[2], "long", $pos[3]) If IsArray($outer_rgn) Then $inner_rgn = DllCall("gdi32.dll", "long", "CreateEllipticRgn", "long", $i_x, "long", $i_y, "long", $i_x + $i_size, "long", $i_y + $i_size) If IsArray($inner_rgn) Then $combined_rgn = DllCall("gdi32.dll", "long", "CreateRectRgn", "long", 0, "long", 0, "long", 0, "long", 0) If IsArray($combined_rgn) Then DllCall("gdi32.dll", "long", "CombineRgn", "long", $combined_rgn[0], "long", $outer_rgn[0], "long", $inner_rgn[0], "int", 4) $ret = DllCall("user32.dll", "long", "SetWindowRgn", "hwnd", $h_win, "long", $combined_rgn[0], "int", 1) If $ret[0] Then Return 1 Else Return 0 EndIf Else Return 0 EndIf Else Return 0 EndIf Else Return 0 EndIf EndFunc ;==>_GuiHole Func _GuiRoundCorners($h_win, $i_x1, $i_y1, $i_x3, $i_y3) ; Written by gafrost. Local $XS_pos, $XS_ret, $XS_ret2 $XS_pos = WinGetPos($h_win) $XS_ret = DllCall("gdi32.dll", "long", "CreateRoundRectRgn", "long", $i_x1, "long", $i_y1, "long", $XS_pos[2], "long", $XS_pos[3], "long", $i_x3, "long", $i_y3) If $XS_ret[0]Then $XS_ret2 = DllCall("user32.dll", "long", "SetWindowRgn", "hwnd", $h_win, "long", $XS_ret[0], "int", 1) EndIf EndFunc ;==>_GuiRoundCorners Disables the effect of the other. Bug works vice-versa.
GaryFrost Posted November 4, 2007 Posted November 4, 2007 Moved to Support, I believe you would have to create your own custom function which combines the two. SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
themax90 Posted November 5, 2007 Author Posted November 5, 2007 Bump. I don't know much about GUI manipulation - can anyone make a combined function real quick for me.
Thatsgreat2345 Posted November 5, 2007 Posted November 5, 2007 Bump. I don't know much about GUI manipulation - can anyone make a combined function real quick for me. www.rentacoder.com
_Kurt Posted November 5, 2007 Posted November 5, 2007 www.rentacoder.comPerhaps if someone were to request a program with specific functions, but in this case, I really don't think that was necessary. From what I have read from AutoitSmiths posts, he's not a GUI-expert, but a TCP-IP expert . Kurt Awaiting Diablo III..
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now