Class ActionButton
ActionButton UI element.
Inheritance
Implements
Inherited Members
Namespace: Unity.AppUI.UI
Assembly: solution.dll
Syntax
public class ActionButton : ExVisualElement, IEventHandler, ITransform, ITransitionAnimations, IExperimentalFeatures, IVisualElementScheduler, IResolvedStyle, IContextOverrideElement, ISizeableElement, ISelectableElement, IPressable
Constructors
ActionButton()
Default constructor.
Declaration
public ActionButton()
ActionButton(Action)
Construct a ActionButton with a given click event callback.
Declaration
public ActionButton(Action clickEvent)
Parameters
Type | Name | Description |
---|---|---|
Action | clickEvent | THe given click event callback. |
Fields
accentUssClassName
The ActionButton accent styling class.
Declaration
public static readonly string accentUssClassName
Field Value
Type | Description |
---|---|
string |
iconAndLabelUssClassName
The ActionButton icon and label variant styling class.
Declaration
public static readonly string iconAndLabelUssClassName
Field Value
Type | Description |
---|---|
string |
iconOnlyUssClassName
The ActionButton icon only variant styling class.
Declaration
public static readonly string iconOnlyUssClassName
Field Value
Type | Description |
---|---|
string |
iconUssClassName
The ActionButton icon styling class.
Declaration
public static readonly string iconUssClassName
Field Value
Type | Description |
---|---|
string |
labelUssClassName
The ActionButton label styling class.
Declaration
public static readonly string labelUssClassName
Field Value
Type | Description |
---|---|
string |
quietUssClassName
The ActionButton quiet variant styling class.
Declaration
public static readonly string quietUssClassName
Field Value
Type | Description |
---|---|
string |
sizeUssClassName
The ActionButton size styling class.
Declaration
public static readonly string sizeUssClassName
Field Value
Type | Description |
---|---|
string |
ussClassName
The ActionButton main styling class.
Declaration
public static readonly string ussClassName
Field Value
Type | Description |
---|---|
string |
Properties
accent
The accent variant of the ActionButton.
Declaration
[Tooltip("The accent variant of the ActionButton")]
public bool accent { get; set; }
Property Value
Type | Description |
---|---|
bool |
clickable
Clickable Manipulator for this ActionButton.
Declaration
public Pressable clickable { get; set; }
Property Value
Type | Description |
---|---|
Pressable |
contentContainer
The content container of the ActionButton.
Declaration
public override VisualElement contentContainer { get; }
Property Value
Type | Description |
---|---|
VisualElement |
Overrides
icon
The ActionButton icon.
Declaration
[Tooltip("The ActionButton icon.")]
public string icon { get; set; }
Property Value
Type | Description |
---|---|
string |
iconVariant
The ActionButton icon variant.
Declaration
[Tooltip("The ActionButton icon variant.")]
public IconVariant iconVariant { get; set; }
Property Value
Type | Description |
---|---|
IconVariant |
label
The ActionButton label.
Declaration
[Tooltip("The ActionButton label.")]
public string label { get; set; }
Property Value
Type | Description |
---|---|
string |
quiet
The quiet state of the ActionButton.
Declaration
[Tooltip("The quiet state of the ActionButton")]
public bool quiet { get; set; }
Property Value
Type | Description |
---|---|
bool |
selected
The selected state of the ActionButton.
Declaration
[Tooltip("The selected state of the ActionButton")]
public bool selected { get; set; }
Property Value
Type | Description |
---|---|
bool |
size
The current size of the ActionButton.
Declaration
[Tooltip("The current size of the ActionButton.")]
public Size size { get; set; }
Property Value
Type | Description |
---|---|
Size |
Methods
SetSelectedWithoutNotify(bool)
Set the selected state of the ActionButton without notifying the click event.
Declaration
public void SetSelectedWithoutNotify(bool newValue)
Parameters
Type | Name | Description |
---|---|---|
bool | newValue |
Events
clicked
The ActionButton click event.
Declaration
public event Action clicked
Event Type
Type | Description |
---|---|
Action |