Class Drawable
Definition
- Namespace:
- Tizen.NUI.BaseComponents.VectorGraphics
- Assembly:
- Tizen.NUI.dll
- API Level:
- 9
Drawable is a object class for drawing a vector primitive.
C#Copypublic class Drawable : BaseHandle, INotifyPropertyChanged, IDynamicResourceHandler, IElement, INameScope, IElementController, IDisposable
- Inheritance
- Derived
- Implements
-
System.ComponentModel.INotifyPropertyChangedSystem.IDisposable
Properties
BoundingBox
The bounding box of the drawable object to which no transformation has been applied.
Declaration
C#Copypublic Vector4 BoundingBox { get; }
Property Value
Type | Description |
---|---|
Vector4 |
Remarks
The bounding box doesn't indicate the rendering region in the result but primitive region of the object.
API Level: 9
Opacity
The transparency level [0 ~ 1.0], 0 means totally transparent, while 1 means opaque.
Declaration
C#Copypublic float Opacity { get; set; }
Property Value
Type | Description |
---|---|
System.Single |
API Level: 9
Methods
ClipPath(Drawable)
The intersection with clip drawable is determined and only the resulting pixels from own drawable are rendered.
Declaration
C#Copypublic void ClipPath(Drawable clip)
Parameters
Type | Name | Description |
---|---|---|
Drawable | clip | The clip drawable object. |
Exceptions
Type | Condition |
---|---|
Exception | Drawable clpping failed. |
System.ArgumentNullException | Thrown when drawable is null. |
API Level: 9
Mask(Drawable, MaskType)
The pixels of mask drawable and own drawable are blended according to MaskType.
Declaration
C#Copypublic void Mask(Drawable mask, MaskType type)
Parameters
Type | Name | Description |
---|---|---|
Drawable | mask | The mask drawable object. |
MaskType | type | The masking type. |
Exceptions
Type | Condition |
---|---|
Exception | Drawable masking failed. |
System.ArgumentNullException | Thrown when drawable is null. |
API Level: 9
Declaration
C#Copypublic bool Rotate(float degree)
Parameters
Type | Name | Description |
---|---|---|
System.Single | degree | The degree value of angle. |
Returns
Type | Description |
---|---|
Boolean | True when it's successful. False otherwise. |
API Level: 9
Declaration
C#Copypublic bool Scale(float factor)
Parameters
Type | Name | Description |
---|---|---|
System.Single | factor | The scale factor value. |
Returns
Type | Description |
---|---|
Boolean | True when it's successful. False otherwise. |
API Level: 9
Declaration
C#Copypublic bool Transform(float[] matrix)
Parameters
Type | Name | Description |
---|---|---|
System.Single[] | matrix | The float type array of 3x3 matrix. |
Returns
Type | Description |
---|---|
Boolean | True when it's successful. False otherwise. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | Thrown when matrix is null. |
System.ArgumentException | Thrown when matrix array length is not 9. |
API Level: 9
Declaration
C#Copypublic bool Translate(float x, float y)
Parameters
Type | Name | Description |
---|---|---|
System.Single | x | The x-axis movement value. |
System.Single | y | The y-axis movement value. |
Returns
Type | Description |
---|---|
Boolean | True when it's successful. False otherwise. |