-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix crash due to style cache issue in QT<5.12.4. Fixes #39693 #39725 #39615 #39935
Conversation
c6c66e3
to
6080c15
Compare
Thanks @luipir for all the efforts. |
b84a1ef
to
6b816bf
Compare
some squash to clean commits |
@@ -130,6 +130,7 @@ class GUI_EXPORT QgsCollapsibleGroupBoxBasic : public QGroupBox | |||
void checkToggled( bool ckd ); | |||
void checkClicked( bool ckd ); | |||
void toggleCollapsed(); | |||
void setStyleSheet( const QString &style ); |
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.
Just add docs, don't expand the missing doc list!
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.
I followed the same as the other overloaded slots because the documentation I suppose is based on base class documentation. BTW I'll add doc.
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.
added
I'm a little confused how this fix works -- QWidget::setStyleSheet isn't virtual, so how does this intercept all attempts to set the group box style? |
is it done calling parent setStyleSheet? or do you mean to move the fix to upper levels? |
this won't intercept all attempts, just those done by this class. Perhaps the method should be internalSetStyleSheet() to avoid any confusion ? |
well.. @nyalldawson I'm confused too about why the crash happen always in the same class and does not affect the other call to setStyleSheet (175) all over the qgis code. |
because the crash happen only with this class, I prefered to leave the same method name to avoid to call setStyleSheet falling again in a crash. |
cb892a9
to
d406cfa
Compare
d406cfa
to
e360378
Compare
Should we also backport to 3.10 to be extra safe? |
Sure. |
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.
Let's get this into 3.16 so we can ship a crash free version asap.
Code looks good. The documentation could be improved but we can do that in a follow up PR.
@msevilla00 , that build is too old. |
@msevilla00 last commit included in your build is from 5 days ago. |
Ok, thanks, I did apt update & upgrade and changed... I thought included the latest fix. I'll try with the other repos. Cheers |
Fix crash due to style cache issue in QT<5.12.4. Fixes #39693 #39725 #39615
No tests available :/
workaround to QT bug https://bugreports.qt.io/browse/QTBUG-69204
Partially sponsored by QGIS Spanish User Group qgis.es