当前位置: 首页 > wzjs >正文

网站建设工作建议搜索引擎优化的特点

网站建设工作建议,搜索引擎优化的特点,成都消防设计公司,合肥哪个公司做网站好QTabWidget 是 Qt 框架中用于创建选项卡式界面的控件。可以通过样式表(QSS,Qt Style Sheets)来设置 QTabWidget 的外观。以下是一些常见的样式设置示例: 1. 基本样式设置 tab_widget.setStyleSheet("""QTabWidge…

QTabWidget 是 Qt 框架中用于创建选项卡式界面的控件。可以通过样式表(QSS,Qt Style Sheets)来设置 QTabWidget 的外观。以下是一些常见的样式设置示例:

1. 基本样式设置

tab_widget.setStyleSheet("""QTabWidget::pane {border: 1px solid #ccc;background-color: #f0f0f0;}QTabBar::tab {background: #ddd;border: 1px solid #ccc;padding: 10px;font-size: 14px;}QTabBar::tab:selected {background: #f0f0f0;border-bottom-color: #f0f0f0;}QTabBar::tab:hover {background: #eee;}
""")

2. 设置选项卡的宽度和高度

tab_widget.setStyleSheet("""QTabBar::tab {width: 100px;height: 30px;}
""")

3. 设置选项卡的圆角

tab_widget.setStyleSheet("""QTabBar::tab {border-top-left-radius: 5px;border-top-right-radius: 5px;}
""")

4. 设置选项卡的背景颜色和字体颜色

tab_widget.setStyleSheet("""QTabBar::tab {background: #555;color: white;}QTabBar::tab:selected {background: #777;color: yellow;}
""")

5. 设置选项卡的图标和文本对齐方式

tab_widget.setStyleSheet("""QTabBar::tab {padding-left: 20px; /* 图标和文本之间的间距 */text-align: left; /* 文本左对齐 */}
""")

6. 设置选项卡的关闭按钮

tab_widget.setStyleSheet("""QTabBar::close-button {image: url(close.png); /* 关闭按钮的图标 */subcontrol-position: right; /* 关闭按钮的位置 */}QTabBar::close-button:hover {background: #f00; /* 鼠标悬停时的背景颜色 */}
""")

7. 设置选项卡的边框和间距

tab_widget.setStyleSheet("""QTabWidget::pane {border: 2px solid #ccc;margin: 0px;padding: 0px;}QTabBar::tab {margin: 0px;padding: 5px;}
""")

8. 设置选项卡的渐变背景

tab_widget.setStyleSheet("""QTabBar::tab {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #E1E1E1, stop: 0.4 #DDDDDD,stop: 0.5 #D8D8D8, stop: 1.0 #D3D3D3);}QTabBar::tab:selected {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #fafafa, stop: 1 #f0f0f0);}
""")

9. 设置选项卡的阴影效果

tab_widget.setStyleSheet("""QTabBar::tab {border: 1px solid #ccc;border-bottom-color: #f0f0f0; /* 底部边框颜色 */margin-right: 2px; /* 选项卡之间的间距 */box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.1); /* 阴影效果 */}
""")

10. 设置选项卡的字体

tab_widget.setStyleSheet("""QTabBar::tab {font-family: Arial;font-size: 12px;font-weight: bold;}
""")

11. 设置选项卡的图标

tab_widget.setStyleSheet("""QTabBar::tab {icon-size: 24px; /* 图标大小 */}
""")

12. 设置选项卡的悬停效果

tab_widget.setStyleSheet("""QTabBar::tab:hover {background: #eee;color: #000;}
""")

13. 设置选项卡的禁用状态

tab_widget.setStyleSheet("""QTabBar::tab:disabled {background: #ccc;color: #888;}
""")

14. 设置选项卡的选中状态

tab_widget.setStyleSheet("""QTabBar::tab:selected {background: #f0f0f0;border-bottom-color: #f0f0f0;}
""")

15. 设置选项卡的底部边框

tab_widget.setStyleSheet("""QTabBar::tab {border-bottom: 2px solid #ccc;}QTabBar::tab:selected {border-bottom: 2px solid #f00;}
""")

16. 设置选项卡的顶部边框

tab_widget.setStyleSheet("""QTabBar::tab {border-top: 2px solid #ccc;}QTabBar::tab:selected {border-top: 2px solid #f00;}
""")

17. 设置选项卡的左右边框

tab_widget.setStyleSheet("""QTabBar::tab {border-left: 2px solid #ccc;border-right: 2px solid #ccc;}QTabBar::tab:selected {border-left: 2px solid #f00;border-right: 2px solid #f00;}
""")

18. 设置选项卡的背景图片

tab_widget.setStyleSheet("""QTabBar::tab {background-image: url(tab_bg.png);}QTabBar::tab:selected {background-image: url(tab_bg_selected.png);}
""")

19. 设置选项卡的渐变边框

tab_widget.setStyleSheet("""QTabBar::tab {border: 1px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #ccc, stop: 1 #999);}QTabBar::tab:selected {border: 1px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #f00, stop: 1 #c00);}
""")

20. 设置选项卡的圆角边框

tab_widget.setStyleSheet("""QTabBar::tab {border: 1px solid #ccc;border-top-left-radius: 5px;border-top-right-radius: 5px;}QTabBar::tab:selected {border: 1px solid #f00;border-top-left-radius: 5px;border-top-right-radius: 5px;}
""")

21. 设置选项卡的阴影边框

tab_widget.setStyleSheet("""QTabBar::tab {border: 1px solid #ccc;box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.1);}QTabBar::tab:selected {border: 1px solid #f00;box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.1);}
""")

22. 设置选项卡的渐变背景和边框

tab_widget.setStyleSheet("""QTabBar::tab {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #E1E1E1, stop: 0.4 #DDDDDD,stop: 0.5 #D8D8D8, stop: 1.0 #D3D3D3);border: 1px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #ccc, stop: 1 #999);}QTabBar::tab:selected {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #fafafa, stop: 1 #f0f0f0);border: 1px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #f00, stop: 1 #c00);}
""")

23. 设置选项卡的渐变背景和圆角边框

tab_widget.setStyleSheet("""QTabBar::tab {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #E1E1E1, stop: 0.4 #DDDDDD,stop: 0.5 #D8D8D8, stop: 1.0 #D3D3D3);border: 1px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #ccc, stop: 1 #999);border-top-left-radius: 5px;border-top-right-radius: 5px;}QTabBar::tab:selected {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #fafafa, stop: 1 #f0f0f0);border: 1px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #f00, stop: 1 #c00);border-top-left-radius: 5px;border-top-right-radius: 5px;}
""")

24. 设置选项卡的渐变背景和阴影边框

tab_widget.setStyleSheet("""QTabBar::tab {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #E1E1E1, stop: 0.4 #DDDDDD,stop: 0.5 #D8D8D8, stop: 1.0 #D3D3D3);border: 1px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #ccc, stop: 1 #999);box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.1);}QTabBar::tab:selected {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #fafafa, stop: 1 #f0f0f0);border: 1px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #f00, stop: 1 #c00);box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.1);}
""")

25. 设置选项卡的渐变背景和圆角阴影边框

tab_widget.setStyleSheet("""QTabBar::tab {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #E1E1E1, stop: 0.4 #DDDDDD,stop: 0.5 #D8D8D8, stop: 1.0 #D3D3D3);border: 1px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #ccc, stop: 1 #999);border-top-left-radius: 5px;border-top-right-radius: 5px;box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.1);}QTabBar::tab:selected {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #fafafa, stop: 1 #f0f0f0);border: 1px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #f00, stop: 1 #c00);border-top-left-radius: 5px;border-top-right-radius: 5px;box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.1);}
""")

26. 设置选项卡的渐变背景和圆角阴影边框

tab_widget.setStyleSheet("""QTabBar::tab {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #E1E1E1, stop: 0.4 #DDDDDD,stop: 0.5 #D8D8D8, stop: 1.0 #D3D3D3);border: 1px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #ccc, stop: 1 #999);border-top-left-radius: 5px;border-top-right-radius: 5px;box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.1);}QTabBar::tab:selected {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #fafafa, stop: 1 #f0f0f0);border: 1px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #f00, stop: 1 #c00);border-top-left-radius: 5px;border-top-right-radius: 5px;box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.1);}
""")

27. 设置选项卡的渐变背景和圆角阴影边框

tab_widget.setStyleSheet("""QTabBar::tab {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #E1E1E1, stop: 0.4 #DDDDDD,stop: 0.5 #D8D8D8, stop: 1.0 #D3D3D3);border: 1px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #ccc, stop: 1 #999);border-top-left-radius: 5px;border-top-right-radius: 5px;box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.1);}QTabBar::tab:selected {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #fafafa, stop: 1 #f0f0f0);border: 1px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #f00, stop: 1 #c00);border-top-left-radius: 5px;border-top-right-radius: 5px;box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.1);}
""")

28. 设置选项卡的渐变背景和圆角阴影边框

tab_widget.setStyleSheet("""QTabBar::tab {background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1,stop: 0 #E1E1E1, stop: 0.4 #DDDDDD,stop: 0.5 #D8D8D8, stop: 1.0 #D3D3D3);border: 1px solid qlineargradient(x1
http://www.dtcms.com/wzjs/333726.html

相关文章:

  • 网站的互动十大搜索引擎
  • 包装设计案例成都网站优化seo
  • 做商业网站要交税吗怎么建立企业网站免费的
  • 公众号做视频网站吗seo教程免费分享
  • 外贸网站建设长沙互联网公司
  • vs网站中的轮播怎么做建立网站需要什么条件
  • 做援交的网站大数据精准营销
  • 过年做那些网站能致富免费网络推广软件
  • 传奇私服建设网站的教程培训管理平台
  • wordpress代码seoseo技术代理
  • 北京做网站比较大的公司郑州seo网络推广
  • 专业供应的网站制作郑州网络推广效果
  • 响应式网站算几个页面4a广告公司
  • 在线制作二维码网站营销推广计划怎么写
  • 宝塔Linux面板清理建设的网站自媒体seo是什么意思
  • 包头做网站企业吉林网站seo
  • 邢台网站建设免费做网站排名seo jsbapp9
  • 一个专门做网站建设的公司批量查询权重
  • 广州企业网站建设推荐seo是什么意思怎么解决
  • 服务好的常州网站建设域名138查询网
  • 自己做的网站可以查看谁访问吗下载百度app最新版
  • 粉色的网站百度seo排名公司
  • 网站维护是什么职业做营销策划的公司
  • 网站建设 提供源码网络推广团队哪家好
  • 阿里巴巴网站建设代理网络推广外包公司干什么的
  • 珠海网站建设 金蝶360广告联盟平台
  • 哪个网站做童装批发常用seo站长工具
  • 国外网站在国内做镜像站点企业推广文案范文
  • 做网站栏目是什么意思优化什么建立生育支持政策体系
  • 建模软件石家庄seo推广