File Manager Header Colors

  • snowgoer540
  • snowgoer540's Avatar Topic Author
  • Offline
  • Moderator
  • Moderator
More
27 Dec 2020 00:14 #193256 by snowgoer540
File Manager Header Colors was created by snowgoer540
One of the recent file manager updates added some welcomed additions. But no good deed... haha.

With the header came a bit of a color change. As can be seen below, the header has a grey background that makes the font hard to read. Is there an easy way to change the styling of this particular section?



Thanks!
Attachments:

Please Log in or Create an account to join the conversation.

More
27 Dec 2020 00:49 #193257 by cmorley
Replied by cmorley on topic File Manager Header Colors
play around with this added to the sylesheet:
QHeaderView::section {
    background-color:  foregnd;
    color: white;
    border: 1px solid #6c6c6c;
}

If you are interested - here is not a bad reference of stylesheets.
doc.qt.io/qt-5/stylesheet-examples.html#customizing-qheaderview

Please Log in or Create an account to join the conversation.

  • snowgoer540
  • snowgoer540's Avatar Topic Author
  • Offline
  • Moderator
  • Moderator
More
27 Dec 2020 01:14 #193258 by snowgoer540
Replied by snowgoer540 on topic File Manager Header Colors
Well that got me there, albeit maybe a discovery is made too...

I'm on Mint 19.2. The color changes for Phill by just setting the background color.

For me, I have to set the background color and the border as well:
#filemanager QHeaderView::section {
    background-color:  backalt;
    border: 1px solid backalt;
}

Results in this:


Without the border line, the color refuses to change on Mint it seems.

Thanks for pointing me in the right direction. I will definitely check out the link you provided.
Attachments:

Please Log in or Create an account to join the conversation.

  • snowgoer540
  • snowgoer540's Avatar Topic Author
  • Offline
  • Moderator
  • Moderator
More
27 Dec 2020 01:39 - 27 Dec 2020 01:39 #193259 by snowgoer540
Replied by snowgoer540 on topic File Manager Header Colors
We've discovered that
border: none;

works as well.
Last edit: 27 Dec 2020 01:39 by snowgoer540.

Please Log in or Create an account to join the conversation.

More
06 Jan 2021 01:55 #194181 by persei8
Replied by persei8 on topic File Manager Header Colors
With my preferred stylesheet, the alternating row colors come out as grey and white with the white being unreadable. Some way to turn it off? Thanks.
Jim

Please Log in or Create an account to join the conversation.

More
06 Jan 2021 08:19 #194192 by phillc54
Replied by phillc54 on topic File Manager Header Colors
Try this:

#filemanager QTableView {
alternate-background-color: red }

Please Log in or Create an account to join the conversation.

More
06 Jan 2021 16:15 #194241 by persei8
Replied by persei8 on topic File Manager Header Colors
Thanks, but what I meant was I want alternating row colors turned completely off. The way to do it is to insert the following in the handler file, generally in a section responsible for initializing widgets.
        self.w.filemanager.list.setAlternatingRowColors(False)
        self.w.filemanager.table.setAlternatingRowColors(False)

Where self.w.filemanager is the object name of the filemanager widget inserted into the ui file.
Jim

Please Log in or Create an account to join the conversation.

More
06 Jan 2021 16:54 #194250 by cmorley
Replied by cmorley on topic File Manager Header Colors
should be a Qstyle way to do this too - I'll look later

Please Log in or Create an account to join the conversation.

More
07 Jan 2021 00:27 #194313 by cmorley
Replied by cmorley on topic File Manager Header Colors
This works in the stylesheet too:
QTableView{
qproperty-alternatingRowColors : false
}
The following user(s) said Thank You: phillc54, persei8

Please Log in or Create an account to join the conversation.

Moderators: cmorley
Time to create page: 0.102 seconds
Powered by Kunena Forum