Chinaunix首页 | 论坛 | 博客
  • 博客访问: 280292
  • 博文数量: 59
  • 博客积分: 1346
  • 博客等级: 中尉
  • 技术积分: 461
  • 用 户 组: 普通用户
  • 注册时间: 2011-01-06 17:17
文章分类

全部博文(59)

文章存档

2012年(9)

2011年(50)

分类: C/C++

2011-11-09 19:28:59

linux系统中QGroupBox没有边框,所以要对其进行设置。用样式表来设置边框
点击 change stylesheet,输入
 
QGroupBox {
    border-width:1px;   //线的粗细
   border-style:solid;
  border-color:lightGray;   //颜色,
  margin-top: 0.5ex;  //文字在方框中位置的偏离度
}
QGroupBox::title {
     subcontrol-origin: margin;
     subcontrol-position: top left;
   left:25px;       //线的偏离度
     margin-left: 0px;
     padding:0 1px;   //文字在方框中位置的偏离度
}
阅读(19437) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~