Struct LayoutLength
Definition
- Assembly:
- Tizen.NUI.dll
A type that represents a layout length. Currently, this implies pixels, but could be extended to handle device dependant sizes, etc.
C#
Copy
public struct LayoutLength : IEquatable<LayoutLength>
- Implements
-
System.IEquatable<T><Layout
Length >
Constructors
Declaration
C#
Copy
public LayoutLength(int value)
Parameters
Type | Name | Description |
---|---|---|
int | value | Int to initialize with. |
Declaration
C#
Copy
public LayoutLength(float value)
Parameters
Type | Name | Description |
---|---|---|
float | value | Float to initialize with. |
Declaration
C#
Copy
public LayoutLength(LayoutLength layoutLength)
Parameters
Type | Name | Description |
---|---|---|
Layout |
layoutLength | LayoutLength object to initialize with. |
Methods
Declaration
C#
Copy
public float AsDecimal()
Returns
Type | Description |
---|---|
float | The layout length value as the raw decimal value. |
AsRoundedValue()
Return value as rounded value (whole number), best used as final output
Declaration
C#
Copy
public float AsRoundedValue()
Returns
Type | Description |
---|---|
float | The layout length value as a rounded whole number. |
Declaration
C#
Copy
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
object | obj | The object to compare with the current object. |
Returns
Type | Description |
---|---|
bool | true if equal LayoutLength, else false. |
Overrides
Equals(LayoutLength)
Determines whether the specified object is equal to the current object.
Declaration
C#
Copy
public bool Equals(LayoutLength layoutLength)
Parameters
Type | Name | Description |
---|---|---|
Layout |
layoutLength | The LayoutLength to compare with the current LayoutLength. |
Returns
Type | Description |
---|---|
bool | true if equal LayoutLengths, else false. |
Declaration
C#
Copy
public override int GetHashCode()
Returns
Type | Description |
---|---|
int | Calculated hash code. |
Overrides
Operators
Declaration
C#
Copy
public static LayoutLength operator +(LayoutLength arg1, int arg2)
Parameters
Type | Name | Description |
---|---|---|
Layout |
arg1 | The first value. |
int | arg2 | The second value. |
Returns
Type | Description |
---|---|
Layout |
The LayoutLength containing the result of the addition. |
Declaration
C#
Copy
public static LayoutLength operator +(LayoutLength arg1, LayoutLength arg2)
Parameters
Type | Name | Description |
---|---|---|
Layout |
arg1 | The first value. |
Layout |
arg2 | The second value. |
Returns
Type | Description |
---|---|
Layout |
The LayoutLength containing the result of the addition. |
Declaration
C#
Copy
public static LayoutLength operator /(LayoutLength arg1, int arg2)
Parameters
Type | Name | Description |
---|---|---|
Layout |
arg1 | The first value. |
int | arg2 | The int value to scale the vector by. |
Returns
Type | Description |
---|---|
Layout |
The LayoutLength containing the result of the scaling. |
Declaration
C#
Copy
public static LayoutLength operator /(LayoutLength arg1, LayoutLength arg2)
Parameters
Type | Name | Description |
---|---|---|
Layout |
arg1 | The first value. |
Layout |
arg2 | The second value. |
Returns
Type | Description |
---|---|
Layout |
The LayoutLength containing the result of the division. |
Declaration
C#
Copy
public static bool operator ==(LayoutLength arg1, LayoutLength arg2)
Parameters
Type | Name | Description |
---|---|---|
Layout |
arg1 | The first value. |
Layout |
arg2 | The second value |
Returns
Type | Description |
---|---|
bool | true if LayoutLengths are equal |
Declaration
C#
Copy
public static bool operator !=(LayoutLength arg1, LayoutLength arg2)
Parameters
Type | Name | Description |
---|---|---|
Layout |
arg1 | The first value. |
Layout |
arg2 | The second value |
Returns
Type | Description |
---|---|
bool | true if LayoutLengths are not equal |
Declaration
C#
Copy
public static LayoutLength operator *(LayoutLength arg1, int arg2)
Parameters
Type | Name | Description |
---|---|---|
Layout |
arg1 | The first value. |
int | arg2 | The int value to scale the LayoutLength. |
Returns
Type | Description |
---|---|
Layout |
The LayoutLength containing the result of the scaling. |
Declaration
C#
Copy
public static LayoutLength operator *(LayoutLength arg1, LayoutLength arg2)
Parameters
Type | Name | Description |
---|---|---|
Layout |
arg1 | The first value. |
Layout |
arg2 | The second value. |
Returns
Type | Description |
---|---|
Layout |
The LayoutLength containing the result of the multiplication. |
Declaration
C#
Copy
public static LayoutLength operator -(LayoutLength arg1, int arg2)
Parameters
Type | Name | Description |
---|---|---|
Layout |
arg1 | The first value. |
int | arg2 | The second value. |
Returns
Type | Description |
---|---|
Layout |
The LayoutLength containing the result of the subtraction. |
Declaration
C#
Copy
public static LayoutLength operator -(LayoutLength arg1, LayoutLength arg2)
Parameters
Type | Name | Description |
---|---|---|
Layout |
arg1 | The first value. |
Layout |
arg2 | The second value. |
Returns
Type | Description |
---|---|
Layout |
The LayoutLength containing the result of the subtraction. |