Class Entry
Definition
- Namespace:
- ElmSharp
- Assembly:
- ElmSharp.dll
- API Level:
- preview
The Entry is a convenience widget that shows a box in which the user can enter text.
public class Entry : Layout, IAccessibleObject
- Inheritance
- Implements
Constructors
View SourceEntry(EvasObject)
Creates and initializes a new instance of the Entry class.
Declaration
public Entry(EvasObject parent)
Parameters
Type | Name | Description |
---|---|---|
EvasObject | parent | The EvasObject to which the new Entry will be attached as a child. |
API Level: preview
Properties
View SourceAutoCapital
Sets or gets the autocapitalization type on the immodule.
Declaration
public AutoCapital AutoCapital { get; set; }
Property Value
Type | Description |
---|---|
AutoCapital |
API Level: preview
View SourceCopyAndPasteMode
Sets or gets the entry text paste/drop mode.
Declaration
public CopyAndPasteMode CopyAndPasteMode { get; set; }
Property Value
Type | Description |
---|---|
CopyAndPasteMode |
API Level: preview
View SourceCursorGeometry
Gets the geometry of the cursor.
Declaration
public Rect CursorGeometry { get; }
Property Value
Type | Description |
---|---|
Rect |
API Level: preview
View SourceCursorPosition
Sets or gets the current position of the cursor in the entry.
Declaration
public int CursorPosition { get; set; }
Property Value
Type | Description |
---|---|
Int32 |
API Level: preview
View SourceHorizontalBounce
Sets or gets the horizontal bounce behavior. When scrolling, the scroller may "bounce" when reaching an edge of the content object. This is a visual way to indicate that the end has reached. This is enabled by default for both the axis. This API will be set if it is enabled for the given axis with boolean parameters for each axis.
Declaration
public bool HorizontalBounce { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
API Level: preview
View SourceHorizontalScrollBarVisiblePolicy
Sets or gets the value of the HorizontalScrollBarVisiblePolicy.
Declaration
public virtual ScrollBarVisiblePolicy HorizontalScrollBarVisiblePolicy { get; set; }
Property Value
Type | Description |
---|---|
ScrollBarVisiblePolicy |
Remarks
ScrollBarVisiblePolicy.Auto means that the horizontal scrollbar is made visible if it is needed, or otherwise kept hidden. ScrollBarVisiblePolicy.Visible turns it on all the time, and ScrollBarVisiblePolicy.Invisible always keeps it off.
API Level: preview
View SourceInputHint
Sets or gets the value of the input hint.
Declaration
public InputHints InputHint { get; set; }
Property Value
Type | Description |
---|---|
InputHints |
API Level: preview
View SourceInputPanelLanguage
Sets or gets the language mode of the input panel.
Declaration
public InputPanelLanguage InputPanelLanguage { get; set; }
Property Value
Type | Description |
---|---|
InputPanelLanguage |
API Level: preview
View SourceInputPanelReturnKeyDisabled
Sets or gets whether the return key on the input panel should be disabled or not.
Declaration
public bool InputPanelReturnKeyDisabled { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
API Level: preview
View SourceInputPanelShowByOnDemand
Sets or gets the attribute to show the input panel, in case of only an user's explicit Mouse Up event. It doesn't request to show the input panel even though it has focus. If true, the input panel will be shown only in case of the Mouse up event (Focus event will be ignored).
Declaration
public bool InputPanelShowByOnDemand { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
API Level: preview
View SourceInputPanelVariation
Sets or gets the input panel layout variation of the entry.
Declaration
public int InputPanelVariation { get; set; }
Property Value
Type | Description |
---|---|
Int32 |
API Level: preview
View SourceIsAutoSave
Sets or gets the entry object's 'autosave' status.
Declaration
public bool IsAutoSave { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
API Level: preview
View SourceIsCursorFormat
Gets whether a format node exists at the current cursor position.
Declaration
public bool IsCursorFormat { get; }
Property Value
Type | Description |
---|---|
Boolean |
API Level: preview
View SourceIsCursorVisibelFormat
Gets if the current cursor position holds a visible format node.
Declaration
public bool IsCursorVisibelFormat { get; }
Property Value
Type | Description |
---|---|
Boolean |
API Level: preview
View SourceIsEditable
Sets or gets whether the entry is editable.
Declaration
public bool IsEditable { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
API Level: preview
View SourceIsEmpty
Sets or gets whether the entry is empty.
Declaration
public bool IsEmpty { get; }
Property Value
Type | Description |
---|---|
Boolean |
API Level: preview
View SourceIsPassword
Sets or gets the entry to the password mode.
Declaration
public bool IsPassword { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
API Level: preview
View SourceIsSingleLine
Sets or gets the entry to the single line mode.
Declaration
public bool IsSingleLine { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
API Level: preview
View SourceLineWrapType
Sets or gets the line wrap type to use on multiline entries.
Declaration
public WrapType LineWrapType { get; set; }
Property Value
Type | Description |
---|---|
WrapType |
API Level: preview
View SourcePredictionAllowed
Sets or gets whether the entry should allow to use the text prediction.
Declaration
public bool PredictionAllowed { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
API Level: preview
View SourceScrollable
Sets or gets the scrollable state of the entry.
Declaration
public bool Scrollable { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
API Level: preview
View SourceText
Sets or gets the text currently shown in the object entry.
Declaration
public override string Text { get; set; }
Property Value
Type | Description |
---|---|
String |
Overrides
API Level: preview
View SourceTextStyle
Sets or gets the style on top of the user style stack.
Declaration
public string TextStyle { get; set; }
Property Value
Type | Description |
---|---|
String |
Remarks
If there are styles in the user style stack, the properties in the top style of the user style stack will replace the properties in current theme. The input style is specified in the format, tag='property=value' (i.e., DEFAULT='font=Sans font_size=60'hilight=' + font_weight=Bold').
API Level: preview
View SourceVerticalBounce
Sets or gets the vertical bounce behavior. When scrolling, the scroller may "bounce" when reaching an edge of the content object. This is a visual way to indicate that the end has reached. This is enabled by default for both the axis. This API will be set if it is enabled for the given axis with boolean parameters for each axis.
Declaration
public bool VerticalBounce { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
API Level: preview
View SourceVerticalScrollBarVisiblePolicy
Sets or gets the value of VerticalScrollBarVisiblePolicy.
Declaration
public virtual ScrollBarVisiblePolicy VerticalScrollBarVisiblePolicy { get; set; }
Property Value
Type | Description |
---|---|
ScrollBarVisiblePolicy |
Remarks
ScrollBarVisiblePolicy.Auto means that the vertical scrollbar is made visible if it is needed, or otherwise kept hidden. ScrollBarVisiblePolicy.Visible turns it on all the time, and ScrollBarVisiblePolicy.Invisible always keeps it off.
API Level: preview
Methods
View SourceAppendItemProvider(Func<String, EvasObject>)
This appends a custom item provider to the list for that entry.
Declaration
public void AppendItemProvider(Func<string, EvasObject> func)
Parameters
Type | Name | Description |
---|---|---|
Func<String, EvasObject> | func | This function is used to provide items. |
API Level: preview
View SourceAppendMarkUpFilter(Func<Entry, String, String>)
Appends a markup filter function for text inserted in the entry.
Declaration
public void AppendMarkUpFilter(Func<Entry, string, string> filter)
Parameters
Type | Name | Description |
---|---|---|
Func<Entry, String, String> | filter | This function type is used by entry filters to modify text. |
API Level: preview
View SourceAppendText(String)
Appends the text of the entry.
Declaration
public void AppendText(string text)
Parameters
Type | Name | Description |
---|---|---|
String | text | The text to be displayed. |
API Level: preview
View SourceBeginCursorSelection()
Begins a selection within the entry, as though the user was holding down the mouse button to make a selection.
Declaration
public void BeginCursorSelection()
API Level: preview
View SourceConvertMarkupToUtf8(String)
Converts a markup (HTML-like) string into UTF-8.
Declaration
public static string ConvertMarkupToUtf8(string markup)
Parameters
Type | Name | Description |
---|---|---|
String | markup | The string (in markup) to be converted. |
Returns
Type | Description |
---|---|
String | The converted string (in UTF-8). |
API Level: preview
View SourceCopySelection()
This executes a "copy" action on the selected text in the entry.
Declaration
public void CopySelection()
API Level: preview
View SourceCreateHandle(EvasObject)
Creates a widget handle.
Declaration
protected override IntPtr CreateHandle(EvasObject parent)
Parameters
Type | Name | Description |
---|---|---|
EvasObject | parent | Parent EvasObject. |
Returns
Type | Description |
---|---|
IntPtr | Handle IntPtr. |
Overrides
API Level: preview
View SourceCutSelection()
This executes a "cut" action on the selected text in the entry.
Declaration
public void CutSelection()
API Level: preview
View SourceDisableSelection(Boolean)
This disables the entry's selection handlers. This works properly on the profile that provides selection handlers.
Declaration
public void DisableSelection(bool disable)
Parameters
Type | Name | Description |
---|---|---|
Boolean | disable | If true, the selection handlers are disabled. |
API Level: preview
View SourceEndCursorSelection()
Ends a selection within the entry as though the user had just released the mouse button while making a selection.
Declaration
public void EndCursorSelection()
API Level: preview
View SourceForceCalculation()
Forces calculation of the entry size and text layout.
Declaration
public void ForceCalculation()
API Level: preview
View SourceGetCursorContent()
Gets the string by the cursor at its current position.
Declaration
public string GetCursorContent()
Returns
Type | Description |
---|---|
String |
API Level: preview
View SourceGetSelection()
Gets any selected text within the entry.
Declaration
public string GetSelection()
Returns
Type | Description |
---|---|
String | Selection's value. |
API Level: preview
View SourceHideInputPanel()
Hides the input panel (virtual keyboard).
Declaration
public void HideInputPanel()
Remarks
Note that the input panel is shown or hidden automatically according to the focus state of the entry widget. This API can be used in case of manually controlling by using SetInputPanelEnabled(false).
API Level: preview
View SourceInsertTextToCursor(String)
Inserts the given text into the entry at the current cursor position.
Declaration
public void InsertTextToCursor(string text)
Parameters
Type | Name | Description |
---|---|---|
String | text | The text to be inserted. |
API Level: preview
View SourceMoveCursorBegin()
Moves the cursor to the beginning of the entry.
Declaration
public void MoveCursorBegin()
API Level: preview
View SourceMoveCursorDown()
Moves the cursor one line down within the entry.
Declaration
public bool MoveCursorDown()
Returns
Type | Description |
---|---|
Boolean | TRUE on success, otherwise FALSE on failure. |
API Level: preview
View SourceMoveCursorEnd()
Moves the cursor to the end of the entry.
Declaration
public void MoveCursorEnd()
API Level: preview
View SourceMoveCursorLineBegin()
Moves the cursor to the beginning of the current line.
Declaration
public void MoveCursorLineBegin()
API Level: preview
View SourceMoveCursorLineEnd()
Moves the cursor to the end of the current line.
Declaration
public void MoveCursorLineEnd()
API Level: preview
View SourceMoveCursorNext()
Moves the cursor by one position to the right within the entry.
Declaration
public bool MoveCursorNext()
Returns
Type | Description |
---|---|
Boolean |
API Level: preview
View SourceMoveCursorPrev()
Moves the cursor one place to the left within the entry.
Declaration
public bool MoveCursorPrev()
Returns
Type | Description |
---|---|
Boolean | TRUE on success, otherwise FALSE on failure. |
API Level: preview
View SourceMoveCursorUp()
Moves the cursor one line up within the entry.
Declaration
public bool MoveCursorUp()
Returns
Type | Description |
---|---|
Boolean | TRUE on success, otherwise FALSE on failure. |
API Level: preview
View SourcePasteSelection()
This executes a "paste" action in the entry.
Declaration
public void PasteSelection()
API Level: preview
View SourcePrependItemProvider(Func<String, EvasObject>)
This prepends a custom item provider to the list for that entry.
Declaration
public void PrependItemProvider(Func<string, EvasObject> func)
Parameters
Type | Name | Description |
---|---|---|
Func<String, EvasObject> | func | This function is used to provide items. |
API Level: preview
View SourcePrependMarkUpFilter(Func<Entry, String, String>)
Prepends a markup filter function for text inserted in the entry.
Declaration
public void PrependMarkUpFilter(Func<Entry, string, string> filter)
Parameters
Type | Name | Description |
---|---|---|
Func<Entry, String, String> | filter | This function type is used by entry filters to modify text. |
API Level: preview
View SourceRemoveItemProvider(Func<String, EvasObject>)
This removes a custom item provider to the list for that entry.
Declaration
public void RemoveItemProvider(Func<string, EvasObject> func)
Parameters
Type | Name | Description |
---|---|---|
Func<String, EvasObject> | func | This function is used to provide items. |
API Level: preview
View SourceRemoveMarkUpFilter(Func<Entry, String, String>)
Removes a markup filter.
Declaration
public void RemoveMarkUpFilter(Func<Entry, string, string> filter)
Parameters
Type | Name | Description |
---|---|---|
Func<Entry, String, String> | filter | This function type is used by entry filters to modify text. |
API Level: preview
View SourceSaveFile()
Writes any changes made to the file that is set by a file.
Declaration
public void SaveFile()
API Level: preview
View SourceSelectAll()
Selects all the text within the entry.
Declaration
public void SelectAll()
API Level: preview
View SourceSelectNone()
Drops any existing text selection within the entry.
Declaration
public void SelectNone()
API Level: preview
View SourceSetFile(String, TextFormat)
Sets the file (and implicitly loads it) for the text to display and then edit.
Declaration
public void SetFile(string file, TextFormat textFormat)
Parameters
Type | Name | Description |
---|---|---|
String | file | The path to the file to load and save. |
TextFormat | textFormat | The file format. |
API Level: preview
View SourceSetIconVisible(Boolean)
Sets the visibility of the left-side widget of the entry.
Declaration
public void SetIconVisible(bool isDisplay)
Parameters
Type | Name | Description |
---|---|---|
Boolean | isDisplay | true if the object should be displayed, otherwise false. |
API Level: preview
View SourceSetInputPanelEnabled(Boolean)
Sets the attribute to show the input panel automatically.
Declaration
public void SetInputPanelEnabled(bool enabled)
Parameters
Type | Name | Description |
---|---|---|
Boolean | enabled | If true, the input panel appears when the entry is clicked or has focus, otherwise false. |
API Level: preview
View SourceSetInputPanelLayout(InputPanelLayout)
Sets the input panel layout of the entry.
Declaration
public void SetInputPanelLayout(InputPanelLayout layout)
Parameters
Type | Name | Description |
---|---|---|
InputPanelLayout | layout | The layout type. |
API Level: preview
View SourceSetInputPanelReturnKeyAutoEnable(Boolean)
Sets whether the return key on the input panel is disabled automatically, when the entry has no text.
Declaration
public void SetInputPanelReturnKeyAutoEnable(bool enable)
Parameters
Type | Name | Description |
---|---|---|
Boolean | enable | If enabled is true, the return key is automatically disabled when the entry has no text. |
API Level: preview
View SourceSetInputPanelReturnKeyType(InputPanelReturnKeyType)
Sets the "return" key type. This type is used to set the string or icon on the "return" key of the input panel.
Declaration
public void SetInputPanelReturnKeyType(InputPanelReturnKeyType keyType)
Parameters
Type | Name | Description |
---|---|---|
InputPanelReturnKeyType | keyType | The type of "return" key on the input panel. |
API Level: preview
View SourceSetSelectionRegion(Int32, Int32)
This selects a region of text within the entry.
Declaration
public void SetSelectionRegion(int start, int end)
Parameters
Type | Name | Description |
---|---|---|
Int32 | start | The start position. |
Int32 | end | The end position. |
API Level: preview
View SourceShowInputPanel()
Show the input panel (virtual keyboard) based on the input panel property of the entry such as layout, autocapital types, and so on.
Declaration
public void ShowInputPanel()
Remarks
Note that the input panel is shown or hidden automatically according to the focus state of the entry widget. This API can be used in the case of manual control by using the SetInputPanelEnabled(false).
API Level: preview
Events
View SourceActivated
Activated will be triggered when the entry is activated.
Declaration
public event EventHandler Activated
Event Type
Type | Description |
---|---|
EventHandler |
API Level: preview
View SourceChangedByUser
ChangedByUser will be triggered when the entry is changed by user.
Declaration
public event EventHandler ChangedByUser
Event Type
Type | Description |
---|---|
EventHandler |
API Level: preview
View SourceClicked
Clicked will be triggered when the entry is clicked.
Declaration
public event EventHandler Clicked
Event Type
Type | Description |
---|---|
EventHandler |
API Level: preview
View SourceCursorChanged
CursorChanged will be triggered when the cursor in the entry is changed.
Declaration
public event EventHandler CursorChanged
Event Type
Type | Description |
---|---|
EventHandler |