TextBlock style in RadDocking control not applied in runtime

2 posts, 0 answers
  1. T N
    T N avatar
    3 posts
    Member since:
    Jul 2013

    Posted 08 Apr 2014 Link to this post

    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?

  2. Vladi
    Vladi avatar
    743 posts

    Posted 09 Apr 2014 Link to this post


    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.

  3. DevCraft banner
Back to Top