滑块控件QSlider,如果设置的垂直样式,其进度颜色和剩余颜色,刚好和横向样式的颜色相反的,不确定这个是否是Qt的BUG,Qt456都是这个现象
cpp
QSlider::groove:horizontal{
height:8px;
background:#FF0000;
}
QSlider::add-page:horizontal{
height:8px;
background:#FF0000;
}
QSlider::sub-page:horizontal{
height:8px;
background:#00FF00;
}
QSlider::handle:horizontal{
width:10px;
background:#0000FF;
}
QSlider::groove:vertical{
width:8px;
background:#FF0000;
}
QSlider::add-page:vertical{
width:8px;
background:#00FF00;
}
QSlider::sub-page:vertical{
width:8px;
background:#FF0000;
}
QSlider::handle:vertical{
height:10px;
background:#0000FF;
}
推荐一个零声学院项目课,个人觉得老师讲得不错,分享给大家:
零声白金学习卡(含基础架构/高性能存储/golang云原生/音视频/Linux内核)
https://xxetb.xet.tech/s/VsFMs