WPF

Upgrade Guide User Guide Demos Support Forums Download
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class FontListComboBox - WPF API Reference | Syncfusion

    Show / Hide Table of Contents

    Class FontListComboBox

    Represents combo box that contains the list of fonts.

    Inheritance
    System.Object
    FontListBase
    FontListComboBox
    Inherited Members
    FontListBase.OnAllFontsChanged(DependencyPropertyChangedEventArgs)
    FontListBase.CoerceAllFontsProperty(DependencyObject, Object)
    FontListBase.AllFontsChanged
    Namespace: Syncfusion.Windows.Tools.Controls
    Assembly: Syncfusion.Tools.Wpf.dll
    Syntax
    [SkinType(SkinVisualStyle = Skin.Default, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF;component/Controls/FontComboBox/Themes/Generic.xaml")]
    [SkinType(SkinVisualStyle = Skin.Office2003, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF.Classic;component/Controls/FontComboBox/Themes/Office2003Style.xaml")]
    [SkinType(SkinVisualStyle = Skin.Blend, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF.Classic;component/Controls/FontComboBox/Themes/BlendStyle.xaml")]
    [SkinType(SkinVisualStyle = Skin.Office2010Silver, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF.Classic;component/Controls/FontComboBox/Themes/Office2010SilverStyle.xaml")]
    [SkinType(SkinVisualStyle = Skin.Office2007Blue, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF.Classic;component/Controls/FontComboBox/Themes/Office2007BlueStyle.xaml")]
    [SkinType(SkinVisualStyle = Skin.Office2007Black, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF.Classic;component/Controls/FontComboBox/Themes/Office2007BlackStyle.xaml")]
    [SkinType(SkinVisualStyle = Skin.Office2007Silver, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF.Classic;component/Controls/FontComboBox/Themes/Office2007SilverStyle.xaml")]
    [SkinType(SkinVisualStyle = Skin.ShinyRed, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF.Classic;component/Controls/FontComboBox/Themes/ShinyRedStyle.xaml")]
    [SkinType(SkinVisualStyle = Skin.Office2010Blue, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF.Classic;component/Controls/FontComboBox/Themes/Office2010BlueStyle.xaml")]
    [SkinType(SkinVisualStyle = Skin.Office2010Black, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF.Classic;component/Controls/FontComboBox/Themes/Office2010BlackStyle.xaml")]
    [SkinType(SkinVisualStyle = Skin.Transparent, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF.Classic;component/Controls/FontComboBox/Themes/TransparentStyle.xaml")]
    [SkinType(SkinVisualStyle = Skin.SyncOrange, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF.Classic;component/Controls/FontComboBox/Themes/SyncOrangeStyle.xaml")]
    [SkinType(SkinVisualStyle = Skin.ShinyBlue, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF.Classic;component/Controls/FontComboBox/Themes/ShinyBlueStyle.xaml")]
    [SkinType(SkinVisualStyle = Skin.VS2010, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF.Classic;component/Controls/FontComboBox/Themes/VS2010Style.xaml")]
    [SkinType(SkinVisualStyle = Skin.Metro, Type = typeof(FontListComboBox), XamlResource = "/Syncfusion.Tools.WPF.Classic;component/Controls/FontComboBox/Themes/MetroStyle.xaml")]
    public class FontListComboBox : FontListBase

    Constructors

    FontListComboBox()

    Initializes a new instance of the FontListComboBox class.

    Declaration
    public FontListComboBox()

    Fields

    DisplayFontNamesInSystemFontProperty

    Identifies the DisplayFontNamesInSystemFont dependency property.

    Declaration
    public static readonly DependencyProperty DisplayFontNamesInSystemFontProperty
    Field Value
    Type Description
    System.Windows.DependencyProperty

    FocusedFontFamilyProperty

    Identifies the FocusedFontFamily dependency property.

    Declaration
    public static readonly DependencyProperty FocusedFontFamilyProperty
    Field Value
    Type Description
    System.Windows.DependencyProperty

    FontsSourceProperty

    Identifies the FontsSource dependency property.

    Declaration
    public static readonly DependencyProperty FontsSourceProperty
    Field Value
    Type Description
    System.Windows.DependencyProperty

    GroupHeaderStyleProperty

    Identifies the GroupHeaderStyle dependency property.

    Declaration
    public static readonly DependencyProperty GroupHeaderStyleProperty
    Field Value
    Type Description
    System.Windows.DependencyProperty

    IsDropDownOpenProperty

    Identifies the IsDropDownOpen dependency property.

    Declaration
    public static readonly DependencyProperty IsDropDownOpenProperty
    Field Value
    Type Description
    System.Windows.DependencyProperty

    ItemContainerStyleProperty

    Identifies the ItemContainerStyle dependency property.

    Declaration
    public static readonly DependencyProperty ItemContainerStyleProperty
    Field Value
    Type Description
    System.Windows.DependencyProperty

    ItemsForegroundProperty

    Identifies the ItemsForeground dependency property.

    Declaration
    public static readonly DependencyProperty ItemsForegroundProperty
    Field Value
    Type Description
    System.Windows.DependencyProperty

    ItemTemplateProperty

    Identifies the ItemTemplate dependency property.

    Declaration
    public static readonly DependencyProperty ItemTemplateProperty
    Field Value
    Type Description
    System.Windows.DependencyProperty

    M_openPopup

    Command that opens popup with FintListBox control.

    Declaration
    public static RoutedCommand M_openPopup
    Field Value
    Type Description
    System.Windows.Input.RoutedCommand

    PopupDropDownHeightProperty

    Identifies the PopupDropDownHeight dependency property.

    Declaration
    public static readonly DependencyProperty PopupDropDownHeightProperty
    Field Value
    Type Description
    System.Windows.DependencyProperty

    RecentlyUsedFontsProperty

    Identifies the RecentlyUsedFonts dependency property.

    Declaration
    public static readonly DependencyProperty RecentlyUsedFontsProperty
    Field Value
    Type Description
    System.Windows.DependencyProperty

    SelectedFontFamilyProperty

    Identifies the SelectedFontFamily dependency property.

    Declaration
    public static readonly DependencyProperty SelectedFontFamilyProperty
    Field Value
    Type Description
    System.Windows.DependencyProperty

    ThemeFontsProperty

    Identifies the ThemeFonts dependency property.

    Declaration
    public static readonly DependencyProperty ThemeFontsProperty
    Field Value
    Type Description
    System.Windows.DependencyProperty

    Properties

    DisplayFontNamesInSystemFont

    Gets or sets a value indicating whether fonts should be displayed in system font. This is a dependency property.

    Declaration
    public bool DisplayFontNamesInSystemFont { get; set; }
    Property Value
    Type Description
    System.Boolean

    Type: System.Boolean Default value is false.

    See Also
    System.Boolean

    FocusedFontFamily

    Gets or sets the focused font family. This is a dependency property.

    Declaration
    public FontFamily FocusedFontFamily { get; set; }
    Property Value
    Type Description
    System.Windows.Media.FontFamily

    Type: System.Windows.Media.FontFamily

    Remarks

    Focused font family is displayed in text box of FontListComboBox control.

    See Also
    System.Windows.Media.FontFamily

    FontsSource

    Gets or sets the source for the font collection. This is a dependency property.

    Declaration
    public object FontsSource { get; set; }
    Property Value
    Type Description
    System.Object

    Type: System.Object Default value is "System".

    Examples

    FontListComboBox fontListComboBox1 = new FontListComboBox(); this.panel1.Children.Add(fontListComboBox1); FontCollection collection = new FontCollection(); collection.Add(new FontFamily("Tahoma")); collection.Add(new FontFamily("Century")); collection.Add(new FontFamily("Arial")); fontListComboBox1.FontsSource = collection;

    See Also
    System.Object

    GroupHeaderStyle

    Gets or sets the style of the group header. This is a dependency property.

    Declaration
    public Style GroupHeaderStyle { get; set; }
    Property Value
    Type Description
    System.Windows.Style

    Type: System.Windows.Style

    See Also
    System.Windows.Style

    IsDropDownOpen

    Gets or sets a value indicating whether dropDown is shown. This is a dependency property.

    Declaration
    public bool IsDropDownOpen { get; set; }
    Property Value
    Type Description
    System.Boolean

    Type: System.Boolean Default value is false.

    See Also
    System.Boolean

    ItemContainerStyle

    Gets or sets the style of the item container. This is a dependency property.

    Declaration
    public Style ItemContainerStyle { get; set; }
    Property Value
    Type Description
    System.Windows.Style

    Type: System.Windows.Style

    See Also
    System.Windows.Style

    ItemsForeground

    Gets or sets pop-up's items foreground. This is a dependency property.

    Declaration
    public Brush ItemsForeground { get; set; }
    Property Value
    Type Description
    System.Windows.Media.Brush

    Type: System.Windows.Media.Brush

    See Also
    System.Windows.Media.Brush

    ItemTemplate

    Gets or sets the template of the item. This is a dependency property.

    Declaration
    public DataTemplate ItemTemplate { get; set; }
    Property Value
    Type Description
    System.Windows.DataTemplate

    Type: System.Windows.DataTemplate

    See Also
    System.Windows.DataTemplate

    PopupDropDownHeight

    Gets or sets pop-up's height. Default value is Double.NaN. This is a dependency property.

    Declaration
    public double PopupDropDownHeight { get; set; }
    Property Value
    Type Description
    System.Double

    Type: System.Double

    Remarks

    When the NaN value is assigned, the auto-sizing behavior is enabled. When the negative value is assigned, it is treated as NaN and, therefore, the auto-sizing behavior is enabled.

    RecentlyUsedFonts

    Gets or sets the collection of recently used fonts. This is a dependency property.

    Declaration
    public FontCollection RecentlyUsedFonts { get; set; }
    Property Value
    Type Description
    FontCollection

    Type: FontCollection

    Examples

    FontListComboBox fontListComboBox1 = new FontListComboBox(); this.panel1.Children.Add(fontListComboBox1); FontFamily font = new FontFamily( "Century" ); fontListComboBox1.RecentlyUsedFonts.Add(font);

    See Also
    FontCollection

    SelectedFontFamily

    Gets or sets the selected font family. This is a dependency property.

    Declaration
    public FontFamily SelectedFontFamily { get; set; }
    Property Value
    Type Description
    System.Windows.Media.FontFamily

    Type: System.Windows.Media.FontFamily

    Remarks

    Selected font family is displayed in text box of FontListComboBox control.

    See Also
    System.Windows.Media.FontFamily

    ThemeFonts

    Gets or sets the collection of theme fonts. This is a dependency property.

    Declaration
    public ThemeFontFamilyCollection ThemeFonts { get; set; }
    Property Value
    Type Description
    ThemeFontFamilyCollection

    Type: ThemeFontFamilyCollection

    Examples

    FontListComboBox fontListComboBox1 = new FontListComboBox(); this.panel1.Children.Add(fontListComboBox1); ThemeFontFamily font = new ThemeFontFamily("Century", "body"); fontListComboBox1.ThemeFonts.Add(font);

    See Also
    ThemeFontFamilyCollection

    Methods

    CoercePopupDropDownHeight(DependencyObject, Object)

    Fulfils the logic before setting the PopupDropDownHeight value.

    Declaration
    public static object CoercePopupDropDownHeight(DependencyObject d, object baseValue)
    Parameters
    Type Name Description
    System.Windows.DependencyObject d

    FontListComboBox instance to which this property belongs.

    System.Object baseValue

    Value that should be set.

    Returns
    Type Description
    System.Object

    Coerced Value

    CoerceRecentlyUsedFontsProperty(DependencyObject, Object)

    Fulfils the logic before setting the RecentlyUsedFonts value.

    Declaration
    public static object CoerceRecentlyUsedFontsProperty(DependencyObject d, object baseValue)
    Parameters
    Type Name Description
    System.Windows.DependencyObject d

    FontListComboBox instance to which this property belongs.

    System.Object baseValue

    BaseValue that should be set.

    Returns
    Type Description
    System.Object

    Value that should be set.

    CoerceThemeFontsProperty(DependencyObject, Object)

    Fulfils the logic before setting the ThemeFonts value.

    Declaration
    public static object CoerceThemeFontsProperty(DependencyObject d, object baseValue)
    Parameters
    Type Name Description
    System.Windows.DependencyObject d

    FontListComboBox instance to which this property belongs.

    System.Object baseValue

    BaseValue that should be set.

    Returns
    Type Description
    System.Object

    Value that should be set.

    OnDisplayFontNamesInSystemFontChanged(DependencyPropertyChangedEventArgs)

    Updates property value cache and raises DisplayFontNamesInSystemFontChanged event.

    Declaration
    protected virtual void OnDisplayFontNamesInSystemFontChanged(DependencyPropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Windows.DependencyPropertyChangedEventArgs e

    Property change details, such as old value and new value.

    OnFocusedFontFamilyChanged(DependencyPropertyChangedEventArgs)

    Updates property value cache and raises FocusedFontFamilyChanged event.

    Declaration
    protected virtual void OnFocusedFontFamilyChanged(DependencyPropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Windows.DependencyPropertyChangedEventArgs e

    Property changes details, such as old value and new value.

    OnFontsSourceChanged(DependencyPropertyChangedEventArgs)

    Updates property value cache and raises FontsSourceChanged event.

    Declaration
    protected virtual void OnFontsSourceChanged(DependencyPropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Windows.DependencyPropertyChangedEventArgs e

    Property changes details, such as old value and new value.

    OnGroupHeaderStyleChanged(DependencyPropertyChangedEventArgs)

    Updates property value cache and raises GroupHeaderStyleChanged event.

    Declaration
    protected virtual void OnGroupHeaderStyleChanged(DependencyPropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Windows.DependencyPropertyChangedEventArgs e

    Property changes details, such as old value and new value.

    OnInitialized(EventArgs)

    Raises the System.Windows.FrameworkElement.Initialized event. This method is invoked whenever System.Windows.FrameworkElement.IsInitialized is set to true internally.

    Declaration
    protected override void OnInitialized(EventArgs e)
    Parameters
    Type Name Description
    System.EventArgs e

    The System.Windows.RoutedEventArgs that contains the event data.

    OnIsDropDownOpenChanged(DependencyPropertyChangedEventArgs)

    Updates property value cache and raises IsDropDownOpenChanged event.

    Declaration
    protected virtual void OnIsDropDownOpenChanged(DependencyPropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Windows.DependencyPropertyChangedEventArgs e

    Property change details, such as old value and new value.

    OnItemContainerStyleChanged(DependencyPropertyChangedEventArgs)

    Updates property value cache and raises ItemContainerStyleChanged event.

    Declaration
    protected virtual void OnItemContainerStyleChanged(DependencyPropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Windows.DependencyPropertyChangedEventArgs e

    Property changes details, such as old value and new value.

    OnItemTemplateChanged(DependencyPropertyChangedEventArgs)

    Updates property value cache and raises ItemTemplateChanged event.

    Declaration
    protected virtual void OnItemTemplateChanged(DependencyPropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Windows.DependencyPropertyChangedEventArgs e

    Property changes details, such as old value and new value.

    OnLostMouseCapture(MouseEventArgs)

    Invoked when an System.Windows.Input.Mouse.LostMouseCapture attached event reaches an element.

    Declaration
    protected override void OnLostMouseCapture(MouseEventArgs e)
    Parameters
    Type Name Description
    System.Windows.Input.MouseEventArgs e

    The System.Windows.Input.MouseEventArgs that contains event data.

    OnMouseDown(MouseButtonEventArgs)

    Invoked when an System.Windows.Input.Mouse.MouseDown attached event reaches an element.

    Declaration
    protected override void OnMouseDown(MouseButtonEventArgs e)
    Parameters
    Type Name Description
    System.Windows.Input.MouseButtonEventArgs e

    The System.Windows.Input.MouseButtonEventArgs that contains the event data.

    OnMouseWheel(MouseWheelEventArgs)

    Invoked when the mouse wheel rotates over the FontComboBox.

    Declaration
    protected override void OnMouseWheel(MouseWheelEventArgs e)
    Parameters
    Type Name Description
    System.Windows.Input.MouseWheelEventArgs e

    The System.Windows.Input.MouseWheelEventArgs that contains the event data.

    OnPopupDropDownHeightChanged(DependencyPropertyChangedEventArgs)

    Updates property value cache and raises PopupDropDownHeightChanged event.

    Declaration
    protected virtual void OnPopupDropDownHeightChanged(DependencyPropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Windows.DependencyPropertyChangedEventArgs e

    Property changes details, such as old value and new value.

    OnRecentlyUsedFontsChanged(DependencyPropertyChangedEventArgs)

    Updates property value cache and raises RecentlyUsedFontsChanged event.

    Declaration
    protected virtual void OnRecentlyUsedFontsChanged(DependencyPropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Windows.DependencyPropertyChangedEventArgs e

    Property changes details, such as old value and new value.

    OnSelectedFontFamilyChanged(DependencyPropertyChangedEventArgs)

    Updates property value cache and raises SelectedFontFamilyChanged event.

    Declaration
    protected virtual void OnSelectedFontFamilyChanged(DependencyPropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Windows.DependencyPropertyChangedEventArgs e

    Property changes details, such as old value and new value.

    OnThemeFontsChanged(DependencyPropertyChangedEventArgs)

    Updates property value cache and raises ThemeFontsChanged event.

    Declaration
    protected virtual void OnThemeFontsChanged(DependencyPropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Windows.DependencyPropertyChangedEventArgs e

    Property changes details, such as old value and new value.

    Events

    DisplayFontNamesInSystemFontChanged

    Event that is raised when DisplayFontNamesInSystemFont property is changed.

    Declaration
    public event PropertyChangedCallback DisplayFontNamesInSystemFontChanged
    Event Type
    Type Description
    System.Windows.PropertyChangedCallback

    FocusedFontFamilyChanged

    Event that is raised when FocusedFontFamily property is changed.

    Declaration
    public event PropertyChangedCallback FocusedFontFamilyChanged
    Event Type
    Type Description
    System.Windows.PropertyChangedCallback

    FontsSourceChanged

    Event that is raised when FontsSource property is changed.

    Declaration
    public event PropertyChangedCallback FontsSourceChanged
    Event Type
    Type Description
    System.Windows.PropertyChangedCallback

    GroupHeaderStyleChanged

    Event that is raised when GroupHeaderStyle property is changed.

    Declaration
    public event PropertyChangedCallback GroupHeaderStyleChanged
    Event Type
    Type Description
    System.Windows.PropertyChangedCallback

    IsDropDownOpenChanged

    Event that is raised when IsDropDownOpen property is changed.

    Declaration
    public event PropertyChangedCallback IsDropDownOpenChanged
    Event Type
    Type Description
    System.Windows.PropertyChangedCallback

    ItemContainerStyleChanged

    Event that is raised when ItemContainerStyle property is changed.

    Declaration
    public event PropertyChangedCallback ItemContainerStyleChanged
    Event Type
    Type Description
    System.Windows.PropertyChangedCallback

    ItemTemplateChanged

    Event that is raised when ItemTemplate property is changed.

    Declaration
    public event PropertyChangedCallback ItemTemplateChanged
    Event Type
    Type Description
    System.Windows.PropertyChangedCallback

    PopupDropDownHeightChanged

    Event that is raised when PopupDropDownHeight property is changed.

    Declaration
    public event PropertyChangedCallback PopupDropDownHeightChanged
    Event Type
    Type Description
    System.Windows.PropertyChangedCallback

    RecentlyUsedFontsChanged

    Event that is raised when RecentlyUsedFonts property is changed.

    Declaration
    public event PropertyChangedCallback RecentlyUsedFontsChanged
    Event Type
    Type Description
    System.Windows.PropertyChangedCallback

    SelectedFontFamilyChanged

    Event that is raised when SelectedFontFamily property is changed.

    Declaration
    public event PropertyChangedCallback SelectedFontFamilyChanged
    Event Type
    Type Description
    System.Windows.PropertyChangedCallback

    ThemeFontsChanged

    Event that is raised when ThemeFonts property is changed.

    Declaration
    public event PropertyChangedCallback ThemeFontsChanged
    Event Type
    Type Description
    System.Windows.PropertyChangedCallback
    Back to top Generated by DocFX
    Copyright © 2001 - 2022 Syncfusion Inc. All Rights Reserved