Closed JohnAD closed 3 months ago
Here is the code I used to test this. It's a tiny standalone Python app with the theme cut & pasted and the dialog in a .ui
file.
I also see it in the FreeCAD proper, but FreeCAD probably is doing other stuff with the theming, so I doubt it exactly matches. So, this example is really only for showing the disabled
formatting.
PlainTextEdit and TextLabel don't appear to be used in FreeCAD anywhere and aren't even defined in my stylesheet. I can add them if you need to use them, but there should be comparable alternative widgets to use instead.
Oh, for the file main.py
you will want to uncomment lines 10 to 12 to turn on the theme.
TextLabel == QLabel . I should have used different text on that one.
looks great! thanks.
For the input and label elements commonly used with forms, visually distinguishing enabled vs disabled state would be very useful.
To give an example, I added all those items to a dialog:
The enabled items are on the left. The same items disabled are on the right.
For comparison, the same dialog with no theme added: