Made ::paint(...) member function work more like QT5.5's QItemDelegate::paint(...)
Specifically, draws QIcon instead of Pixmap when appropriate.
Refs T664
mwolff | |
kfunk |
Made ::paint(...) member function work more like QT5.5's QItemDelegate::paint(...)
Specifically, draws QIcon instead of Pixmap when appropriate.
Refs T664
Project view's decorations should be in same place in HiDPI mode.
Tested on OSX:
Before |
After |
After with project colouring |
Automatic diff as part of commit; lint not applicable. |
Automatic diff as part of commit; unit tests not applicable. |
this smells like a bug in Qt to me, what Qt version are you using? In general, certainly unexpected and should also be fixed upstream.
I have little knowledge of this code, but imo we can merge it for now. But do please add a comment around your new code, and/or extract it into a separate function, to make it clear that this is a workaround.
plugins/projectmanagerview/projectmodelitemdelegate.cpp | ||
---|---|---|
34 | please follow our style and join this line with the next | |
37 | same here: } else { return QIcon::Normal; } | |
43 | join into a single line please | |
65 | join | |
69 | join | |
105 | join |
@mwolff
This was originally developed against Qt5.5.0, however now has been tested against Qt5.5.1
I hope this patch is correct style wise.
Other details:
OSX 10.11.1 "El Capitan"
clang --version Apple LLVM version 7.0.0 (clang-700.1.76) Target: x86_64-apple-darwin15.0.0 Thread model: posix
lgtm, do you have commit rights? if so, go ahead, otherwise one of us will push this change for you.
thanks!
Oops, I think at my place of work, we have arcanist configured to squash commits.
I'll be sure do squash next time.