Table of Contents

Class SymbolIconExtension

Namespace
Wpf.Ui.Markup
Assembly
Wpf.Ui.dll

Custom MarkupExtension which can provide SymbolIcon.

public class SymbolIconExtension : MarkupExtension
Inheritance
SymbolIconExtension
Inherited Members

Examples

<ui:Button
    Appearance="Primary"
    Content="WPF UI button with font icon"
    Icon="{ui:SymbolIcon Symbol=Fluent24}" />
<ui:Button Icon="{ui:SymbolIcon Fluent24}" />
<ui:HyperlinkButton Icon="{ui:SymbolIcon Fluent24}" />
<ui:TitleBar Icon="{ui:SymbolIcon Fluent24}" />

Constructors

SymbolIconExtension()

public SymbolIconExtension()

SymbolIconExtension(string)

public SymbolIconExtension(string symbol)

Parameters

symbol string

SymbolIconExtension(SymbolRegular)

public SymbolIconExtension(SymbolRegular symbol)

Parameters

symbol SymbolRegular

SymbolIconExtension(SymbolRegular, bool)

public SymbolIconExtension(SymbolRegular symbol, bool filled)

Parameters

symbol SymbolRegular
filled bool

Properties

Filled

[ConstructorArgument("filled")]
public bool Filled { get; set; }

Property Value

bool

FontSize

public double FontSize { get; set; }

Property Value

double

Symbol

[ConstructorArgument("symbol")]
public SymbolRegular Symbol { get; set; }

Property Value

SymbolRegular

Methods

ProvideValue(IServiceProvider)

When implemented in a derived class, returns an object that is provided as the value of the target property for this markup extension.

public override object ProvideValue(IServiceProvider serviceProvider)

Parameters

serviceProvider IServiceProvider

A service provider helper that can provide services for the markup extension.

Returns

object

The object value to set on the property where the extension is applied.