Class RadSyntaxEditor
Inherited Members
Namespace: Telerik.WinControls.UI
Assembly: Telerik.WinControls.SyntaxEditor.dll
Syntax
[TelerikToolboxCategory("Editors")]
public class RadSyntaxEditor : RadControl, INotifyPropertyChanged, ISupportInitializeNotification, ISupportInitialize, IComponentTreeHandler, ILayoutHandler, IPCHost, IAnalyticsProvider
Constructors
RadSyntaxEditor()
Declaration
public RadSyntaxEditor()
Properties
AllowScaling
Gets or sets a value indicating whether [allow scaling].
Declaration
public bool AllowScaling { get; set; }
Property Value
System.Boolean
|
AutoSize
RadSyntaxEditor does not support AutoSize True this property always returns False.
Declaration
public override bool AutoSize { get; set; }
Property Value
System.Boolean
|
Overrides
CaretColor
Gets or sets the caret color.
Declaration
public Color CaretColor { get; set; }
Property Value
System.Drawing.Color
The caret color. |
CaretDisplayMode
Gets or sets the caret display mode.
Declaration
public CaretDisplayMode CaretDisplayMode { get; set; }
Property Value
CaretDisplayMode
The caret display mode. |
CaretWidth
Gets or sets the caret width when the DisplayMode is set to Normal.
Declaration
public double CaretWidth { get; set; }
Property Value
System.Double
The caret width. |
Commands
Gets the commands available in the control.
Declaration
public SyntaxEditorCommands Commands { get; }
Property Value
SyntaxEditorCommands
The commands. |
DefaultSize
Gets the default size when the control is dragged onto the designer surface.
Declaration
protected override Size DefaultSize { get; }
Property Value
System.Drawing.Size
|
Dispatcher
Gets the dispatcher objcect.
Declaration
public Dispatcher Dispatcher { get; }
Property Value
Dispatcher
The dispatcher. |
Document
Gets or sets the text document.
Declaration
public TextDocument Document { get; set; }
Property Value
TextDocument
The document. |
EditorFontSize
Gets or sets a value indicating the font size of the text editor.
Declaration
public double EditorFontSize { get; set; }
Property Value
System.Double
|
InputHandler
Gets or sets the component which is responsible for handling the input of RadSyntexEditor.
Declaration
public SyntaxEditorInputBehavior InputHandler { get; set; }
Property Value
SyntaxEditorInputBehavior
|
IsCaretVisible
Gets or sets a value indicating whether this instance is caret visible.
Declaration
public bool IsCaretVisible { get; set; }
Property Value
System.Boolean
|
IsSelectionEnabled
Gets or sets a value indicating whether this instance is selection enabled.
Declaration
public bool IsSelectionEnabled { get; set; }
Property Value
System.Boolean
|
IsWordWrapEnabled
Declaration
public bool IsWordWrapEnabled { get; set; }
Property Value
System.Boolean
|
Palette
Gets or sets the palette of syntax elements' colors used for this RadSyntaxEditorElement instance.
Declaration
public SyntaxEditorPalette Palette { get; set; }
Property Value
SyntaxEditorPalette
|
ScaleFactor
Gets or sets the scale factor.
Declaration
public double ScaleFactor { get; set; }
Property Value
System.Double
The scale factor. |
ShouldTaggersProcessEntireLines
Gets or sets a value whether the entire line should be processed by the taggers.
Declaration
public bool ShouldTaggersProcessEntireLines { get; set; }
Property Value
System.Boolean
|
ShowLineNumbers
Gets or sets a value indicating whether the line numbers are shown.
Declaration
public bool ShowLineNumbers { get; set; }
Property Value
System.Boolean
|
SyntaxEditorElement
Gets the RadSyntaxEditorElement which is the main element in the control.
Declaration
public RadSyntaxEditorElement SyntaxEditorElement { get; }
Property Value
RadSyntaxEditorElement
|
TaggersRegistry
Gets the taggers registry.
Declaration
public TaggersRegistry TaggersRegistry { get; }
Property Value
TaggersRegistry
The taggers registry. |
TextFormatDefinitions
Gets the text format definitions.
Declaration
public TextFormatDefinitionStack TextFormatDefinitions { get; }
Property Value
TextFormatDefinitionStack
The text format definitions. |
UseShiftKeyInSelection
Gets or sets a value indicating whether [use shift key in selection].
Declaration
public bool UseShiftKeyInSelection { get; set; }
Property Value
System.Boolean
|
Methods
Copy()
Copies this instance.
Declaration
public void Copy()
CreateAccessibilityInstance()
Declaration
protected override AccessibleObject CreateAccessibilityInstance()
Returns
System.Windows.Forms.AccessibleObject
|
CreateBehavior()
Declaration
protected override ComponentInputBehavior CreateBehavior()
Returns
ComponentInputBehavior
|
Overrides
CreateChildItems(RadElement)
Declaration
protected override void CreateChildItems(RadElement parent)
Parameters
RadElement
parent
|
Overrides
GetPointFromPosition(CaretPosition)
Gets the point from position.
Declaration
public Point GetPointFromPosition(CaretPosition position)
Parameters
CaretPosition
position
The position. |
Returns
Point
Point. |
GetPositionFromControlPoint(Point)
Gets the position from point which is relative to the control.
Declaration
public CaretPosition GetPositionFromControlPoint(Point point)
Parameters
System.Drawing.Point
point
The point relative to the control. |
Returns
CaretPosition
CaretPosition. |
GetPositionFromPoint(Point)
Gets the position from point. To get the correct caret position expects the point to be relative to the editor presenter and adjusted with the scale factor and scroll offsets. Use the GetPositionFromControlPoint method instead, which internally makes the necessary adjustments considering the scale factor and offsets, assuming the point is in control coordinates.
Declaration
public CaretPosition GetPositionFromPoint(Point point)
Parameters
System.Drawing.Point
point
The point. |
Returns
CaretPosition
CaretPosition. |
IsInputKey(Keys)
Declaration
protected override bool IsInputKey(Keys keyData)
Parameters
System.Windows.Forms.Keys
keyData
|
Returns
System.Boolean
|
Overrides
MoveCurrentLineToTop()
Moves the current line to top.
Declaration
public void MoveCurrentLineToTop()
OnGotFocus(EventArgs)
Declaration
protected override void OnGotFocus(EventArgs e)
Parameters
System.EventArgs
e
|
Overrides
OnKeyDown(KeyEventArgs)
Declaration
protected override void OnKeyDown(KeyEventArgs e)
Parameters
System.Windows.Forms.KeyEventArgs
e
|
Overrides
OnKeyPress(KeyPressEventArgs)
Declaration
protected override void OnKeyPress(KeyPressEventArgs e)
Parameters
System.Windows.Forms.KeyPressEventArgs
e
|
Overrides
OnKeyUp(KeyEventArgs)
Declaration
protected override void OnKeyUp(KeyEventArgs e)
Parameters
System.Windows.Forms.KeyEventArgs
e
|
Overrides
OnLoad(Size)
Declaration
protected override void OnLoad(Size desiredSize)
Parameters
System.Drawing.Size
desiredSize
|
Overrides
OnLostFocus(EventArgs)
Declaration
protected override void OnLostFocus(EventArgs e)
Parameters
System.EventArgs
e
|
Overrides
OnThemeChanged()
PageDown()
Pages down.
Declaration
public void PageDown()
PageUp()
Pages up.
Declaration
public void PageUp()
ProcessDialogChar(Char)
Declaration
protected override bool ProcessDialogChar(char charCode)
Parameters
System.Char
charCode
|
Returns
System.Boolean
|
ProcessMnemonic(Char)
Declaration
protected override bool ProcessMnemonic(char charCode)
Parameters
System.Char
charCode
|
Returns
System.Boolean
|
Overrides
ScaleControl(SizeF, BoundsSpecified)
Declaration
protected override void ScaleControl(SizeF factor, BoundsSpecified specified)
Parameters
System.Drawing.SizeF
factor
|
System.Windows.Forms.BoundsSpecified
specified
|
Overrides
SelectAll()
Selects all.
Declaration
public void SelectAll()
UpdateSelection()
Updates the selection.
Declaration
public void UpdateSelection()
ZoomIn()
Zooms in.
Declaration
public void ZoomIn()
ZoomOut()
Zooms out.
Declaration
public void ZoomOut()
ZoomTo(Double)
Zooms to particular zoom level. The minimum supported zoom level is 0.2 and the maximum supported is 4.
Declaration
public void ZoomTo(double zoomLevel)
Parameters
System.Double
zoomLevel
The scale factor which will be used for zooming. |
Exceptions
System.ArgumentOutOfRangeException
ZoomLevel must be non negative. |
Events
CommandError
Occurs when [command error].
Declaration
public event EventHandler<CommandErrorEventArgs> CommandError
Event Type
System.EventHandler<CommandErrorEventArgs>
|
CommandExecuted
Occurs when [command executed].
Declaration
public event EventHandler<CommandExecutedEventArgs> CommandExecuted
Event Type
System.EventHandler<CommandExecutedEventArgs>
|
CommandExecuting
Occurs when [command executing].
Declaration
public event EventHandler<CommandExecutingEventArgs> CommandExecuting
Event Type
System.EventHandler<CommandExecutingEventArgs>
|
DocumentChanged
Occurs when document has been changed.
Declaration
public event EventHandler DocumentChanged
Event Type
System.EventHandler
|
DocumentChanging
Occurs when document is being changed.
Declaration
public event EventHandler DocumentChanging
Event Type
System.EventHandler
|
DocumentContentChanged
Occurs when document content has been changed.
Declaration
public event EventHandler<TextContentChangedEventArgs> DocumentContentChanged
Event Type
System.EventHandler<TextContentChangedEventArgs>
|
DocumentContentChanging
Occurs when document content is being changed.
Declaration
public event EventHandler<TextContentChangingEventArgs> DocumentContentChanging
Event Type
System.EventHandler<TextContentChangingEventArgs>
|
IsReadOnlyChanged
Occurs when [is read only changed].
Declaration
public event EventHandler IsReadOnlyChanged
Event Type
System.EventHandler
|
LayoutPropertiesChanged
Occurs when [layout properties changed].
Declaration
public event EventHandler LayoutPropertiesChanged
Event Type
System.EventHandler
|
PreviewSyntaxEditorInput
Occurs when [preview code editor input].
Declaration
public event EventHandler<PreviewSyntaxEditorInputEventArgs> PreviewSyntaxEditorInput
Event Type
System.EventHandler<PreviewSyntaxEditorInputEventArgs>
|
PreviewSyntaxEditorKeyDown
Occurs when [preview code editor key down].
Declaration
public event EventHandler<PreviewSyntaxEditorKeyEventArgs> PreviewSyntaxEditorKeyDown
Event Type
System.EventHandler<PreviewSyntaxEditorKeyEventArgs>
|
PreviewSyntaxEditorKeyUp
Occurs when [preview code editor key up].
Declaration
public event EventHandler<PreviewSyntaxEditorKeyEventArgs> PreviewSyntaxEditorKeyUp
Event Type
System.EventHandler<PreviewSyntaxEditorKeyEventArgs>
|
PreviewSyntaxEditorMouseLeftButtonDown
Occurs when [preview code editor mouse left button down].
Declaration
public event EventHandler<PreviewSyntaxEditorMouseButtonEventArgs> PreviewSyntaxEditorMouseLeftButtonDown
Event Type
System.EventHandler<PreviewSyntaxEditorMouseButtonEventArgs>
|
PreviewSyntaxEditorMouseRightButtonDown
Occurs when [preview code editor mouse right button down].
Declaration
public event EventHandler<PreviewSyntaxEditorMouseButtonEventArgs> PreviewSyntaxEditorMouseRightButtonDown
Event Type
System.EventHandler<PreviewSyntaxEditorMouseButtonEventArgs>
|
ScaleFactorChanged
Occurs when [scale factor changed].
Declaration
public event EventHandler ScaleFactorChanged
Event Type
System.EventHandler
|
SelectionChanged
Occurs when the selection of the control changes.
Declaration
public event EventHandler SelectionChanged
Event Type
System.EventHandler
|
ViewportChanged
Occurs when [viewport changed].
Declaration
public event EventHandler ViewportChanged
Event Type
System.EventHandler
|