QT 滚动条样式(记录一下)

//整个垂直滚动条区域样式
"QScrollBar:vertical{background-color:transparent;width:20px;height:255px;padding-top:20px;padding-bottom:20px;}"   
//滚动条上⾯和下⾯区域样式
"QScrollBar::add-page:vertical,QScrollBar::sub-page:vertical{background-color:transparent;}"         
//滑块区域样式
"QScrollBar::handle:vertical{background:rgba(75,120,154,0.8);border:1px solid rgba(255,0,0,1);}"    
//⿏标滑过滑块样式
"QScrollBar::handle:vertical:hover,QScrollBar::handle:vertical:pressed{background:red;border:1px solid rgb(255,255,255);}"
//向上箭头样式
"QScrollBar::sub-line:vertical{height:12px;width:12px;background:rgba(255,0,0,0.5) url(:/1.png);}"
//向上箭头滑过、摁下样式
"QScrollBar::sub-line:vertical:hover,QScrollBar::sub-line:vertical:pressed{height:20px;width:20px;background:red url(:/1.png);border:1px solid rgb(255,255,255);}"
//向下箭头样式
"QScrollBar::add-line:vertical{height:20px;width:20px;background:red url(:/1.png);}"
//向下箭头滑过、摁下样式
"QScrollBar::add-line:vertical:hover,QScrollBar::add-line:vertical:pressed{height:20px;width:20px;background:red url(:/1.png);border:1px solid rgb(255,255,25

你可能感兴趣的:(css,html,css3)