更改 Package.appxmanifest 文件中标题栏的背景颜色

Change the Background color of the TitleBar in the Package.appxmanifest file

我需要在我的通用应用程序中修改 ApplicationViewTitleBar 的背景颜色,我在我的项目中为每个 Class 在后面的代码中这样做:

ApplicationViewTitleBar titleBar = ApplicationView.GetForCurrentView().TitleBar;
titleBar.BackgroundColor = Colors.Black;
titleBar.ForegroundColor = Colors.White;
titleBar.ButtonBackgroundColor = Colors.Black;
titleBar.ButtonForegroundColor = Colors.White;

我有一个问题, - 我在 Package.appxmanifest 文件,请问这里有没有指定的属性 显示启动画面时我可以用来修改标题栏背景颜色的文件

感谢帮助

通过将 page.similar 扩展到此示例,使用自定义初始屏幕执行此操作的一种方法 https://msdn.microsoft.com/en-us/library/windows/apps/mt187309.aspx 和其他给你的建议,为什么要在每个页面中添加所有这五行标题栏,你可以使用 Behavior SDK 或创建静态 class with Dependency Properties.for 更多信息见下文 link。 https://marcominerva.wordpress.com/2015/05/19/easily-manage-the-title-bar-in-windows-10-apps/