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

Font Size on RadRichTextBoxRibbonUI not synced with RadRichTextBox

3 Answers 125 Views
RichTextBox
This is a migrated thread and some comments may be shown as answers.
Tim
Top achievements
Rank 1
Tim asked on 16 Jul 2020, 06:15 AM

Using latest version of UI for WPF R2 2020 SP.

I have a RadRichTextBox and RadRichTextBoxRibbonUI on a user control.

All of the buttons on the ribbon view are synced with the selected text on the rich text box, other than font size. Note that if I highlight text and select a new font size, it works as expected, except that the newly selected size is not displayed in the ribbon view (the combobox is empty after the selection).

Snippet of code attached to show that the Command binding is set correctly, or so I believe.

Any help greatly appreciated.

 

<telerik:RadRichTextBoxRibbonUI CollapseThresholdSize="50,50" VerticalAlignment="Top" DataContext="{Binding Commands, ElementName=radRichTextBox}" ApplicationButtonContent="File">

     .....

</telerik:RadRichTextBoxRibbonUI>

<telerik:DocumentRuler Grid.Row="1">
    <telerik:RadRichTextBox Name="radRichTextBox" LayoutMode="Paged" />
</telerik:DocumentRuler>
<telerik:RadRichTextBoxStatusBar Grid.Row="2"  AssociatedRichTextBox="{Binding ElementName=radRichTextBox, Mode=OneTime}" />

3 Answers, 1 is accepted

Sort by
0
Accepted
Tanya
Telerik team
answered on 16 Jul 2020, 08:43 AM

Hi Andrew,

I have tested the behavior of the font size combo box in our Telerik Editor example and it seems to work as expected. Is your setup different? Are there any specific steps to reproduce this behavior?

Regards,
Tanya
Progress Telerik

0
Tim
Top achievements
Rank 1
answered on 17 Jul 2020, 01:19 AM

Hi Tanya,

Thanks for the quick reply. I downloaded the source for the Editor example and found considerable differences between the RadRichTextBoxRibbonUI code and what was generated when I followed the instructions in the doco and had the code generated by dropping a RadRichTextBoxRibbonUI control from the toolbox onto the designer in visual studio.

After taking the code from the Editor and using it in my application, everything is working, so perhaps someone might want to look at the code that is being autogenerated following the procedure in the documentation?

Thanks again for your help.

Cheers,

Andrew.

0
Tanya
Telerik team
answered on 20 Jul 2020, 10:55 AM

Hello Andrew,

I am glad to hear that everything is now set up and working on your side.

I have checked the XAML generation and the XAML from the example. The differences I am encountering are mostly related to the formatting of the code. Can you please share the result you are getting so I can check what is missing there and try to find what might be causing a difference?

Regards,
Tanya
Progress Telerik

Tags
RichTextBox
Asked by
Tim
Top achievements
Rank 1
Answers by
Tanya
Telerik team
Tim
Top achievements
Rank 1
Share this question
or