comparison main/main.cpp @ 253:6a6b5a1a6c67

* Speed up spectrogram painting by releasing mutex in FFTDataServer while calculating data prior to writing it, and by adding whole-column value query methods to FFT objects * Add paint cache to Thumbwheel -- repaints of this widget were slowing down the whole spectrogram repaint * More uses of MutexLocker (named and with debug) and more profile points * Make startup much quicker some of the time, with OSC server in place
author Chris Cannam
date Thu, 08 May 2008 14:46:22 +0000
parents f88cb5bc5142
children c452d8a7b770
comparison
equal deleted inserted replaced
252:f88cb5bc5142 253:6a6b5a1a6c67
257 257
258 QString language = QLocale::system().name(); 258 QString language = QLocale::system().name();
259 259
260 QTranslator qtTranslator; 260 QTranslator qtTranslator;
261 QString qtTrName = QString("qt_%1").arg(language); 261 QString qtTrName = QString("qt_%1").arg(language);
262 std::cerr << "Loading " << qtTrName.toStdString() << "..." << std::endl; 262 std::cerr << "Loading " << qtTrName.toStdString() << "... ";
263 bool success = false; 263 bool success = false;
264 if (!(success = qtTranslator.load(qtTrName))) { 264 if (!(success = qtTranslator.load(qtTrName))) {
265 QString qtDir = getenv("QTDIR"); 265 QString qtDir = getenv("QTDIR");
266 if (qtDir != "") { 266 if (qtDir != "") {
267 success = qtTranslator.load 267 success = qtTranslator.load
268 (qtTrName, QDir(qtDir).filePath("translations")); 268 (qtTrName, QDir(qtDir).filePath("translations"));
269 } 269 }
270 } 270 }
271 if (!success) { 271 if (!success) {
272 std::cerr << "Failed to load Qt translation for locale" << std::endl; 272 std::cerr << "Failed\nFailed to load Qt translation for locale" << std::endl;
273 } else {
274 std::cerr << "Done" << std::endl;
273 } 275 }
274 application.installTranslator(&qtTranslator); 276 application.installTranslator(&qtTranslator);
275 277
276 QTranslator svTranslator; 278 QTranslator svTranslator;
277 QString svTrName = QString("sonic-visualiser_%1").arg(language); 279 QString svTrName = QString("sonic-visualiser_%1").arg(language);
278 std::cerr << "Loading " << svTrName.toStdString() << "..." << std::endl; 280 std::cerr << "Loading " << svTrName.toStdString() << "... ";
279 svTranslator.load(svTrName, ":i18n"); 281 svTranslator.load(svTrName, ":i18n");
282 std::cerr << "Done" << std::endl;
280 application.installTranslator(&svTranslator); 283 application.installTranslator(&svTranslator);
281 284
282 StoreStartupLocale(); 285 StoreStartupLocale();
283 286
284 // Permit size_t and PropertyName to be used as args in queued signal calls 287 // Permit size_t and PropertyName to be used as args in queued signal calls