opacity
2015-07-06 14:41
218 查看
opacity : real
This property holds the opacity of the item. Opacity is specified as a number between 0.0 (fully transparent) and 1.0 (fully opaque). The default value is 1.0.
When this property is set, the specified opacity is also applied individually to child items. This may have an unintended effect in some circumstances. For example in the second set of rectangles below, the red rectangle has specified an opacity of 0.5, which affects the opacity of its blue child rectangle even though the child has not specified an opacity.
Item {
Rectangle {
color: "red"
width: 100; height: 100
Rectangle {
color: "blue"
x: 50; y: 50; width: 100; height: 100
}
}
}
Item {
Rectangle {
opacity: 0.5
color: "red"
width: 100; height: 100
Rectangle {
color: "blue"
x: 50; y: 50; width: 100; height: 100
}
}
}
This property holds the opacity of the item. Opacity is specified as a number between 0.0 (fully transparent) and 1.0 (fully opaque). The default value is 1.0.
When this property is set, the specified opacity is also applied individually to child items. This may have an unintended effect in some circumstances. For example in the second set of rectangles below, the red rectangle has specified an opacity of 0.5, which affects the opacity of its blue child rectangle even though the child has not specified an opacity.
Item {
Rectangle {
color: "red"
width: 100; height: 100
Rectangle {
color: "blue"
x: 50; y: 50; width: 100; height: 100
}
}
}
Item {
Rectangle {
opacity: 0.5
color: "red"
width: 100; height: 100
Rectangle {
color: "blue"
x: 50; y: 50; width: 100; height: 100
}
}
}
相关文章推荐
- HOWTO: install kernel debuginfo packages on SUSE Linux Enterprise Server 11
- Shell 变量
- 在Windows的Apache服务器上配置对PHP和CGI的支持
- Linux常用命令大全
- win7 - 虚拟linux,共享设置
- linux调度器_第三代cfs(4)_总手稿_完结篇
- 静态IP设置(基于CentOS7)
- centOS 7安装 gitLab
- Apache服务器下防止图片盗链的办法
- OpenH264 Migration into Webrtc Intro - Windows
- Openstack rest api理解
- xshell连接远程电脑上的虚拟机上的linux
- 25、Linux Make 命令详解
- 【项目管理】 并发服务设计的三种架构
- Cscope的使用(领略Vim + Cscope的强大魅力)
- 如何改变nginx显示静态目录文件的文件名长度
- Linux查看程序端口占用情况
- Linux下安装软件的几种方法
- 使用 NgxFancyIndex 代替nginx原有的autoindex模块美化文件显示
- linux系统安装mysql