Opened 10 years ago
Closed 9 years ago
#2970 closed Bug (No Bug)
TraySetToolTip text set to Chr(0) hides the tooltip.
Reported by: | guinness | Owned by: | |
---|---|---|---|
Milestone: | Component: | AutoIt | |
Version: | 3.3.12.0 | Severity: | None |
Keywords: | Cc: |
Description
If the tooltip text is set to null then the tooltip is hidden. If this isn't a bug then it will need documenting in the help file.
#NoTrayIcon #include <MsgBoxConstants.au3> #include <TrayConstants.au3> Example() Func Example() TraySetState($TRAY_ICONSTATE_SHOW) ; Show the tray menu. TraySetToolTip("An example of a tray menu tooltip.") ; The tray menu icon must be shown before we can set some text. MsgBox($MB_SYSTEMMODAL, "", "Hover your mouse over the AutoIt icon to see the tooltip text set before.") TraySetToolTip(Chr(0)) ; Hide the tooltip text by setting to null i.e. ASCII - 0. MsgBox($MB_SYSTEMMODAL, "", "Hover your mouse over the AutoIt icon to see the tooltip is now hidden.") ; BUG TraySetToolTip() ; Reset the tooltip to the original text i.e. the script filename. MsgBox($MB_SYSTEMMODAL, "", "Hover your mouse over the AutoIt icon to see the tooltip is now the filename e.g. AutoIt - Example.au3") EndFunc ;==>Example
Attachments (0)
Change History (5)
comment:1 Changed 10 years ago by BrewManNH
comment:2 Changed 10 years ago by guinness
The ticket request is just to confirm that this was the intention behaviour of null.
comment:3 Changed 10 years ago by water
TraySetToolTip("") behaves just like TraySetToolTip() and displays the default text in the tool tip.
comment:4 Changed 10 years ago by guinness
But "" is not the same as Chr(0) as "" is (char)32 and null is (char)0. Any further discussion should be moved to the appropriate thread please >> http://www.autoitscript.com/forum/topic/166765-traysettooltip-override-default/.
comment:5 Changed 9 years ago by BrewManNH
- Resolution set to No Bug
- Status changed from new to closed
According to a post by Jos this is intended behavior for using CHR(0) or Null in a tooltip.
Guidelines for posting comments:
- You cannot re-open a ticket but you may still leave a comment if you have additional information to add.
- In-depth discussions should take place on the forum.
For more information see the full version of the ticket guidelines here.
Isn't Null used to signify the end of a string, and you don't display the Null? So, wouldn't a string of just Null do the same thing as you're describing? Just throwing it out there.