Provides a ruler control for RadRichTextEditor that displays horizontal and vertical measurement guides with paragraph formatting controls for precise document layout.
Definition
Namespace:Telerik.WinControls.UI
Assembly:Telerik.WinControls.RichTextEditor.dll
Syntax:
[TelerikToolboxCategory("RichTextEditor")]
[Docking(DockingBehavior.Ask)]
public class RadRichTextEditorRuler : RadControl, IDropTarget, ISynchronizeInvoke, IWin32Window, IBindableComponent, IComponent, IDisposable, INotifyPropertyChanged, ISupportInitializeNotification, ISupportInitialize, IComponentTreeHandler, ILayoutHandler, IAnalyticsProvider
Inheritance: objectMarshalByRefObjectComponentControlScrollableControlRadControlRadRichTextEditorRuler...
Implements:
Inherited Members
Constructors
Initializes a new instance of the RadRichTextEditorRuler class, creating a ruler control for precise document layout and paragraph formatting.
public RadRichTextEditorRuler()
Properties
Gets or sets the RadRichTextEditor control that this ruler is associated with, enabling synchronized measurement and formatting operations.
[Browsable(true)]
public RadRichTextEditor AssociatedRichTextBox { get; set; }
Gets the default size for the ruler control, providing reasonable initial dimensions for ruler display.
protected override Size DefaultSize { get; }
Overrides:
Gets the document ruler element that handles the visual representation and interaction logic for the ruler functionality.
[Browsable(false)]
public DocumentRulerElement DocumentRulerElement { get; }
Methods
Creates the input behavior for handling user interactions with the ruler, including drag operations for margins and indents.
protected override ComponentInputBehavior CreateBehavior()
A new RadRichTextEditorComponentInputBehavior instance for handling ruler interactions.
Overrides:
Creates and initializes the child elements of the ruler control, including the main DocumentRulerElement that provides ruler functionality.
protected override void CreateChildItems(RadElement parent)
The parent RadElement that will contain the ruler element.
Overrides:
Handles the control added event to automatically associate a RadRichTextEditor when it is added to the same container as this ruler.
protected override void OnControlAdded(ControlEventArgs e)
The control event arguments containing information about the added control.
Overrides:
Handles layout changes by positioning the associated RadRichTextEditor to account for ruler dimensions and ensuring proper alignment with ruler measurements.
protected override void OnLayout(LayoutEventArgs e)
The layout event arguments containing information about the layout change.
Overrides:
Handles mouse move events to update the cursor based on the element under the mouse pointer, providing visual feedback for interactive ruler elements.
protected override void OnMouseMove(MouseEventArgs e)
The mouse event arguments containing position and button information.
Overrides: