Hi Vitalij,
Placing the caret next to a read-only range actually places it just before or after it but still outside of it. That is why the users can edit at the start and at the end of the document. You can bypass that behavior by canceling the commands when the caret is at these specific positions. To implement this, you will need to attach to the CommandExecuting event of RadRichTextBox and execute the following code inside its handler:
private void RadRichTextBox_CommandExecuting(object sender, Telerik.Windows.Documents.RichTextBoxCommands.CommandExecutingEventArgs e)
{
if (this.radRichTextBox.Document.CaretPosition.IsPositionAtDocumentStart || this.radRichTextBox.Document.CaretPosition.IsPositionAtDocumentEnd)
{
e.Cancel = true;
}
}
Hope this is helpful.
Regards,
Tanya
Progress Telerik