#include <Icons.au3>
#include <WinAPIEx.au3>
#include <GUIConstantsEx.au3>
HotKeySet('{Esc}', '_Exit')
$hParent = GUICreate('', 0, 0, 0, 0, 0, $WS_EX_TOOLWINDOW)
$hMain = GUICreate("Transparent", 586, 285, -1, -1, $WS_POPUP, $WS_EX_LAYERED, $hParent)
GUISetBkColor(0x000080)
$nPic = GUICtrlCreatePic('', 0, 0, 586, 285)
GUICtrlSetState(-1, $GUI_DISABLE)
_SetImage($nPic, @ScriptDir & '\1660807.png')
GUISetState(@SW_SHOW, $hMain)
_WinAPI_SetLayeredWindowAttributes($hMain, 0x000080, 0, $LWA_COLORKEY)
GUIRegisterMsg($WM_NCHITTEST, 'WM_NCHITTEST')
While 1
Sleep(50)
WEnd
Func _Exit()
Exit
EndFunc ;==>_Exit
Func WM_NCHITTEST($hWnd, $msg, $wParam, $lParam)
Local $iProc = DllCall('user32.dll', 'int', 'DefWindowProc', 'hwnd', $hWnd, 'int', _
$msg, 'wparam', $wParam, 'lparam', $lParam)
If $iProc[0] = $HTCLIENT Then Return $HTCAPTION
Return $GUI_RUNDEFMSG
EndFunc ;==>WM_NCHITTEST
Картинку обрежьте и цвет подберите.ещё бы избавиться от синего контура и жирного куска пикселей слева
#Include <GDIPlus.au3>
#Include <WinAPIEx.au3>
_GDIPlus_Startup()
$hPng = _GDIPlus_ImageLoadFromFile(@ScriptDir & '\1660807.png')
$hBitmap = _GDIPlus_BitmapCreateHBITMAPFromBitmap($hPng)
$hForm = GUICreate('', _GDIPlus_ImageGetWidth($hPng), _GDIPlus_ImageGetHeight($hPng), -1, -1, $WS_POPUPWINDOW, $WS_EX_LAYERED)
_WinAPI_UpdateLayeredWindowEx($hForm, -1, -1, $hBitmap, 255, 1)
_GDIPlus_ImageDispose($hPng)
_GDIPlus_Shutdown()
GUIRegisterMsg($WM_NCHITTEST, 'WM_NCHITTEST')
GUISetState()
Do
Until GUIGetMsg() = -3
Func WM_NCHITTEST($hWnd, $iMsg, $iwParam, $ilParam)
Switch $hWnd
Case $hForm
Return $HTCAPTION
EndSwitch
Return $GUI_RUNDEFMSG
EndFunc ;==>WM_NCHITTEST
#Include <ComboConstants.au3>
#Include <GDIPlus.au3>
#Include <GUIConstantsEx.au3>
#Include <WinAPIEx.au3>
Global Const $SC_DRAGMOVE = 0xF012
_GDIPlus_Startup()
$hPng = _GDIPlus_ImageLoadFromFile(@ScriptDir & '\1660807.png')
$hBitmap = _GDIPlus_BitmapCreateHBITMAPFromBitmap($hPng)
$hParent = GUICreate('', 579, 293, -1, -1, $WS_POPUP, $WS_EX_LAYERED)
_WinAPI_UpdateLayeredWindowEx($hParent, -1, -1, $hBitmap, 255, 1)
_GDIPlus_ImageDispose($hPng)
_GDIPlus_Shutdown()
$hForm = GUICreate('', 563, 180, -1, -1, $WS_POPUP, -1, $hParent)
GUISetBkColor(0x314B89)
GUICtrlCreatePic(@ScriptDir & '\1660807.bmp', 0, 0, 563, 180)
GUICtrlSetState(-1, $GUI_DISABLE)
GUICtrlCreateCombo('Option1', 270, 8, 285, 140, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, 'Option2|Option3|Option4', 'Option1')
$Label = GUICtrlCreateLabel('Loading...', 10, 74, 60, 14)
GUICtrlSetBkColor(-1, $GUI_BKCOLOR_TRANSPARENT)
GUICtrlSetColor(-1, 0xFFFFFF)
$Button = GUICtrlCreateButton('Exit', 476, 150, 80, 23)
GUIRegisterMsg($WM_MOVE, 'WM_MOVE')
GUIRegisterMsg($WM_NCHITTEST, 'WM_NCHITTEST')
WM_MOVE($hParent, $WM_MOVE, 0, 0)
GUISetState(@SW_SHOW, $hParent)
GUISetState(@SW_SHOW, $hForm)
While 1
Switch GUIGetMsg()
Case $GUI_EVENT_CLOSE
Exit
Case $Button
Exit
Case $Label
_SendMessage($hParent, $WM_SYSCOMMAND, $SC_DRAGMOVE, 0)
EndSwitch
WEnd
Func WM_MOVE($hWnd, $iMsg, $wParam, $lParam)
Switch $hWnd
Case $hParent
Local $Pos = WinGetPos($hParent)
If IsArray($Pos) Then
WinMove($hForm, '', $Pos[0] + 13, $Pos[1] + 100)
EndIf
EndSwitch
Return $GUI_RUNDEFMSG
EndFunc ;==>WM_MOVE
Func WM_NCHITTEST($hWnd, $iMsg, $wParam, $lParam)
Switch $hWnd
Case $hForm
_SendMessage($hParent, $WM_SYSCOMMAND, $SC_DRAGMOVE, 0)
Case $hParent
Return $HTCAPTION
EndSwitch
Return $GUI_RUNDEFMSG
EndFunc ;==>WM_NCHITTEST
Func WM_NCHITTEST($hWnd, $iMsg, $wParam, $lParam)
Switch $hWnd
Case $hForm
Local $Info = GUIGetCursorInfo($hForm)
If (IsArray($Info)) And ($Info[2]) Then
_SendMessage($hParent, $WM_SYSCOMMAND, $SC_DRAGMOVE, 0)
EndIf
Case $hParent
Return $HTCAPTION
EndSwitch
Return $GUI_RUNDEFMSG
EndFunc ;==>WM_NCHITTEST
#Include <ComboConstants.au3>
#Include <GDIPlus.au3>
#Include <GUIConstantsEx.au3>
#Include <WinAPIEx.au3>
Global Const $SC_DRAGMOVE = 0xF012
_GDIPlus_Startup()
$hPng = _GDIPlus_ImageLoadFromFile(@ScriptDir & '\1660807.png')
$hBitmap = _GDIPlus_BitmapCreateHBITMAPFromBitmap($hPng)
$hParent = GUICreate('', 579, 293, -1, -1, $WS_POPUP, $WS_EX_LAYERED)
_WinAPI_UpdateLayeredWindowEx($hParent, -1, -1, $hBitmap, 255, 1)
_GDIPlus_ImageDispose($hPng)
_GDIPlus_Shutdown()
$hForm = GUICreate('', 563, 180, -1, -1, $WS_POPUP, -1, $hParent)
GUISetBkColor(0x314B89)
GUICtrlCreatePic(@ScriptDir & '\1660807.bmp', 0, 0, 563, 180)
GUICtrlSetState(-1, $GUI_DISABLE)
GUICtrlCreateCombo('Option1', 270, 8, 285, 140, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, 'Option2|Option3|Option4', 'Option1')
$Label = GUICtrlCreateLabel('Loading...', 10, 74, 60, 14)
GUICtrlSetBkColor(-1, $GUI_BKCOLOR_TRANSPARENT)
GUICtrlSetColor(-1, 0xFFFFFF)
$Button = GUICtrlCreateButton('Exit', 476, 150, 80, 23)
GUIRegisterMsg($WM_MOVE, 'WM_MOVE')
GUIRegisterMsg($WM_NCHITTEST, 'WM_NCHITTEST')
WM_MOVE($hParent, $WM_MOVE, 0, 0)
GUISetState(@SW_SHOW, $hParent)
GUISetState(@SW_SHOW, $hForm)
While 1
Switch GUIGetMsg()
Case $GUI_EVENT_CLOSE
Exit
Case $Button
Exit
Case $Label
_SendMessage($hParent, $WM_SYSCOMMAND, $SC_DRAGMOVE, 0)
EndSwitch
WEnd
Func WM_MOVE($hWnd, $iMsg, $wParam, $lParam)
Switch $hWnd
Case $hParent
Local $Pos = WinGetPos($hParent)
If IsArray($Pos) Then
WinMove($hForm, '', $Pos[0] + 13, $Pos[1] + 100)
EndIf
EndSwitch
Return $GUI_RUNDEFMSG
EndFunc ;==>WM_MOVE
Func WM_NCHITTEST($hWnd, $iMsg, $wParam, $lParam)
Switch $hWnd
Case $hForm
_SendMessage($hParent, $WM_SYSCOMMAND, $SC_DRAGMOVE, 0)
Case $hParent
Return $HTCAPTION
EndSwitch
Return $GUI_RUNDEFMSG
EndFunc ;==>WM_NCHITTEST