Quantcast
Channel: Ribbon for WPF - Recent Posts
Viewing all articles
Browse latest Browse all 1458

Ribbon Control Font Style

$
0
0

Hi,

I have created a style that targets the ribbon control.  In the style I set the font size and font family.  Here is an example of my style:

<Style x:Key="ribbonStyle2" TargetType="{x:Type ribbon:Ribbon}">
<Setter Property="FontFamily" Value="{DynamicResource DefaultFontFamily}" />
<Setter Property="FontSize" Value="14" />
<Setter Property="TextOptions.TextFormattingMode" Value="Display" />
</Style>

I set the style on my ribbon, like this:

<ribbon:Ribbon x:Name="ribbon" Style="{StaticResource ribbonStyle2}"

When I run the application the font style and size doesn't get applied.  If I set the properties directly on the ribbon control it works fine.

Here is an example:

<ribbon:Ribbon x:Name="Ribbon" Grid.Row="0" FontSize="14" FontFamily="{DynamicResource DefaultFontFamily}" TextOptions.TextFormattingMode="Display">

I really need to be able to use a style because I have many applications that are using the ribbon control and I want one style to rule them all :).  Please let me know how I can fix this.

Thanks,

Alyssa


Viewing all articles
Browse latest Browse all 1458

Trending Articles