Core Function ToolTipKill

From Sputnik Wiki
(Difference between revisions)
Jump to: navigation, search
(Example)
m (1 revision)
 
(2 intermediate revisions by one user not shown)
Line 37: Line 37:
  
 
<syntaxhighlight lang="sputnik">
 
<syntaxhighlight lang="sputnik">
glob $lol = array();
+
Global $lol = array();
glob $i = 0;
+
Global $i = 0;
 
   
 
   
 
$GUI = GUICreate("Window", "mooooo", 200, 200);
 
$GUI = GUICreate("Window", "mooooo", 200, 200);

Latest revision as of 12:38, 14 June 2015

ToolTipKill( <ToolTip> )

Contents

Description

Delete a tooltip that was made using ToolTip().

ToolTip

The HWND of the tooltip.

Return Value

None.

Remarks

None.

Example

// This will create a tooltip in the upper left of the screen
$a = ToolTip("This is a tooltip", 0, 0); // Create a tooltip
Sleep(2000); // Sleep to give tooltip time to display
ToolTipKill($a); // Remove the tooltip
 
 
// Same as above but this time place the tooltip at the mouse pointer
$a = ToolTip("This is a tooltip"); // Create a tooltip
Sleep(2000); // Sleep to give tooltip time to display
ToolTip($a); // Remove the tooltip

Heres an example of a program with 2 hotkeys the first hotkey A will create a tooltip and the second hotkey B will delete all tooltips

Global $lol = array();
Global $i = 0;
 
$GUI = GUICreate("Window", "mooooo", 200, 200);
GUILoad( $GUI );
 
HotKeySet("a", "lol();");
HotKeySet("b", "lol2();");
 
While ( GUIStatus( $GUI ) ) DoEvents( );
 
Function lol()
{
	push($lol, ToolTip("This is a tooltip $i"));
	$i++;
}
 
Function lol2()
{
	foreach($lol as $l)
	{
		ToolTipKill($l);
	}
	$lol = array();
}
Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox