New to Telerik UI for WinFormsStart a free 30-day trial

Represent a navigator in RadTextBoxControlElement

Definition

Namespace:Telerik.WinControls.UI

Assembly:Telerik.WinControls.UI.dll

Syntax:

C#
public class TextBoxNavigator : ITextBoxNavigator, IDisposable

Inheritance: objectTextBoxNavigator

Derived Classes: AutoCompleteTextNavigator

Implements: IDisposableITextBoxNavigator

Constructors

Initializes a new instance of the TextBoxNavigator class.

C#
public TextBoxNavigator(RadTextBoxControlElement textBoxElement)
Parameters:textBoxElementRadTextBoxControlElement

The text box element.

Properties

Gets or sets the caret position.

C#
public TextPosition CaretPosition { get; set; }
Property Value:

The caret position.

Implements: ITextBoxNavigator.CaretPosition

Gets or sets the selection end.

C#
public TextPosition SelectionEnd { get; set; }
Property Value:

The selection end.

Implements: ITextBoxNavigator.SelectionEnd

Gets the length of the selection.

C#
public int SelectionLength { get; }
Property Value:

The length of the selection.

Implements: ITextBoxNavigator.SelectionLength

Gets or sets the selection start.

C#
public TextPosition SelectionStart { get; set; }
Property Value:

The selection start.

Implements: ITextBoxNavigator.SelectionStart

Gets the associated text box element.

C#
protected RadTextBoxControlElement TextBoxElement { get; }

Methods

C#
protected ~TextBoxNavigator()
C#
public void Dispose()

Implements: IDisposable.Dispose()

C#
protected virtual void Dispose(bool disposing)
Parameters:disposingbool

Gets the next position.

C#
public virtual TextPosition GetNextPosition(TextPosition position, bool isControlPressed)
Parameters:positionTextPosition

The position.

isControlPressedbool

True if Control modifier key is pressed.

Returns:

TextPosition

Implements: ITextBoxNavigator.GetNextPosition(TextPosition, bool)

Gets the next position.

C#
public virtual TextPosition GetNextPosition(TextPosition position)
Parameters:positionTextPosition

The position.

Returns:

TextPosition

Implements: ITextBoxNavigator.GetNextPosition(TextPosition)

Gets the next position recursively.

C#
protected virtual TextPosition GetNextPositionCore(TextPosition position)
Parameters:positionTextPosition

The position.

Returns:

TextPosition

Gets the position from offset.

C#
public virtual TextPosition GetPositionFromOffset(int offset)
Parameters:offsetint

The offset.

Returns:

TextPosition

Implements: ITextBoxNavigator.GetPositionFromOffset(int)

Gets the position from point.

C#
public virtual TextPosition GetPositionFromPoint(PointF point)
Parameters:pointPointF

The point.

Returns:

TextPosition

Implements: ITextBoxNavigator.GetPositionFromPoint(PointF)

Gets the previous position.

C#
public virtual TextPosition GetPreviousPosition(TextPosition position, bool isControlPressed)
Parameters:positionTextPosition

The position.

isControlPressedbool

True if Control modifier key is pressed.

Returns:

TextPosition

Implements: ITextBoxNavigator.GetPreviousPosition(TextPosition, bool)

Gets the previous position.

C#
public virtual TextPosition GetPreviousPosition(TextPosition position)
Parameters:positionTextPosition

The position.

Returns:

TextPosition

Implements: ITextBoxNavigator.GetPreviousPosition(TextPosition)

Gets the previous position resursively.

C#
protected virtual TextPosition GetPreviousPositionCore(TextPosition position)
Parameters:positionTextPosition

The position.

Returns:

TextPosition

Gets the text position from line.

C#
protected virtual TextPosition GetTextPositionFromLine(LineInfo line, float x)
Parameters:lineLineInfo

The line.

xfloat

The x.

Returns:

TextPosition

Navigates by specified keys.

C#
public virtual bool Navigate(KeyEventArgs keys)
Parameters:keysKeyEventArgs

The KeyEventArgs instance containing the event data.

Returns:

bool

Implements: ITextBoxNavigator.Navigate(KeyEventArgs)

Navigates at line.

C#
protected virtual TextPosition NavigateAtLine(KeyEventArgs keys, TextPosition position)
Parameters:keysKeyEventArgs

The KeyEventArgs instance containing the event data.

positionTextPosition

The position.

Returns:

TextPosition

Navigates to line.

C#
protected virtual TextPosition NavigateToLine(KeyEventArgs keys, TextPosition position)
Parameters:keysKeyEventArgs

The KeyEventArgs instance containing the event data.

positionTextPosition

The position.

Returns:

TextPosition

Raises the event.

C#
protected virtual void OnSelectionChanged(SelectionChangedEventArgs e)
Parameters:eSelectionChangedEventArgs

The SelectionChangedEventArgs instance containing the event data.

Raises the event.

C#
protected virtual void OnSelectionChanging(SelectionChangingEventArgs e)
Parameters:eSelectionChangingEventArgs

The SelectionChangingEventArgs instance containing the event data.

Restores the saved selection position.

C#
public virtual void RestoreSelection()

Implements: ITextBoxNavigator.RestoreSelection()

Resumes the notifications.

C#
public void ResumeNotifications()

Implements: ITextBoxNavigator.ResumeNotifications()

Saves the current selection position.

C#
public virtual void SaveSelection()

Implements: ITextBoxNavigator.SaveSelection()

Scrolls to caret position.

C#
public virtual bool ScrollToCaret()
Returns:

bool

Implements: ITextBoxNavigator.ScrollToCaret()

Selects the specified range.

C#
public virtual bool Select(TextPosition start, TextPosition end)
Parameters:startTextPosition

The start.

endTextPosition

The end.

Returns:

bool

Implements: ITextBoxNavigator.Select(TextPosition, TextPosition)

Selects the override.

C#
protected virtual void SelectOverride(bool notify)
Parameters:notifybool

if set to true [notify].

Sets the caret position.

C#
public virtual void SetCaretPosition()

Suspends the notifications.

C#
public void SuspendNotifications()

Implements: ITextBoxNavigator.SuspendNotifications()

Events

Occurs when selection is changed.

C#
public event SelectionChangedEventHandler SelectionChanged

Implements: ITextBoxNavigator.SelectionChanged

Occurs when selection is changing.

C#
public event SelectionChangingEventHandler SelectionChanging

Implements: ITextBoxNavigator.SelectionChanging