Class Button

Definition

Namespace:
Tizen.NUI.Components
Assembly:
Tizen.NUI.Components.dll
API Level:
6

Button is one kind of common component, a button clearly describes what action will occur when the user selects it. Button may contain text or an icon.

C#
Copy
public class Button : Control, INotifyPropertyChanged, IDynamicResourceHandler, IElement, INameScope, IElementController, IDisposable, IResourcesProvider
Inheritance
System.Object
Tizen.NUI.Binding.BindableObject
Tizen.NUI.Binding.Element
Tizen.NUI.Components.Control
Button
Derived
Tizen.NUI.Components.SelectButton
Implements
System.ComponentModel.INotifyPropertyChanged
System.IDisposable

Constructors

View Source

Button()

Creates a new instance of a Button.

Declaration
C#
Copy
public Button()
API Level: 6

Properties

View Source

FontFamily

Text font family in Button.

Declaration
C#
Copy
public string FontFamily { get; set; }
Property Value
Type Description
System.String
API Level: 6
View Source

IconPadding

Icon padding in Button, work only when show icon and text.

Declaration
C#
Copy
public Extents IconPadding { get; set; }
Property Value
Type Description
Extents
API Level: 6
View Source

IconURL

Icon image's resource url in Button.

Declaration
C#
Copy
public string IconURL { get; set; }
Property Value
Type Description
System.String
API Level: 6
View Source

IconURLSelector

Icon image's resource url selector in Button.

Declaration
C#
Copy
public StringSelector IconURLSelector { get; set; }
Property Value
Type Description
Tizen.NUI.Components.StringSelector
API Level: 6
View Source

IsEnabled

Flag to decide enable or disable in Button.

Declaration
C#
Copy
public bool IsEnabled { get; set; }
Property Value
Type Description
System.Boolean
API Level: 6
View Source

IsSelectable

Flag to decide Button can be selected or not.

Declaration
C#
Copy
public bool IsSelectable { get; set; }
Property Value
Type Description
System.Boolean
API Level: 6
View Source

IsSelected

Flag to decide selected state in Button.

Declaration
C#
Copy
public bool IsSelected { get; set; }
Property Value
Type Description
System.Boolean
API Level: 6
View Source

PointSize

Text point size in Button.

Declaration
C#
Copy
public float PointSize { get; set; }
Property Value
Type Description
Single
API Level: 6
View Source

PointSizeSelector

Text font size selector in Button.

Declaration
C#
Copy
public FloatSelector PointSizeSelector { get; set; }
Property Value
Type Description
Tizen.NUI.Components.FloatSelector
API Level: 6
View Source

Text

The text of Button.

Declaration
C#
Copy
public string Text { get; set; }
Property Value
Type Description
System.String
API Level: 6
View Source

TextAlignment

Text horizontal alignment in Button.

Declaration
C#
Copy
public HorizontalAlignment TextAlignment { get; set; }
Property Value
Type Description
HorizontalAlignment
API Level: 6
View Source

TextColor

Text color in Button.

Declaration
C#
Copy
public Color TextColor { get; set; }
Property Value
Type Description
Color
API Level: 6
View Source

TextColorSelector

Text color selector in Button.

Declaration
C#
Copy
public ColorSelector TextColorSelector { get; set; }
Property Value
Type Description
Tizen.NUI.Components.ColorSelector
API Level: 6
View Source

TextPadding

Text padding in Button, work only when show icon and text.

Declaration
C#
Copy
public Extents TextPadding { get; set; }
Property Value
Type Description
Extents
API Level: 6
View Source

TextSelector

Text string selector in Button.

Declaration
C#
Copy
public StringSelector TextSelector { get; set; }
Property Value
Type Description
Tizen.NUI.Components.StringSelector
API Level: 6
View Source

TranslatableText

Translate text string in Button.

Declaration
C#
Copy
public string TranslatableText { get; set; }
Property Value
Type Description
System.String
API Level: 6
View Source

TranslatableTextSelector

Translateable text string selector in Button.

Declaration
C#
Copy
public StringSelector TranslatableTextSelector { get; set; }
Property Value
Type Description
Tizen.NUI.Components.StringSelector
API Level: 6

Methods

View Source

Dispose(DisposeTypes)

Dispose Button and all children on it.

Declaration
C#
Copy
protected override void Dispose(DisposeTypes type)
Parameters
Type Name Description
DisposeTypes type

Dispose type.

Overrides
Tizen.NUI.Components.Control.Dispose(Tizen.NUI.DisposeTypes)
API Level: 6
View Source

OnKey(Key)

Called after a key event is received by the view that has had its focus set.

Declaration
C#
Copy
public override bool OnKey(Key key)
Parameters
Type Name Description
Key key

The key event.

Returns
Type Description
System.Boolean

True if the key event should be consumed.

Overrides
Tizen.NUI.Components.Control.OnKey(Tizen.NUI.Key)
API Level: 6

Events

View Source

ClickEvent

An event for the button clicked signal which can be used to subscribe or unsubscribe the event handler provided by the user.

Declaration
C#
Copy
public event EventHandler<Button.ClickEventArgs> ClickEvent
Event Type
Type Description
System.EventHandler<Button.ClickEventArgs>
API Level: 6
View Source

StateChangedEvent

An event for the button state changed signal which can be used to subscribe or unsubscribe the event handler provided by the user.

Declaration
C#
Copy
public event EventHandler<Button.StateChangedEventArgs> StateChangedEvent
Event Type
Type Description
System.EventHandler<Button.StateChangedEventArgs>
API Level: 6

Implements

System.ComponentModel.INotifyPropertyChanged
System.IDisposable