tooltip(text)
Class: Button. Method inherited from UIComponent.
Description:
Sets or gets tooltip text for the component. It's the text that pops up when cursor hovers the component.
Parameters:
| Name | Type | Description |
|---|---|---|
|
|
string |
Can be plain text or HTML. HTML string should be surrounded with HTML tags. See example. |
Returns:
Returns this component if argument is set, otherwise returns string value.
Type: string | this
Examples:
button.tooltip("<html>This is line 1<br />This is line 2</html>"); // Setting HTML string with 2 lines of text
