Skip to content
Browse files

Avoid crash when setting application font/font size in options dialog causes a segfault
in Qt >= 5.11 if we change the stylesheet on the fly.

Workaround this by only setting the stylesheet once at startup,
and require a restart if settings change which modify the

Just a workaround -- the upstream bug is being looked at,
but better to require a restart than crash.
  • Loading branch information
nyalldawson committed Oct 23, 2018
1 parent 4f43282 commit ac44bf2514b12b8689777673793977ee3b5a8fd3
Showing with 8 additions and 0 deletions.
  1. +8 −0 src/app/qgisapp.cpp
@@ -2403,6 +2403,14 @@ void QgisApp::createActionGroups()

void QgisApp::setAppStyleSheet( const QString &stylesheet )
// avoid crash on stylesheet change -- see
static bool sOnce = false;
if ( sOnce )
sOnce = true;

setStyleSheet( stylesheet );

// cascade styles to any current layout designers

0 comments on commit ac44bf2

Please sign in to comment.
You can’t perform that action at this time.