Binding FontStyles and FontWeights to WPF ComboBox
- by Haemoglobin
I was just wondering if it would be possible to bind the list of available FontStyles and FontWeights to a ComboBox?
For example, to bind the list of fonts to a combobox you can use:
FontComboBox.ItemsSource = Fonts.SystemFontFamilies;
Can I also have something for :
FontStyleComboBox.ItemsSource = ....
FontWeightComboBox.ItemsSource = .... ?
Would it require reflection on the System.Windows.FontWeights and System.Windows.FontStyles classes or would there be an easier way than that?
Thanks