开发者

WP7 Application Bar Icons not showing on Simulator (but works in Blend)

开发者 https://www.devze.com 2023-01-26 12:31 出处:网络
It is most probably a stupid mistake, but can anyone tell me why my icons are showing in Blend, but not in开发者_如何学Go the simulator (and not in VS10, but that\'s not really an issue)?

It is most probably a stupid mistake, but can anyone tell me why my icons are showing in Blend, but not in开发者_如何学Go the simulator (and not in VS10, but that's not really an issue)?

WP7 Application Bar Icons not showing on Simulator (but works in Blend)

Edit - Here is my XAML :

    <phone:PhoneApplicationPage.ApplicationBar>
    <shell:ApplicationBar IsVisible="True" IsMenuEnabled="True">
        <shell:ApplicationBarIconButton IconUri="/Images/share.png" Text="Partager"/>
        <shell:ApplicationBarIconButton IconUri="/Images/appbar.edit.rest.png" Text="Note"/>
        <shell:ApplicationBarIconButton IconUri="/Images/appbar.feature.camera.rest.png" Text="Photos/Vidéos"/>
        <shell:ApplicationBarIconButton IconUri="/Images/calendar.png" Text="Rendez-vous"/>
        <shell:ApplicationBar.MenuItems> 
            <shell:ApplicationBarMenuItem Text="MenuItem 1"/>
            <shell:ApplicationBarMenuItem Text="MenuItem 2"/>
        </shell:ApplicationBar.MenuItems>
    </shell:ApplicationBar>
</phone:PhoneApplicationPage.ApplicationBar>

My four .png files are 48x48, transparent .png with black foreground, since the appbar.*.rest.png files where like that and found in the Microsoft icons folder


Make sure that the image properties 'build to action' is Content.


Are your icons:

  • Transparent with a white foreground
  • The right size (48x48)
  • PNGs

? If so, that should be fine. What does your XAML look like?

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号