This question is locked. New answers and comments are not allowed.
If I specify a FontWeight="ExtraBold", the font is displayed as "Normal" in both RadGrid and RadCalendar, yet in a simple TextBox, the weight is applied as I expect. FontFamily and FontStyle work fine...but not FontWeight. I'm using Silverlight controls version 422, VS2010, and Silverlight 4.
Here's my code-behind:
And associated class:
See attached file for the output. Why doesn't FontWeight work with the Rad controls?
| <UserControl |
| xmlns:input="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Input" |
| xmlns:grid="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.GridView" |
| xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" |
| xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
| xmlns:d="http://schemas.microsoft.com/expression/blend/2008" |
| xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" |
| mc:Ignorable="d" |
| d:DesignHeight="300" d:DesignWidth="400" x:Class="FontWeight.MainPage" > |
| <Grid x:Name="LayoutRoot" Background="White"> |
| <Grid.RowDefinitions> |
| <RowDefinition Height="Auto" ></RowDefinition> |
| <RowDefinition Height="Auto" ></RowDefinition> |
| <RowDefinition Height="Auto" ></RowDefinition> |
| <RowDefinition Height="Auto" ></RowDefinition> |
| <RowDefinition Height="Auto" ></RowDefinition> |
| </Grid.RowDefinitions> |
| <grid:RadGridView Grid.Row="0" x:Name="dgMain" FontFamily="Verdana" FontWeight="ExtraBold" FontStyle="Italic" /> |
| <input:RadCalendar Grid.Row="1" x:Name="rCalendar" FontFamily="Verdana" FontWeight="Normal" FontStyle="Normal" /> |
| <TextBox Grid.Row="2" FontFamily="Verdana" FontWeight="ExtraBold" FontStyle="Italic" Text="Hello World" /> |
| <TextBox Grid.Row="3" FontFamily="Verdana" FontWeight="Normal" FontStyle="Normal" Text="Hello World" /> |
| </Grid> |
| </UserControl> |
| public MainPage() |
| { |
| InitializeComponent(); |
| LoadGrid(); |
| } |
| private void LoadGrid() |
| { |
| List<Class1> rows = new List<Class1>(); |
| Class1 row = new Class1(); |
| row.description = "Hello World"; |
| rows.Add(row); |
| dgMain.ItemsSource = rows; |
| } |
| namespace FontWeight |
| { |
| public class Class1 |
| { |
| public string description { get; set; } |
| } |
| } |