Hi Folks,
Im having trouble understanding stylesheets and how to set styling of components of a QTreeView.
I did look at the docs here:
http://doc.qt.io/qt-5/stylesheet-reference.html &
http://doc.qt.io/qt-4.8/stylesheet-examples.html
The component I'd like to style are the Header(Title, Color, Height, Border), The ArrowIcon (Closed and Open Color), and the Scrollbar (Color, Width).
Also would like to learn how to style things in general. Is there a system of thinking when styling widgets? How would I go about knowing what tags to call. example, i dont know what the arrow thing is called to style it, or the scrollbar.
I used this for the ScrollArea, but/and i tried to use it with the scroll for the QTreeView, but nothing happened:
I tried:Qt Code:
QscrollBar::vertical{width: 12px;} QscrollBar::handle:vertical{background: #505050}To copy to clipboard, switch view to plain text mode
Qt Code:
To copy to clipboard, switch view to plain text mode
I guess what I'm asking for is the syntax...maybe.
Another thing I would like to do is understand the MODEL system. Im using QFileSystemModel as the model set to my TreeView. I was able to set some filters to get the data I want, but how do I not show the last folders in a directory tree?
Cheers!
Bookmarks