Décode les indicateurs de bit en chaîne TTF_*
#include <GuiToolTip.au3>
_GUIToolTip_BitsToTTF ( $iFlags )
$iFlags | Une valeur représentant les constantes d'info-bulle nécessaires au décodage |
#include <GUIConstantsEx.au3> #include <GUIToolTip.au3> #include <MsgBoxConstants.au3> Example() Func Example() Local $hGUI = GUICreate(StringTrimRight(@ScriptName, 4), 350, 200) Local $idButton = GUICtrlCreateButton("This is a button", 30, 32, 130, 28) Local $hButton = GUICtrlGetHandle($idButton) ;Crée un contrôle info-bulle en utilisant les paramètres par défaut Local $hToolTip = _GUIToolTip_Create(0) ; Ajoute un élément au contrôle info-bulle _GUIToolTip_AddTool($hToolTip, 0, "This is a ToolTip", $hButton) GUISetState(@SW_SHOW) ; Récupére les informations de l'élément affecté au bouton Local $aTool = _GUIToolTip_GetToolInfo($hToolTip, 0, $hButton) ; Convertit le tableau en texte en utilisant la fonction _GUIToolTip_BitsToTTF ; pour convertir le flag des informations en une chaîne de texte. MsgBox($MB_SYSTEMMODAL, "Tooltip info", "Flags: " & @TAB & _GUIToolTip_BitsToTTF($aTool[0]) & @CRLF & _ "HWnd: " & @TAB & $aTool[1] & @CRLF & _ "ID: " & @TAB & $aTool[2] & @CRLF & _ "Left X:" & @TAB & $aTool[3] & @CRLF & _ "Left Y:" & @TAB & $aTool[4] & @CRLF & _ "Right X:" & @TAB & $aTool[5] & @CRLF & _ "Right Y:" & @TAB & $aTool[6] & @CRLF & _ "Instance:" & @TAB & $aTool[7] & @CRLF & _ "Text:" & @TAB & $aTool[8] & @CRLF & _ "lParam:" & @TAB & $aTool[9]) ; Détruit le contrôle info-bulle _GUIToolTip_Destroy($hToolTip) GUIDelete($hGUI) EndFunc ;==>Example