Что нового

Убрать моргание элемента ProgressBar

Viktor1703

AutoIT Гуру
Сообщения
1,535
Репутация
413
Как убрать моргание скинового ProgressBar'a?



Example:
Код:
#include <GUIConstantsEx.au3>
#Include <JSkin_Progress.au3>

$hForm = GUICreate("_JSkin_CreateProgressBar", 400, 200)
GUISetBkColor(0x1E1E1E)

$iProW =  _JSkin_CreateProgressBar(10, 10,  12,  180, 1, 1, 0x4C4C4C, 0x202020, 0x404040, 0xFF7F7F, 0xFF0000)
$iProW2 = _JSkin_CreateProgressBar(28, 10,  12,  180, 1, 1, 0x4C4C4C, 0x202020, 0x404040, 0xFFEFAA, 0xFFD800)
$iProH =  _JSkin_CreateProgressBar(50, 160, 340, 12,  0, 0, 0x4C4C4C, 0x202020, 0x404040, 0xA5FF7F, 0x007F0E)
$iProH2 = _JSkin_CreateProgressBar(50, 178, 340, 12,  0, 0, 0x4C4C4C, 0x202020, 0x404040, 0x7FC9FF, 0x0084E2)

$hButton1 = GUICtrlCreateButton("Step +", 140, 90, 50, 20)
$hButton2 = GUICtrlCreateButton("Step -", 200, 90, 50, 20)
GUISetState()
	
While 1
	Switch GUIGetMsg()
	    Case $GUI_EVENT_CLOSE
		    Exit
		Case $hButton1
            For $i = 0 To 100 Step + 1
	            _JSkin_SetProgressStep($iProW, $i)
				_JSkin_SetProgressStep($iProW2, $i)
	            _JSkin_SetProgressStep($iProH, $i)
				_JSkin_SetProgressStep($iProH2, $i)
	            WinSetTitle($hForm, '', "W: " & _JSkin_GetProgressStep($iProW) & "%" & "   " & "H: " & _JSkin_GetProgressStep($iProH) & "%" & "   " & "W2: " & _JSkin_GetProgressStep($iProW2) & "%" & "   " & "H2: " & _JSkin_GetProgressStep($iProH2) & "%")
	            Sleep(30)
            Next	
		Case $hButton2
            For $i = 100 To 0 Step - 1
	            _JSkin_SetProgressStep($iProW, $i)
				_JSkin_SetProgressStep($iProW2, $i)
	            _JSkin_SetProgressStep($iProH, $i)
				_JSkin_SetProgressStep($iProH2, $i)
	            WinSetTitle($hForm, '', "W: " & _JSkin_GetProgressStep($iProW) & "%" & "   " & "H: " & _JSkin_GetProgressStep($iProH) & "%" & "   " & "W2: " & _JSkin_GetProgressStep($iProW2) & "%" & "   " & "H2: " & _JSkin_GetProgressStep($iProH2) & "%")
	            Sleep(30)
            Next			
	EndSwitch		
Wend

JSkin_Progress.au3:
Код:
#Include <WinAPIEx.au3>

Global $_JSkin_Progress_Param[1][16] = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]]

Func _JSkin_CreateProgressBar($iLeft, $iTop, $iWidth, $iHeight, $iType, $Gradient, $iFrame, $iTColor, $iBColor, $lTColor, $lBColor)
	
    $iFont = GUICtrlCreatePic("", $iLeft, $iTop, $iWidth, $iHeight)
    $hFont = GUICtrlGetHandle($iFont)
    GUICtrlSetState($iFont, 128)

	$iLine = GUICtrlCreatePic("", $iLeft + 2, $iTop + 2, $iWidth - 4, $iHeight - 4)
    $hLine = GUICtrlGetHandle($iLine)
	GUICtrlSetState($iLine, 128)

	$_JSkin_Progress_Param[0][0] += 1
	ReDim $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0] + 1][UBound($_JSkin_Progress_Param, 2)]
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][0] = $iFont
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][1] = $hFont
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][2] = $iFrame
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][3] = $iTColor
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][4] = $iBColor
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][5] = $iLine
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][6] = $hLine
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][7] = $lTColor
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][8] = $lBColor	
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][9] = $iLeft
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][10] = $iTop
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][11] = $iWidth
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][12] = $iHeight	
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][13] = 0
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][14] = $iType
	$_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][15] = $Gradient
	
	__SetProgressColor($hFont, $iWidth, $iHeight, $iFrame, $iTColor, $iBColor)

	Return $iLine
EndFunc	

Func _JSkin_SetProgressStep($iCtrlId, $iStep)
	For $i = 0 To $_JSkin_Progress_Param[0][0]
		If $_JSkin_Progress_Param[$i][5] = $iCtrlId Then
			If $_JSkin_Progress_Param[$i][14] = 0 Then
				
			    $iStep = Round($iStep * (($_JSkin_Progress_Param[$i][11] - 2)/ 100))
			    $_JSkin_Progress_Param[$i][13] = Round(($iStep / (($_JSkin_Progress_Param[$i][11] - 2) / 100)))

			    $hDC = _WinAPI_GetDC($_JSkin_Progress_Param[$i][6])
                $hDestDC = _WinAPI_CreateCompatibleDC($hDC)
                $hBitmap = _WinAPI_CreateCompatibleBitmapEx($hDC, $iStep - 2, $_JSkin_Progress_Param[$i][12] - 4, 0x060606)
                $hDestSv = _WinAPI_SelectObject($hDestDC, $hBitmap)
                Dim $hGradient[2][3] = [[0, 0, $_JSkin_Progress_Param[$i][7]], [$iStep - 2, $_JSkin_Progress_Param[$i][12] - 4, $_JSkin_Progress_Param[$i][8]]]
                _WinAPI_GradientFill($hDestDC, $hGradient, 0, 2, $_JSkin_Progress_Param[$i][15])
                _WinAPI_ReleaseDC($_JSkin_Progress_Param[$i][6], $hDC)
                _WinAPI_SelectObject($hDestDC, $hDestSv)
                _WinAPI_DeleteDC($hDestDC)
                _SendMessage($_JSkin_Progress_Param[$i][6], 0x0172, 0, $hBitmap)
		    ElseIf $_JSkin_Progress_Param[$i][14] = 1 Then
				
			    $iStep = Round($iStep * (($_JSkin_Progress_Param[$i][12] - 2)/ 100))
			    $_JSkin_Progress_Param[$i][13] = Round(($iStep / (($_JSkin_Progress_Param[$i][12] - 2) / 100)))
				
				GUICtrlSetPos($_JSkin_Progress_Param[$i][5], $_JSkin_Progress_Param[$i][9] + 2, ($_JSkin_Progress_Param[$i][10] + $_JSkin_Progress_Param[$i][12]) - $iStep , $_JSkin_Progress_Param[$i][11] - 4, ($_JSkin_Progress_Param[$i][12] - $_JSkin_Progress_Param[$i][12] - 2) + $iStep)

			    $hDC = _WinAPI_GetDC($_JSkin_Progress_Param[$i][6])
                $hDestDC = _WinAPI_CreateCompatibleDC($hDC)
                $hBitmap = _WinAPI_CreateCompatibleBitmapEx($hDC, $_JSkin_Progress_Param[$i][11] - 4, ($_JSkin_Progress_Param[$i][12] - $_JSkin_Progress_Param[$i][12] - 2) + $iStep, 0x060606)
                $hDestSv = _WinAPI_SelectObject($hDestDC, $hBitmap)
				Dim $hGradient[4][3] = [[0, 0, $_JSkin_Progress_Param[$i][7]], _
									   [$_JSkin_Progress_Param[$i][11] - 4, ($_JSkin_Progress_Param[$i][12] - $_JSkin_Progress_Param[$i][12] - 2) + $iStep, $_JSkin_Progress_Param[$i][8]], _
									   [  0, ($_JSkin_Progress_Param[$i][12] - $_JSkin_Progress_Param[$i][12] - 2) + $iStep, $_JSkin_Progress_Param[$i][8]], _
                                       [0, 0, $_JSkin_Progress_Param[$i][7]]]
				
				_WinAPI_GradientFill($hDestDC, $hGradient, 0, 1, $_JSkin_Progress_Param[$i][15])
                _WinAPI_GradientFill($hDestDC, $hGradient, 2, 3, $_JSkin_Progress_Param[$i][15])
				
                _WinAPI_ReleaseDC($_JSkin_Progress_Param[$i][6], $hDC)
                _WinAPI_SelectObject($hDestDC, $hDestSv)
                _WinAPI_DeleteDC($hDestDC)
                _SendMessage($_JSkin_Progress_Param[$i][6], 0x0172, 0, $hBitmap)
		    EndIf	
			GUICtrlSetState($_JSkin_Progress_Param[$i][5], 16 + 128)
        EndIf
    Next
EndFunc

Func _JSkin_GetProgressStep($iCtrlId)
	For $i = 0 To $_JSkin_Progress_Param[0][0]
		If $_JSkin_Progress_Param[$i][5] = $iCtrlId Then
			Return $_JSkin_Progress_Param[$i][13]
		EndIf
	Next	
EndFunc	

Func __SetProgressColor($iCtrlId, $iWidth, $iHeight, $iFrame, $iTColor, $iBColor)
	
	Local $hDC, $hDestDC, $hBitmap, $hDestSv, $hGradient 
	
	$hDC = _WinAPI_GetDC($iCtrlId)
    $hDestDC = _WinAPI_CreateCompatibleDC($hDC)
    $hBitmap = _WinAPI_CreateCompatibleBitmapEx($hDC, $iWidth, $iHeight, $iFrame)
    $hDestSv = _WinAPI_SelectObject($hDestDC, $hBitmap)
	
	For $i = 0 To $_JSkin_Progress_Param[0][0]
	    If $_JSkin_Progress_Param[$i][1] = $iCtrlId Then
			If $_JSkin_Progress_Param[$i][14] = 0 Then
                Dim $hGradient[2][3] = [[2, 2, $iTColor], [$iWidth - 2, $iHeight - 2, $iBColor]]
               _WinAPI_GradientFill($hDestDC, $hGradient)
			Else
			   Dim $hGradient[4][3] = [[2, 2, $iTColor], _
									   [$iWidth - 2, $iHeight - 2, $iBColor], _
									   [  0, $iHeight - 2, $iBColor], _
                                       [0, 0, $iTColor]]
				
				_WinAPI_GradientFill($hDestDC, $hGradient, 0, 1, 2)
                _WinAPI_GradientFill($hDestDC, $hGradient, 2, 3, 1)
		    EndIf 
	    EndIf 
	Next   
	
    _WinAPI_ReleaseDC($iCtrlId, $hDC)
    _WinAPI_SelectObject($hDestDC, $hDestSv)
    _WinAPI_DeleteDC($hDestDC)
    _SendMessage($iCtrlId, 0x0172, 0, $hBitmap)
EndFunc
 

Yashied

Модератор
Команда форума
Глобальный модератор
Сообщения
5,379
Репутация
2,716
Мерцание может вызывать только GUICtrlSetPos(). А еще не понятен смысл GUICtrlSetState().
 
Автор
V

Viktor1703

AutoIT Гуру
Сообщения
1,535
Репутация
413
GUICtrlSetState() обновляет элемент и он правильно прорисовывается (можно и убрать), на счёт GUICtrlSetPos() это знаю, но как тогда обойтись без него?! тогда вертикальный прогресс будет заполнятся сверху в низ...


Добавлено:
Сообщение автоматически объединено:

С прорисовкой разобрался, нужно теперь чтоб вертикальный прогресс заполнялся с низу в верх

Example:
Код:
#include <GUIConstantsEx.au3>
#Include <JSkin_Progress.au3>

Global $FontProgress1[5] = [0x4C4C4C, 0x202020, 0x404040, 0xFF7F7F, 0xFF0000]
Global $FontProgress2[5] = [0x4C4C4C, 0x202020, 0x404040, 0xFFEFAA, 0xFFD800]
Global $FontProgress3[5] = [0x4C4C4C, 0x202020, 0x404040, 0xA5FF7F, 0x007F0E]
Global $FontProgress4[5] = [0x4C4C4C, 0x202020, 0x404040, 0x7FC9FF, 0x0084E2]


$hForm = GUICreate("_JSkin_CreateProgressBar", 400, 200)
GUISetBkColor(0x1E1E1E)

$iProW =  _JSkin_CreateProgressBar(10, 10,  12,  180, 1, 1, $FontProgress1)
$iProW2 = _JSkin_CreateProgressBar(28, 10,  12,  180, 1, 1, $FontProgress2)
$iProH =  _JSkin_CreateProgressBar(50, 160, 340, 12,  0, 0, $FontProgress3)
$iProH2 = _JSkin_CreateProgressBar(50, 178, 340, 12,  0, 0, $FontProgress4)

$hButton1 = GUICtrlCreateButton("UP", 140, 90, 50, 20)
$hButton2 = GUICtrlCreateButton("DOWN", 200, 90, 50, 20)
GUISetState()
	
While 1
	Switch GUIGetMsg()
	    Case $GUI_EVENT_CLOSE
		    Exit
		Case $hButton1
            For $i = 0 To 100 Step + 1
	            _JSkin_SetProgressStep($iProW, $i)
				_JSkin_SetProgressStep($iProW2, $i)
	            _JSkin_SetProgressStep($iProH, $i)
				_JSkin_SetProgressStep($iProH2, $i)
	            WinSetTitle($hForm, '', "W: " & _JSkin_GetProgressStep($iProW) & "%" & "   " & "H: " & _JSkin_GetProgressStep($iProH) & "%" & "   " & "W2: " & _JSkin_GetProgressStep($iProW2) & "%" & "   " & "H2: " & _JSkin_GetProgressStep($iProH2) & "%")
	            Sleep(30)
            Next	
			_JSkin_PaintProgress()
		Case $hButton2
            For $i = 100 To 0 Step - 1
	            _JSkin_SetProgressStep($iProW, $i)
				_JSkin_SetProgressStep($iProW2, $i)
	            _JSkin_SetProgressStep($iProH, $i)
				_JSkin_SetProgressStep($iProH2, $i)
	            WinSetTitle($hForm, '', "W: " & _JSkin_GetProgressStep($iProW) & "%" & "   " & "H: " & _JSkin_GetProgressStep($iProH) & "%" & "   " & "W2: " & _JSkin_GetProgressStep($iProW2) & "%" & "   " & "H2: " & _JSkin_GetProgressStep($iProH2) & "%")
	            Sleep(30)
            Next	
			_JSkin_PaintProgress()
	EndSwitch		
Wend

JSkin_Progress.au3:
Код:
#Include <WinAPIEx.au3>

Global $_JSkin_Progress_Param[1][16] = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]]

Func _JSkin_CreateProgressBar($iLeft, $iTop, $iWidth, $iHeight, $iType, $Gradient, ByRef $iColor)
	
	If IsArray($iColor) Then 
		
        $iFont = GUICtrlCreatePic("", $iLeft, $iTop, $iWidth, $iHeight)
        $hFont = GUICtrlGetHandle($iFont)
        GUICtrlSetState($iFont, 128)

	    $iLine = GUICtrlCreatePic("", $iLeft + 2, $iTop + 2, $iWidth - 4, $iHeight - 4)
        $hLine = GUICtrlGetHandle($iLine)
	    GUICtrlSetState($iLine, 128)

	    $_JSkin_Progress_Param[0][0] += 1
	    ReDim $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0] + 1][UBound($_JSkin_Progress_Param, 2)]
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][0] = $iFont
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][1] = $hFont
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][2] = $iColor[0]
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][3] = $iColor[1]
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][4] = $iColor[2]
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][5] = $iLine
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][6] = $hLine
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][7] = $iColor[3]
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][8] = $iColor[4]
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][9] = $iLeft
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][10] = $iTop
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][11] = $iWidth
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][12] = $iHeight	
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][13] = 0
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][14] = $iType
	    $_JSkin_Progress_Param[$_JSkin_Progress_Param[0][0]][15] = $Gradient
	
	    __SetProgressColor($hFont, $iWidth, $iHeight, $iColor[0], $iColor[1], $iColor[2])

	    Return $iLine
		
	EndIf
	
EndFunc	

Func _JSkin_SetProgressStep($iCtrlId, $iStep)
	For $i = 0 To $_JSkin_Progress_Param[0][0]
		If $_JSkin_Progress_Param[$i][5] = $iCtrlId Then
			If $_JSkin_Progress_Param[$i][14] = 0 Then
				
			    $iStep = Round($iStep * (($_JSkin_Progress_Param[$i][11] - 2)/ 100))
			    $_JSkin_Progress_Param[$i][13] = Round(($iStep / (($_JSkin_Progress_Param[$i][11] - 2) / 100)))

			    $hDC = _WinAPI_GetDC($_JSkin_Progress_Param[$i][6])
                $hDestDC = _WinAPI_CreateCompatibleDC($hDC)
                $hBitmap = _WinAPI_CreateCompatibleBitmapEx($hDC, $iStep - 2, $_JSkin_Progress_Param[$i][12] - 4, 0x060606)
                $hDestSv = _WinAPI_SelectObject($hDestDC, $hBitmap)
                Dim $hGradient[2][3] = [[0, 0, $_JSkin_Progress_Param[$i][7]], [$iStep - 2, $_JSkin_Progress_Param[$i][12] - 4, $_JSkin_Progress_Param[$i][8]]]
                _WinAPI_GradientFill($hDestDC, $hGradient, 0, 2, $_JSkin_Progress_Param[$i][15])
                _WinAPI_ReleaseDC($_JSkin_Progress_Param[$i][6], $hDC)
                _WinAPI_SelectObject($hDestDC, $hDestSv)
                _WinAPI_DeleteDC($hDestDC)
                _SendMessage($_JSkin_Progress_Param[$i][6], 0x0172, 0, $hBitmap)
		    ElseIf $_JSkin_Progress_Param[$i][14] = 1 Then
				
			    $iStep = Round($iStep * (($_JSkin_Progress_Param[$i][12] - 2)/ 100))
			    $_JSkin_Progress_Param[$i][13] = Round(($iStep / (($_JSkin_Progress_Param[$i][12] - 2) / 100)))
				
				;GUICtrlSetPos($_JSkin_Progress_Param[$i][5], $_JSkin_Progress_Param[$i][9] + 2, ($_JSkin_Progress_Param[$i][10] + $_JSkin_Progress_Param[$i][12]) - $iStep , $_JSkin_Progress_Param[$i][11] - 4, ($_JSkin_Progress_Param[$i][12] - $_JSkin_Progress_Param[$i][12] - 2) + $iStep)

			    $hDC = _WinAPI_GetDC($_JSkin_Progress_Param[$i][6])
                $hDestDC = _WinAPI_CreateCompatibleDC($hDC)
                $hBitmap = _WinAPI_CreateCompatibleBitmapEx($hDC, $_JSkin_Progress_Param[$i][11] - 4, ($_JSkin_Progress_Param[$i][12] - $_JSkin_Progress_Param[$i][12] - 2) + $iStep, 0x060606)
                $hDestSv = _WinAPI_SelectObject($hDestDC, $hBitmap)
				Dim $hGradient[4][3] = [[0, 0, $_JSkin_Progress_Param[$i][7]], _
									   [$_JSkin_Progress_Param[$i][11] - 4, ($_JSkin_Progress_Param[$i][12] - $_JSkin_Progress_Param[$i][12] - 2) + $iStep, $_JSkin_Progress_Param[$i][8]], _
									   [  0, ($_JSkin_Progress_Param[$i][12] - $_JSkin_Progress_Param[$i][12] - 2) + $iStep, $_JSkin_Progress_Param[$i][8]], _
                                       [0, 0, $_JSkin_Progress_Param[$i][7]]]
				
				_WinAPI_GradientFill($hDestDC, $hGradient, 0, 1, $_JSkin_Progress_Param[$i][15])
                _WinAPI_GradientFill($hDestDC, $hGradient, 2, 3, $_JSkin_Progress_Param[$i][15])
				
                _WinAPI_ReleaseDC($_JSkin_Progress_Param[$i][6], $hDC)
                _WinAPI_SelectObject($hDestDC, $hDestSv)
                _WinAPI_DeleteDC($hDestDC)
                _SendMessage($_JSkin_Progress_Param[$i][6], 0x0172, 0, $hBitmap)
		    EndIf	
        EndIf
    Next
EndFunc

Func _JSkin_GetProgressStep($iCtrlId)
	For $i = 0 To $_JSkin_Progress_Param[0][0]
		If $_JSkin_Progress_Param[$i][5] = $iCtrlId Then
			Return $_JSkin_Progress_Param[$i][13]
		EndIf
	Next	
EndFunc	

Func _JSkin_PaintProgress()
	For $i = 0 To $_JSkin_Progress_Param[0][0]
		GUICtrlSetState($_JSkin_Progress_Param[$i][5], 16)
	Next	
EndFunc	


Func __SetProgressColor($iCtrlId, $iWidth, $iHeight, $iFrame, $iTColor, $iBColor)
	
	Local $hDC, $hDestDC, $hBitmap, $hDestSv, $hGradient 
	
	$hDC = _WinAPI_GetDC($iCtrlId)
    $hDestDC = _WinAPI_CreateCompatibleDC($hDC)
    $hBitmap = _WinAPI_CreateCompatibleBitmapEx($hDC, $iWidth, $iHeight, $iFrame)
    $hDestSv = _WinAPI_SelectObject($hDestDC, $hBitmap)
	
	For $i = 0 To $_JSkin_Progress_Param[0][0]
	    If $_JSkin_Progress_Param[$i][1] = $iCtrlId Then
			If $_JSkin_Progress_Param[$i][14] = 0 Then
                Dim $hGradient[2][3] = [[2, 2, $iTColor], [$iWidth - 2, $iHeight - 2, $iBColor]]
               _WinAPI_GradientFill($hDestDC, $hGradient)
			Else
			   Dim $hGradient[4][3] = [[2, 2, $iTColor], _
									   [$iWidth - 2, $iHeight - 2, $iBColor], _
									   [  0, $iHeight - 2, $iBColor], _
                                       [0, 0, $iTColor]]
				
				_WinAPI_GradientFill($hDestDC, $hGradient, 0, 1, 2)
                _WinAPI_GradientFill($hDestDC, $hGradient, 2, 3, 1)
		    EndIf 
	    EndIf 
	Next   
	
    _WinAPI_ReleaseDC($iCtrlId, $hDC)
    _WinAPI_SelectObject($hDestDC, $hDestSv)
    _WinAPI_DeleteDC($hDestDC)
    _SendMessage($iCtrlId, 0x0172, 0, $hBitmap)
EndFunc
 
Верх