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

TextBlock style in RadDocking control not applied in runtime

1 Answer 31 Views
This is a migrated thread and some comments may be shown as answers.
Top achievements
Rank 1
T N asked on 08 Apr 2014, 09:10 AM
Hi all,
I currently have a problem with applying Style for TextBlock when TextBlock is in RadDocking control. I have a simple example below.

- The app will use Windows8Theme

public App()
    StyleManager.ApplicationTheme = new Windows8Theme();

The TextBlock is set with FontWeight Bold.

<telerik:RadDocking Grid.Row="1" HasDocumentHost="False">
    <telerik:RadSplitContainer Orientation="Horizontal">
        <telerik:RadPaneGroup telerik:ProportionalStackPanel.RelativeSize="200, 200">
            <telerik:RadPane PaneHeaderVisibility="Collapsed">
                    <TextBlock FontWeight="Bold" Margin="50" Foreground="Green" Text="HIHI" />

In the designer it was correctly displayed

But in runtime it was not

I think that setting ApplicationTheme in App() has overwritten the Style of TextBlock.

Question: What should I do to keep FontWeight of TextBlock from overwriting by StyleManager?

1 Answer, 1 is accepted

Sort by
Telerik team
answered on 09 Apr 2014, 02:10 PM

In order to support dynamic FontSizes in the Telerik Windows8Theme there is a built-in Style in that theme that Targets every TextBlock and set specific values to its Style properties. In this case the issue is that the default FontFamily is set to Segoe UI Semibold which itself doesn't have an Bold style, meaning that when setting the FontWeight to Bold the style is correctly set but there is no visual representation for it.

In order to resolve this issue all you will need to set a different FontFamily from the default Segoe UI Semibold one, for example Segoe UI.


Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

Asked by
Top achievements
Rank 1
Answers by
Telerik team
Share this question