Class AutocompleteBehavior
This class presents a behavior for the autocomplete used in the ItemsControls.
Inheritance
Namespace: Telerik.Windows.Controls.Primitives
Assembly: Telerik.Windows.Controls.dll
Syntax
public class AutocompleteBehavior : Object
Constructors
AutocompleteBehavior()
Initializes a new instance of the Autocomplete
Declaration
public AutocompleteBehavior()
Properties
AllowCustomText
Gets or sets a value indicating whether a custom text is allowed.
Declaration
public bool AllowCustomText { get; set; }
Property Value
System.
|
AutoCompleteTimeout
Gets or sets the autocomplete timeout. When the timeout is over, the typed text for the autocomplete is reset.
Declaration
public static TimeSpan AutoCompleteTimeout { get; set; }
Property Value
System.
|
CurrentText
Gets the current text that is used for the autocomplete.
Declaration
public string CurrentText { get; }
Property Value
System.
|
IsIndexSelectable
Gets or sets whether the item associated with the index is selectable.
Declaration
public Func<int, bool> IsIndexSelectable { get; set; }
Property Value
System.
|
ItemSearch
Gets or sets the ItemSearch for the autocomplete. The IItemSearchControl object defines the logic how the items are found with the retrievers.
Declaration
public IItemSearchControl ItemSearch { get; set; }
Property Value
LastSelectionLength
Gets the last length of the selection.
Declaration
protected int LastSelectionLength { get; }
Property Value
System.
|
LastSelectionStart
Gets the last selection start.
Declaration
protected int LastSelectionStart { get; }
Property Value
System.
|
LastText
Gets the last text that is set.
Declaration
protected string LastText { get; }
Property Value
System.
|
MatchingItem
Gets the matching item.
Declaration
public object MatchingItem { get; }
Property Value
System.
|
TextRetriever
Gets or sets the text Retriever that is used for autocomplete.
Declaration
public IValueRetriever TextRetriever { get; set; }
Property Value
TextSearchMode
Gets or sets the text search mode. Specifies how TextSearch will match items.
Declaration
public TextSearchMode TextSearchMode { get; set; }
Property Value
Text The text search mode. |
TextSource
Gets or sets the text source.
Declaration
public ITextSource TextSource { get; set; }
Property Value
Methods
ExtractCurrentText()
Extracts the current text from the current selection to its length.
Declaration
protected virtual string ExtractCurrentText()
Returns
System.
|
IsFullMatch(Object)
Determines whether the matched item is found with full match or not.
Declaration
public bool IsFullMatch(object item)
Parameters
System. The item. |
Returns
System.
|
SetCurrentText(String)
Sets a current text for the autocomplete.
Declaration
public bool SetCurrentText(string text)
Parameters
System. The text. |
Returns
System.
|
TextSourceSelectionChangeDetected()
This property is used to detect whether the test source selection change is detected or not.
Declaration
protected bool TextSourceSelectionChangeDetected()
Returns
System.
|
TextSourceTextChangeDetected()
This property is used to detect whether the test source text change is detected or not.
Declaration
protected bool TextSourceTextChangeDetected()
Returns
System.
|
UpdateCurrentText()
Updates the current text.
Declaration
protected bool UpdateCurrentText()
Returns
System.
|
UpdateTextSource(String, String)
Updates the text source according the current and matching item text.
Declaration
protected virtual void UpdateTextSource(string text, string matchingItemText)
Parameters
System. The current text. |
System. The matching item text. |
UpdateTextSourceStateCache()
Updates the text source state cache.
Declaration
protected virtual void UpdateTextSourceStateCache()
Events
CurrentTextChanged
Occurs when current text is changed.
Declaration
public event EventHandler CurrentTextChanged
Event Type
System.
|
MatchingItemChanged
Occurs when matching item is changed.
Declaration
public event EventHandler MatchingItemChanged
Event Type
System.
|