This is a migrated thread and some comments may be shown as answers.

Font changes unexpectedly when clicking into an empty editor

1 Answer 58 Views
RichTextBox
This is a migrated thread and some comments may be shown as answers.
Will
Top achievements
Rank 1
Will asked on 21 Aug 2012, 07:38 PM
I have a small window with an RRTB and its associated RadRichTextBoxRibbonUI.  

The RRTB has initial focus, and the caret is blinking at the top left.

If the user changes the font from the default, say from Verdana to Times New Roman, then clicks anywhere within the RRTB as if they were bringing focus back to it, the font changes back to the default (Verdana in this example).

Attached is an image with three stills taken 1) on load 2) after font change and 3) after click.

Is this expected behavior, or a bug?  Are there any workarounds for it?

1 Answer, 1 is accepted

Sort by
0
Accepted
Todor
Telerik team
answered on 24 Aug 2012, 05:52 PM
Hi Will,

This is the behavior by design. When you click on a button or a combo box in the UI, the change specified is applied to the current editing style. All commands focus the editor right after they change the specific property of the current editing style, so that it is not necessary to click on the document again to get the focus. If you start typing right away, the text will be bold/italic/with the new fore color, etc.

However, the UI also tracks the position of the caret in the editor in order to reset the values it shows when the caret position changes. That is why when you click in the editor, the combo boxes take the values of the current editing style at the place in the document where the caret is in and update their values.

We will consider changing the behavior so that if the new position is the same as the old one, the values of the current style will not be reset. However, this change is far from trivial and is not currently scheduled.

Please, contact us again if you encounter any other issues with our products.

Kind regards,
Todor
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Tags
RichTextBox
Asked by
Will
Top achievements
Rank 1
Answers by
Todor
Telerik team
Share this question
or