StandardStyles.xaml发生了什么?

时间:2014-11-02 09:55:16

标签: c# xaml windows-store-apps

Windows Store应用项目的StandardStyles.xaml文件发生了什么变化?我正在尝试向AppBar添加一个PRINT按钮,但它不在intellisense或属性窗格中,但我知道它在StandardStyles文件中,因为我在过去(大约一年前)使用过它。为什么标准样式文件不能在任何地方找到,如何将其恢复并正确使用,因为我可以在过去使用它?

我在网上找到的都是一些博客文章,提到它已被删除并被generic.xaml取代,但没有提及如何在我的项目中获取它。

2 个答案:

答案 0 :(得分:0)

据我所知,PrintAppBarButtonStyle中从来没有StandardStyles.xaml,因为Microsoft希望您只使用 Devices 下的Charms栏进行打印。

通常,语法<Button Style="{StaticResource XXXAppBarButtonStyle}" />已被新的AppBarButton control取代,其使用方法如下:

<AppBarButton Icon="XXX" Label="Descriptive text" Click="AppBarButton_Click"/>

有关所有可用图标的列表,请参阅Symbol enumeration - 但是,遗憾的是,这个图标缺少打印符号。

答案 1 :(得分:0)

StandardStyles.xaml替换为generic.xaml。阅读更多here