Class HelpBox
HelpBox UI element.
Implements
Inherited Members
VisualElement.ExecuteDefaultAction(EventBase)
VisualElement.Focus()
VisualElement.Overlaps(Rect)
VisualElement.ToString()
VisualElement.GetFirstOfType<T>()
VisualElement.GetFirstAncestorOfType<T>()
VisualElement.canGrabFocus
VisualElement.focusController
VisualElement.cacheAsBitmap
CallbackEventHandler.RegisterCallback<TEventType>(EventCallback<TEventType>, TrickleDown)
CallbackEventHandler.RegisterCallback<TEventType, TUserArgsType>(EventCallback<TEventType, TUserArgsType>, TUserArgsType, TrickleDown)
CallbackEventHandler.UnregisterCallback<TEventType>(EventCallback<TEventType>, TrickleDown)
CallbackEventHandler.UnregisterCallback<TEventType, TUserArgsType>(EventCallback<TEventType, TUserArgsType>, TrickleDown)
Namespace: Unity.AppUI.UI
Assembly: Unity.AppUI.dll
Syntax
public class HelpBox : BaseVisualElement, IEventHandler, ITransform, ITransitionAnimations, IExperimentalFeatures, IVisualElementScheduler, IResolvedStyle, IContextOverrideElement, IAdditionalDataHolder
Constructors
HelpBox()
Default constructor.
Declaration
public HelpBox()
HelpBox(string, AlertSemantic, string)
Constructor with a message and optional variant.
Declaration
public HelpBox(string msg, AlertSemantic variant = AlertSemantic.Information, string icon = "info")
Parameters
| Type | Name | Description |
|---|---|---|
| string | msg | The message to display. |
| AlertSemantic | variant | The semantic variant controlling the color scheme. |
| string | icon | The icon name to display. |
Fields
iconUssClassName
The HelpBox icon styling class.
Declaration
public const string iconUssClassName = "appui-helpbox__icon"
Field Value
| Type | Description |
|---|---|
| string |
messageUssClassName
The HelpBox message styling class.
Declaration
public const string messageUssClassName = "appui-helpbox__message"
Field Value
| Type | Description |
|---|---|
| string |
sizeUssClassName
The HelpBox size styling class.
Declaration
public const string sizeUssClassName = "appui-helpbox--size-"
Field Value
| Type | Description |
|---|---|
| string |
ussClassName
The HelpBox main styling class.
Declaration
public const string ussClassName = "appui-helpbox"
Field Value
| Type | Description |
|---|---|
| string |
variantUssClassName
The HelpBox variant styling class.
Declaration
public const string variantUssClassName = "appui-helpbox--"
Field Value
| Type | Description |
|---|---|
| string |
Properties
iconName
The name of the icon displayed in the HelpBox.
Declaration
public string iconName { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
message
The message displayed inside the HelpBox.
Declaration
public string message { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
size
The size of the HelpBox, which controls the size of the icon and the message text.
Declaration
public Size size { get; set; }
Property Value
| Type | Description |
|---|---|
| Size |
variant
The semantic variant which controls the color scheme of the HelpBox.
Declaration
public AlertSemantic variant { get; set; }
Property Value
| Type | Description |
|---|---|
| AlertSemantic |
Methods
GetSizeUssClassName(Size)
Declaration
public static string GetSizeUssClassName(Size enumValue)
Parameters
| Type | Name | Description |
|---|---|---|
| Size | enumValue |
Returns
| Type | Description |
|---|---|
| string |
GetVariantUssClassName(AlertSemantic)
Declaration
public static string GetVariantUssClassName(AlertSemantic enumValue)
Parameters
| Type | Name | Description |
|---|---|---|
| AlertSemantic | enumValue |
Returns
| Type | Description |
|---|---|
| string |