简体   繁体   中英

Using font icons in WP8.1 Silverlight ApplicationBar

I'm trying to figure out why I can't use the glyphicons that are available to WP8 XAML apps in my Silverlight 8.1 Application.

As you can see from the fragment below, I have to specify an image to use as the icon compared to the ease of using one of the glyph icons.

<phone:PhoneApplicationPage.ApplicationBar>
    <shell:ApplicationBar IsVisible="True" IsMenuEnabled="True">
        <shell:ApplicationBarIconButton IconUri="/Images/appbar_button2.png" Text="Button 2"/>

Does anyone know how I can simply use the icons without needing to go through the extra work of creating images?

In WP8.1 Silverlight you need to use an image. The symbol enumeration with those glyphicons are only available for Windows (Phone) Store apps only, see the documentation :

Minimum supported Phone: Windows Phone 8.1 [Windows Runtime apps only]

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM