[Kst] extragear/graphics/kst/kst

George Staikos staikos at kde.org
Fri Oct 7 20:19:51 CEST 2005


SVN commit 468334 by staikos:

another 11% or better increase in startup time by delaying font checks


 M  +9 -8      kst.cpp  


--- trunk/extragear/graphics/kst/kst/kst.cpp #468333:468334
@@ -211,13 +211,6 @@
 
   QTimer::singleShot(0, this, SLOT(updateActions()));
 
-  checkFontPresent("Symbol");
-  checkFontPresent("Helvetica");
-
-  QFont defaultFont; // QT's current default font
-  QFontInfo info(defaultFont);
-  _defaultFont = info.family();
-
   if (!isFakingSDIApplication()) {
     bool addedWindowMenu = false;
     int menuCount = menuBar()->count();
@@ -238,7 +231,6 @@
     }
     connect(windowMenu(), SIGNAL(aboutToShow()), this, SLOT(addNewWindowMenu()));
   }
-  QTimer::singleShot(0, this, SLOT(loadExtensions()));
 }
 
 
@@ -282,6 +274,14 @@
   // Initialise the plugin loader and collection first.
   PluginCollection::self();
 
+  // Do font checks after startup
+  checkFontPresent("Symbol");
+  checkFontPresent("Helvetica");
+
+  QFont defaultFont; // QT's current default font
+  QFontInfo info(defaultFont);
+  _defaultFont = info.family();
+
   ExtensionMgr *mgr = ExtensionMgr::self();
   mgr->setWindow(this);
   KService::List sl = KServiceType::offers("Kst Extension");
@@ -365,6 +365,7 @@
 void KstApp::updateActions() {
   // Hack
   StatusBarAction->setChecked(statusBar()->isShown());
+  QTimer::singleShot(0, this, SLOT(loadExtensions()));
 }
 
 


More information about the Kst mailing list