在Windows 10程序中,以前只能用于全屏方式的Metro程序现在可以运行在窗口模式下了,并且改了个新名字,叫Windows 通用程序(Universal Windows app),简称UWP程序。新的UWP程序虽然大体上还是和以前的Metro程序差不多的,但还是引入了一点新东西的,本文这里就介绍一下它的标题栏设置的几个特性。

隐藏标题栏:

将应用界面扩展至 Titlebar 区域

CoreApplication.GetCurrentView().TitleBar.ExtendViewIntoTitleBar = true;

修改标题栏颜色:

var tiWtleBar = Windows.UI.ViewManagement.ApplicationView.GetForCurrentView().TitleBar;
    titleBar.BackgroundColor = Colors.DarkBlue;
    titleBar.ForegroundColor = Colors.White;
    titleBar.ButtonHoverBackgroundColor = Colors.LightBlue;
    titleBar.ButtonBackgroundColor = Colors.Maroon;
    titleBar.ButtonForegroundColor = Colors.White;

自定义标题栏控件:

可以将界面中任意控件指定为标题栏,指定后该控件将具有标题栏的行为特性,如拖动窗口、右键弹出窗口操作菜单等。

Window.Current.SetTitleBar(grid);

Windows 10 UWP程序标题栏设置的更多相关文章

  1. Mobilize.Net Silverlight bridge to Windows 10 UWP

    Windows UWP 既 Windows 10 Universal Windows platform,这个微软基于Windows NT内核的个运行时(Runtime)平台,此平台横跨所有的 Wind ...

  2. DevExpress Windows 10 UWP Controls新版亮点

    行业领先的.NET界面控件2018年第二次重大更新——DevExpress v18.2日前正式发布,本站将以连载的形式为大家介绍新版本新功能.本文将介绍了DevExpress Windows 10 U ...

  3. Windows 10 UWP开发:如何去掉ListView默认的选中效果

    原文:Windows 10 UWP开发:如何去掉ListView默认的选中效果 开发UWP的时候,很多人会碰到一个问题,就是ListView在被数据绑定之后经常有个默认选中的效果,就像这样: 而且它不 ...

  4. 使用Prism6 建立 Windows 10 通用程序.

    使用Prism6 建立 Windows 10 通用程序. 目标: 使用prism6,建立Windows 通用程序项目. 1, 解决方案—添加新建项目—通用—空白应用—输入名称—确定—确定 2 ,引用上 ...

  5. 背水一战 Windows 10 (5) - UI: 标题栏

    [源码下载] 背水一战 Windows 10 (5) - UI: 标题栏 作者:webabcd 介绍背水一战 Windows 10 之 UI 标题栏 示例TitleBarDemo.xaml <P ...

  6. DevExpress v18.1新版亮点——Windows 10 UWP篇

    用户界面套包DevExpress v18.1日前终于正式发布,本站将以连载的形式为大家介绍各版本新增内容.本文将介绍了DevExpress Windows 10 UWP v18.1 的新功能,快来下载 ...

  7. 修改 Windows 10 UWP 应用任务栏图标

    修改 Windows 10 UWP 应用任务栏图标 Windows 7 时代,修改任务栏图标很简单,右键打开属性,更改图标即可.但步入 Windows 8 之后,随着应用商店 UWP 应用的问世,可以 ...

  8. 设置UWP程序自启动(Automate launching Windows 10 UWP apps)

    在开发UWP程序的过程中,有时候需要设置程序的自启.本人实现的步骤如下: 1.在VS中激活Protocol (Package.appxmanifest --> Declarations --&g ...

  9. 1)Win10-UWA开发 UWP应用操作方法、Windows 10应用程序的指南

    孙广东   2015.8.22 全部任务类型(比方在列表中显示数据或创建导航窗格)的说明和代码演示样例. 在这一节 包含例如以下: 主题 描写叙述 Accessibility 创建通用的Windows ...

随机推荐

  1. 用js实现图片连播和联级菜单的实现

    <!DOCTYPE html> <html> <head> <title>图片轮播</title> <style> div{ b ...

  2. IndexWriterConfig的各个配置项说明(转)

    1.Analyzer:分析器 2.matchVersion:所用Lucene的版本 3.ramBufferSizeMB:随机内存 默认为16M. 用于控制buffer索引文档的内存上限,如果buffe ...

  3. 查找内容grep命令

    标准unix/linux下的grep通过以下参数控制上下文 grep -C 5 foo file 显示file文件中匹配foo字串那行以及上下5行 grep -B 5 foo file 显示foo及前 ...

  4. HDU 2647 Reward(拓扑排序+判断环+分层)

    题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=2647 题目大意:要给n个人发工资,告诉你m个关系,给出m行每行a b,表示b的工资小于a的工资,最低工 ...

  5. 洛谷 P1957 口算练习题 题解

    题目传送门 这道题是考字符串处理,另外输入要使用c++的cin的神奇功能. #include<bits/stdc++.h> using namespace std; int n;char ...

  6. javaWeb之写一个最简单的servlet

    1. 创建一个类servletTest2 继承HttpServlet类. public class servletTest2 extends HttpServlet { public servletT ...

  7. 【PAT】1001. A+B Format (20)

    1001. A+B Format (20) Calculate a + b and output the sum in standard format -- that is, the digits m ...

  8. 【LOJ】#2014. 「SCOI2016」萌萌哒

    题解 这个题好妙啊 首先我们发现,如果我们可以暴力,就是把相同的元素拿并查集合起来,最后统计集合个数\(cnt\) 答案是\(9\*10^{cnt - 1}\) 然而我们做不到= = 我们可以用倍增的 ...

  9. Apache+PHP环境搭建

    第一次搭建Apache+PHP+MySQL的开发环境,发现Apache与PHP的整合非常麻烦,先整理记录如下: 一.安装Apache 1.登录http://httpd.apache.org/downl ...

  10. [转]SharePoint 2010 Powershell Feature Cmdlets

    In this installment its time to look at the various cmdlets that have to do with Features. Of course ...