Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Active container (light gray) and edit (yellow) colors in Tree view a…
…re now changeable in prefs->display->colors
- Loading branch information
1 parent
869b5c8
commit 10e33d0
Showing
3 changed files
with
269 additions
and
215 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
10e33d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi Yorik,
IMHO these colors might be controled by default by the stylesheets and, if user wants to, set a new one. Not only background colors but also the text color itself...
Could you make them "reachable" by stylesheets with an ID or something similar?
Thanks!
10e33d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, but I don't know what needs to be done for that... I can investigate, but if you know the answer, please tell ;)
10e33d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's pretty easy: I just need you to "mark" the active text with an ID and tell me what kind of Qt object it is.
For example: it's a QLineText and the unique ID is #ActiveObject, then I create a line in the stylesheet like the following:
QLineText#ActiveObject { color: red }
Anyway, maybe the more flexible setup would be to let the stylesheet to style it as I have just suggested but let the user override this default in the FC Preferences so that they can change it if they want a different one...
10e33d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok the problem is this: that widget is a QTreeViewItem. It has no background color normally. So I think what we need to do, is to add a class ID to it at the same time that we change its color, and remove that class ID when we set it back to normal. I'll have a look at how to do that...
10e33d0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Other approach would be to keep the ID always added to the class and on the default option (no background color) write it as rgba(0,0,0,0) which adds the RGB color (any) and the alpha value to 0 which is 100% transparent.
Do you think this could work?