Class TextEditorExtensions
Definition
- Assembly:
- Tizen.NUI.Extension.dll
Markup extensions for View.
public static class TextEditorExtensions
- Inheritance
-
objectTextEditorExtensions
Methods
View SourceEllipsis<T>(T, bool)
The Ellipsis.
Enable or disable the ellipsis.
Placeholder PropertyMap is used to add ellipsis to placeholder text.
Declaration
public static T Ellipsis<T>(this T view, bool enabled) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| bool | enabled | The ellipsis value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
EllipsisPosition<T>(T, EllipsisPosition)
Specifies which portion of the text should be replaced with an ellipsis when the text size exceeds the layout size.
Declaration
public static T EllipsisPosition<T>(this T view, EllipsisPosition position) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| EllipsisPosition | position | The position value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
EnableEditing<T>(T, bool)
Enable editing in text control.
Declaration
public static T EnableEditing<T>(this T view, bool enabled) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| bool | enabled | The editing value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
EnableFontSizeScale<T>(T, bool)
Enable FontSizeScale to TextEditor.
Whether the font size scale is enabled. (The default value is true)
Declaration
public static T EnableFontSizeScale<T>(this T view, bool enabled) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| bool | enabled | The font size scale enabled value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
EnableMarkup<T>(T, bool)
Whether the mark-up processing is enabled.
Declaration
public static T EnableMarkup<T>(this T view, bool markup) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| bool | markup | The blink value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
EnableSelection<T>(T, bool)
Enables Text selection, such as the cursor, handle, clipboard, and highlight color.
Declaration
public static T EnableSelection<T>(this T view, bool enabled) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| bool | enabled | The selection value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
FontFamily<T>(T, string)
The requested font family to use.
Declaration
public static T FontFamily<T>(this T view, string family) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| string | family | The font family value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
FontSize<T>(T, float)
The size of font in pixels.
Declaration
public static T FontSize<T>(this T view, float size) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| float | size | The size value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
FontSizeScale<T>(T, float)
Set FontSizeScale to TextEditor.
The default value is 1.0.
The given font size scale value is used for multiplying the specified font size before querying fonts.
If FontSizeScale.UseSystemSetting, will use the SystemSettings.FontSize internally.
Declaration
public static T FontSizeScale<T>(this T view, float scale) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| float | scale | The scale value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
FontStyle<T>(T, FontWidthType, FontWeightType, FontSlantType)
Set FontStyle to TextEditor.
Declaration
public static T FontStyle<T>(this T view, FontWidthType width, FontWeightType weight, FontSlantType slant) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| FontWidthType | width | The font width value. |
| FontWeightType | weight | The font weight value. |
| FontSlantType | slant | The font slant value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
GrabHandleColor<T>(T, float, float, float, float)
The color of grab handle.
Declaration
public static T GrabHandleColor<T>(this T view, float r, float g, float b, float a = 1) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| float | r | The red component. |
| float | g | The green component. |
| float | b | The blue component. |
| float | a | The alpha component. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
GrabHandleColor<T>(T, uint, float)
The color of grab handle.
Declaration
public static T GrabHandleColor<T>(this T view, uint value, float alpha) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| uint | value | The value of 0xRRGGBB format. |
| float | alpha | The alpha value between 0.0 and 1.0. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
Examples
new UIColor(0xFF0000, 1f); // Solid red
new UIColor(0x00FF00, 0.5f) // Half transparent green
View Source
GrabHandleColor<T>(T, UIColor)
The color of grab handle.
Declaration
public static T GrabHandleColor<T>(this T view, UIColor color) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| UIColor | color | The color value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
InputColor(TextEditor)
Gets the color for the input.
Declaration
public static UIColor InputColor(this TextEditor view)
Parameters
| Type | Name | Description |
|---|---|---|
| TextEditor | view | The extension target. |
Returns
| Type | Description |
|---|---|
| UIColor | The input color value. |
InputColor<T>(T, float, float, float, float)
The color of the new input text.
Declaration
public static T InputColor<T>(this T view, float r, float g, float b, float a = 1) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| float | r | The red component. |
| float | g | The green component. |
| float | b | The blue component. |
| float | a | The alpha component. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
InputColor<T>(T, uint, float)
The color of the new input text.
Declaration
public static T InputColor<T>(this T view, uint value, float alpha) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| uint | value | The value of 0xRRGGBB format. |
| float | alpha | The alpha value between 0.0 and 1.0. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
Examples
new UIColor(0xFF0000, 1f); // Solid red
new UIColor(0x00FF00, 0.5f) // Half transparent green
View Source
InputColor<T>(T, UIColor)
The color of the new input text.
Declaration
public static T InputColor<T>(this T view, UIColor color) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| UIColor | color | The color value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
InputFontFamily<T>(T, string)
The font's family of the new input text.
Declaration
public static T InputFontFamily<T>(this T view, string family) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| string | family | The font family value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
InputFontStyle<T>(T, FontWidthType, FontWeightType, FontSlantType)
Set InputFontStyle to TextEditor.
Declaration
public static T InputFontStyle<T>(this T view, FontWidthType width, FontWeightType weight, FontSlantType slant) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| FontWidthType | width | The font width value. |
| FontWeightType | weight | The font weight value. |
| FontSlantType | slant | The font slant value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
PlaceholderText<T>(T, string)
The text to display when the TextEditor is empty and inactive.
Declaration
public static T PlaceholderText<T>(this T view, string text) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| string | text | The text value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
PlaceholderTextColor(TextEditor)
Gets the color for the placeholder text of the View.
Declaration
public static UIColor PlaceholderTextColor(this TextEditor view)
Parameters
| Type | Name | Description |
|---|---|---|
| TextEditor | view | The extension target. |
Returns
| Type | Description |
|---|---|
| UIColor | The placeholder text color value. |
PlaceholderTextColor<T>(T, float, float, float, float)
The color of the placeholder text.
Declaration
public static T PlaceholderTextColor<T>(this T view, float r, float g, float b, float a = 1) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| float | r | The red component. |
| float | g | The green component. |
| float | b | The blue component. |
| float | a | The alpha component. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
PlaceholderTextColor<T>(T, uint, float)
The color of the placeholder text.
Declaration
public static T PlaceholderTextColor<T>(this T view, uint value, float alpha) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| uint | value | The value of 0xRRGGBB format. |
| float | alpha | The alpha value between 0.0 and 1.0. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
Examples
TextEditor.PlaceholderTextColor(0xFF0000, 1f); // Solid red
TextEditor.PlaceholderTextColor(0x00FF00, 0.5f) // Half transparent green
View Source
PlaceholderTextColor<T>(T, UIColor)
The color of the placeholder text.
Declaration
public static T PlaceholderTextColor<T>(this T view, UIColor color) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| UIColor | color | The color value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
PrimaryCursorColor(TextEditor)
Gets the color for the primary cursor.
Declaration
public static UIColor PrimaryCursorColor(this TextEditor view)
Parameters
| Type | Name | Description |
|---|---|---|
| TextEditor | view | The extension target. |
Returns
| Type | Description |
|---|---|
| UIColor | The primary cursor color value. |
PrimaryCursorColor<T>(T, float, float, float, float)
The color to apply to the primary cursor.
Declaration
public static T PrimaryCursorColor<T>(this T view, float r, float g, float b, float a = 1) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| float | r | The red component. |
| float | g | The green component. |
| float | b | The blue component. |
| float | a | The alpha component. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
PrimaryCursorColor<T>(T, uint, float)
The color to apply to the primary cursor.
Declaration
public static T PrimaryCursorColor<T>(this T view, uint value, float alpha) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| uint | value | The value of 0xRRGGBB format. |
| float | alpha | The alpha value between 0.0 and 1.0. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
Examples
new UIColor(0xFF0000, 1f); // Solid red
new UIColor(0x00FF00, 0.5f) // Half transparent green
View Source
PrimaryCursorColor<T>(T, UIColor)
The color to apply to the primary cursor.
Declaration
public static T PrimaryCursorColor<T>(this T view, UIColor color) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| UIColor | color | The color value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
SecondaryCursorColor(TextEditor)
Gets the color for the secondary cursor.
Declaration
public static UIColor SecondaryCursorColor(this TextEditor view)
Parameters
| Type | Name | Description |
|---|---|---|
| TextEditor | view | The extension target. |
Returns
| Type | Description |
|---|---|
| UIColor | The secondary cursor color value. |
SecondaryCursorColor<T>(T, float, float, float, float)
The color to apply to the secondary cursor.
Declaration
public static T SecondaryCursorColor<T>(this T view, float r, float g, float b, float a = 1) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| float | r | The red component. |
| float | g | The green component. |
| float | b | The blue component. |
| float | a | The alpha component. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
SecondaryCursorColor<T>(T, uint, float)
The color to apply to the secondary cursor.
Declaration
public static T SecondaryCursorColor<T>(this T view, uint value, float alpha) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| uint | value | The value of 0xRRGGBB format. |
| float | alpha | The alpha value between 0.0 and 1.0. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
Examples
new UIColor(0xFF0000, 1f); // Solid red
new UIColor(0x00FF00, 0.5f) // Half transparent green
View Source
SecondaryCursorColor<T>(T, UIColor)
The color to apply to the secondary cursor.
Declaration
public static T SecondaryCursorColor<T>(this T view, UIColor color) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| UIColor | color | The color value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
SelectionHighlightColor(TextEditor)
Gets the color for the selection highlight.
Declaration
public static UIColor SelectionHighlightColor(this TextEditor view)
Parameters
| Type | Name | Description |
|---|---|---|
| TextEditor | view | The extension target. |
Returns
| Type | Description |
|---|---|
| UIColor | The selection highlight color value. |
SelectionHighlightColor<T>(T, float, float, float, float)
The color of the selection highlight.
Declaration
public static T SelectionHighlightColor<T>(this T view, float r, float g, float b, float a = 1) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| float | r | The red component. |
| float | g | The green component. |
| float | b | The blue component. |
| float | a | The alpha component. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
SelectionHighlightColor<T>(T, uint, float)
The color of the selection highlight.
Declaration
public static T SelectionHighlightColor<T>(this T view, uint value, float alpha) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| uint | value | The value of 0xRRGGBB format. |
| float | alpha | The alpha value between 0.0 and 1.0. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
Examples
new UIColor(0xFF0000, 1f); // Solid red
new UIColor(0x00FF00, 0.5f) // Half transparent green
View Source
SelectionHighlightColor<T>(T, UIColor)
The color of the selection highlight.
Declaration
public static T SelectionHighlightColor<T>(this T view, UIColor color) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| UIColor | color | The color value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
Text<T>(T, string)
The text to display in the UTF-8 format.
Declaration
public static T Text<T>(this T view, string text) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| string | text | The text value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
TextAlignment<T>(T, HorizontalAlignment, VerticalAlignment)
The line vertical alignment.
Declaration
public static T TextAlignment<T>(this T view, HorizontalAlignment horizontal, VerticalAlignment vertical) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| HorizontalAlignment | horizontal | The horizontal value. |
| VerticalAlignment | vertical | The vertical value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
TextColor(TextEditor)
Gets the color for the text of the View.
Declaration
public static UIColor TextColor(this TextEditor view)
Parameters
| Type | Name | Description |
|---|---|---|
| TextEditor | view | The extension target. |
Returns
| Type | Description |
|---|---|
| UIColor | The text color value. |
TextColor<T>(T, float, float, float, float)
The color of the text.
Declaration
public static T TextColor<T>(this T view, float r, float g, float b, float a = 1) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| float | r | The red component. |
| float | g | The green component. |
| float | b | The blue component. |
| float | a | The alpha component. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
TextColor<T>(T, uint, float)
The color of the text.
Declaration
public static T TextColor<T>(this T view, uint value, float alpha) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| uint | value | The value of 0xRRGGBB format. |
| float | alpha | The alpha value between 0.0 and 1.0. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
Examples
new UIColor(0xFF0000, 1f); // Solid red
new UIColor(0x00FF00, 0.5f) // Half transparent green
View Source
TextColor<T>(T, UIColor)
The color of the text.
Declaration
public static T TextColor<T>(this T view, UIColor color) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| UIColor | color | The color value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
TranslatablePlaceholderText<T>(T, string)
The text can set the SID value.
Declaration
public static T TranslatablePlaceholderText<T>(this T view, string text) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| string | text | The text value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |
TranslatableText<T>(T, string)
The text can set the SID value.
Declaration
public static T TranslatableText<T>(this T view, string text) where T : TextEditor
Parameters
| Type | Name | Description |
|---|---|---|
| T | view | The extension target. |
| string | text | The text value. |
Returns
| Type | Description |
|---|---|
| T | The view itself. |
Type Parameters
| Name | Description |
|---|---|
| T | The type of the view. |