1

I wonder how I could add a style sheet to my qtableviews scrollbar. I'm sure it should work somehow, but I'm not getting it to work..

sth. like this:

 <widget class="QTableView" name="tableView">
         <property name="styleSheet">
           <string notr="true">
            QTableView QScrollBar:horizontal {
             border: 2px solid grey;
             background: #32CC99;
             height: 15px;
             margin: 0px 20px 0 20px;
             }
           </string>
         </property>
       </widget>
Prifulnath
  • 463
  • 7
  • 24
easysaesch
  • 159
  • 1
  • 14
  • It works for me. Do you edit .ui file manually? May be you need to escape some characters? – ilotXXI Sep 26 '16 at 15:29
  • what do you mean by escaping some more characters? I'm editingmy .ui file manually and I don't get it to work – easysaesch Sep 29 '16 at 15:51
  • Don't know. Qt Designer generates similar code. Try to open your .ui file in Designer. Will it tell you errors and can you set the style sheet by it's properties editor? – ilotXXI Sep 29 '16 at 18:33

0 Answers0