Ermittelt den Typ des Füllmuster-Objekts
#Include <GDIPlus.au3>
_GDIPlus_BrushGetType($hBrush)
Parameter
| $hBrush | Handle zu einem Füllmuster-Objekt |
Rückgabewert
| Erfolg: | Füllmustertyp: |
| 0 - Vollfarbe | |
| 1 - schraffierte Füllung | |
| 2 - Texturfüllung | |
| 3 - kreisrunder Farbverlauf | |
| 4 - linearer Farbverlauf | |
| Fehler: | -1 und @error wird gesetzt |
Bemerkungen
Keine.
Verwandte Funktionen
Siehe auch
Suche in der MSDN Bibliothek nach GdipGetBrushType
Beispiel
#include <GuiConstantsEx.au3>
#include <GDIPlus.au3>
#include <WindowsConstants.au3>
Opt('MustDeclareVars', 1)
Global $iMemo
_Main()
Func _Main()
Local $hGUI, $hBrush1, $hBrush2
; Erstellt eine GUI
$hGUI = GUICreate("GDI+", 400, 300)
$iMemo = GUICtrlCreateEdit("", 2, 2, 596, 396, $WS_VSCROLL)
GUICtrlSetFont($iMemo, 9, 400, 0, "Courier New")
GUISetState()
; Erstellt das Füllmuster
_GDIPlus_Startup()
$hBrush1 = _GDIPlus_BrushCreateSolid()
$hBrush2 = _GDIPlus_BrushClone($hBrush1)
; Zeigt Informationen über das Füllmuster
MemoWrite("Füllmuster 1 Handle : 0x" & Hex($hBrush1))
MemoWrite("Füllmuster 1 Typ ...: " & _GDIPlus_BrushGetType($hBrush1))
MemoWrite("Füllmuster 2 Handle : 0x" & Hex($hBrush2))
MemoWrite("Füllmuster 2 Typ ...: " & _GDIPlus_BrushGetType($hBrush2))
; Ressourcen freigeben
_GDIPlus_BrushDispose($hBrush2)
_GDIPlus_BrushDispose($hBrush1)
_GDIPlus_Shutdown()
; Die Schleife wiederholt sich, bis der Benutzer die Beenden-Aktion der GUI auslöst
Do
Until GUIGetMsg() = $GUI_EVENT_CLOSE
EndFunc ;==>_Main
; Gibt eine Zeile im Memo-Fenster aus
Func MemoWrite($sMessage = '')
GUICtrlSetData($iMemo, $sMessage & @CRLF, 1)
EndFunc ;==>MemoWrite