Reputation: 301
Can I add more symbols? is that I'm creating an app but standards like this list do not suffice, and I need, or would like to have more.
https://learn.microsoft.com/en-us/uwp/api/windows.ui.xaml.controls.symbol
Upvotes: 0
Views: 3313
Reputation: 2581
If I understand you correctly, You want to have more symbols in your app than the list you mentioned provides.
Yes, you can do that. If you want to keep using SymbolIcon
, then you have to either set it's Symbol
in code behind or use x:Bind
.
Setting the symbol in code behind:
If your XAML looks like this:
<SymbolIcon x:Name="MySymbolIcon" />
then your code behind is:
MySymbolIcon.Symbol = (Symbol)0xE156;
Or, using x:Bind :
If you have a Symbol
in you code behind like this:
Symbol Avatar = (Symbol)0xE156;
then you can x:Bind
to it in the XAML like this:
<SymbolIcon Symbol="{x:Bind Avatar}" />
And now you may wonder, where will you find these creepy looking hex codes? Well, there's an app Character Map UWP which will provide you a nice list like this:
Or, Using FontIcon :
You see the Codes at the bottom right corner of the image I included? There's code for FontIcon
too. Just copy paste it.
Hope that helps.
Upvotes: 2
Reputation: 1
No you can not extend the Symbol enumeration used by SymbolIcon but you can use the FontIcon.
Upvotes: 0