56 #include <common/glew_wrappers.hh> 72 #include <sys/types.h> 73 #include <sys/sysctl.h> 78 #define GPU_MEMORY_INFO_TOTAL_AVAILABLE_MEMORY_NVX 0x9048 79 #define GPU_MEMORY_INFO_CURRENT_AVAILABLE_VIDMEM_NVX 0x9049 89 if ( OpenFlipper::Options::nogui() )
99 QTextEdit* tmp =
new QTextEdit();
100 tmp->insertHtml( it.value() );
101 tmp->setReadOnly(
true);
110 QFont standardFont =
aboutWidget_->OpenFlipperAbout->currentFont();
111 QFont boldFont = standardFont;
112 boldFont.setBold(
true);
114 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
115 aboutWidget_->OpenFlipperAbout->append(tr(
"%1 Core Version: %2",
"PRODUCT_NAME Core Version:").arg(
TOSTRING(PRODUCT_NAME)).arg(OpenFlipper::Options::coreVersion()) ) ;
116 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
122 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
124 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
127 QDir tempDir = QDir(OpenFlipper::Options::applicationDir());
128 #ifdef OPENFLIPPER_DATADIR 129 tempDir.cd(OPENFLIPPER_DATADIR);
131 aboutWidget_->OpenFlipperAbout->append(
"Data:\t " + tempDir.absolutePath() );
132 aboutWidget_->OpenFlipperAbout->append(
"Shaders:\t " + OpenFlipper::Options::shaderDirStr() );
133 aboutWidget_->OpenFlipperAbout->append(
"Textures:\t " + OpenFlipper::Options::textureDirStr() );
134 aboutWidget_->OpenFlipperAbout->append(
"Scripts:\t " + OpenFlipper::Options::scriptDirStr() );
135 aboutWidget_->OpenFlipperAbout->append(
"Icons:\t " + OpenFlipper::Options::iconDirStr() );
136 aboutWidget_->OpenFlipperAbout->append(
"Fonts:\t" + OpenFlipper::Options::fontsDirStr() );
137 aboutWidget_->OpenFlipperAbout->append(
"Help:\t" + OpenFlipper::Options::helpDirStr() );
144 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
145 aboutWidget_->OpenFlipperAbout->append(tr(
"%1 configuration files:").arg(
TOSTRING(PRODUCT_NAME)));
146 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
148 aboutWidget_->OpenFlipperAbout->append(tr(
"ConfigDir:\t\t\t") + OpenFlipper::Options::configDirStr() );
149 aboutWidget_->OpenFlipperAbout->append(tr(
"Window states:\t\t") + OpenFlipper::Options::configDirStr() + OpenFlipper::Options::dirSeparator() +
"WindowStates.dat");
152 aboutWidget_->OpenFlipperAbout->append(tr(
"Additional option files:"));
153 for (
int i = 0 ; i < OpenFlipper::Options::optionFiles().size() ; ++i)
154 aboutWidget_->OpenFlipperAbout->append(OpenFlipper::Options::optionFiles()[i]);
163 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
164 aboutWidget_->OpenFlipperAbout->append(tr(
"Memory Information:"));
165 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
173 ms.dwLength =
sizeof (ms);
176 GlobalMemoryStatusEx(&ms);
179 aboutWidget_->OpenFlipperAbout->append(tr(
"Physical Memory:\t")+ QString::number(ms.ullAvailPhys/1024/1024) +
"MB/"+
180 QString::number(ms.ullTotalPhys/1024/1024) +
"MB free ("+
181 QString::number(ms.dwMemoryLoad) +
"%)");
182 aboutWidget_->OpenFlipperAbout->append(tr(
"Pagefile Memory:\t")+ QString::number(ms.ullAvailPageFile/1024/1024) +
"MB/" 183 + QString::number(ms.ullTotalPageFile/1024/1024) +
"MB free");
186 #elif defined ARCH_DARWIN 188 aboutWidget_->OpenFlipperAbout->append(tr(
"Not available for this platform (MacOS)"));
192 unsigned long memory = 0;
194 struct mallinfo info;
198 memory += info.hblkhd;
201 memory += info.uordblks;
203 double mmapAllocated = double(info.hblkhd ) / 1024 / 1024;
204 double sbrkAllocated = double(info.uordblks) / 1024 / 1024;
205 double totalAllocated = double(memory) / 1024 / 1024;
207 double pageSize = double(getpagesize()) /1024 ;
208 double availablePages = double( sysconf (_SC_AVPHYS_PAGES) );
209 double freeMem = availablePages * pageSize / 1024;
211 aboutWidget_->OpenFlipperAbout->append(tr(
"Total Memory allocated:\t ") + QString::number(totalAllocated,
'f' ,2 ) + tr(
"MB ")
212 + tr(
"( mmap: ") + QString::number(mmapAllocated ,
'f' ,2 ) + tr(
"MB")
213 + tr(
", sbrk: ") + QString::number(sbrkAllocated ,
'f' ,2 ) + tr(
"MB )") );
215 aboutWidget_->OpenFlipperAbout->append(tr(
"Free Memory:\t\t ") + QString::number(freeMem,
'f' ,2 ) + tr(
"MB ")
216 + tr(
"(") + QString::number(availablePages,
'f' ,0 ) + tr(
" pages of ")
217 + QString::number(pageSize,
'f' ,2 ) + tr(
"KB size)"));
225 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
226 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU Information:"));
227 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
231 QSettings registryCPU(
"HKEY_LOCAL_MACHINE\\HARDWARE\\DESCRIPTION\\System\\CentralProcessor", QSettings::NativeFormat);
233 QStringList cpus = registryCPU.childGroups();
234 if ( cpus.size() != 0 ) {
236 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU vendor:\t\t ") +
237 registryCPU.value( cpus[0]+
"/VendorIdentifier",
"Unknown" ).toString() );
238 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU model:\t\t ") +
239 registryCPU.value( cpus[0]+
"/ProcessorNameString",
"Unknown" ).toString() );
240 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU identifier:\t\t ") +
241 registryCPU.value( cpus[0]+
"/Identifier",
"Unknown" ).toString() );
242 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU Speed:\t\t ") +
243 registryCPU.value( cpus[0]+
"/~MHz",
"Unknown" ).toString()+
" MHz" );
245 aboutWidget_->OpenFlipperAbout->append(
"CPU Cores:\t\t " + QString::number(cpus.size()));
248 aboutWidget_->OpenFlipperAbout->append(tr(
"Unable to retrieve CPU information"));
251 #elif defined ARCH_DARWIN 258 sysctlbyname(
"machdep.cpu.brand_string", NULL, &lenCPU, NULL, 0);
261 pCPU = (
char * )malloc(lenCPU);
264 sysctlbyname(
"machdep.cpu.brand_string", pCPU, &lenCPU, NULL, 0);
267 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU Brand:\t\t ") + QString(pCPU) );
272 int physicalCPUS = 0;
275 lenCPU =
sizeof(int);
276 sysctlbyname(
"hw.physicalcpu", &physicalCPUS, &lenCPU , NULL, 0);
279 aboutWidget_->OpenFlipperAbout->append(tr(
"Physical Cores:\t\t ") + QString::number(physicalCPUS) );
284 lenCPU =
sizeof(int);
285 sysctlbyname(
"hw.logicalcpu", &logicalCPUS, &lenCPU, NULL, 0);
288 aboutWidget_->OpenFlipperAbout->append(tr(
"LogicalCores:\t\t ") + QString::number(logicalCPUS) );
291 QFile cpuinfo(
"/proc/cpuinfo");
292 if (! cpuinfo.exists() )
293 aboutWidget_->OpenFlipperAbout->append(tr(
"Unable to retrieve CPU information"));
296 cpuinfo.open(QFile::ReadOnly);
297 QTextStream stream(&cpuinfo);
299 #if QT_VERSION < QT_VERSION_CHECK(5, 14, 0) 300 QStringList splitted = stream.readAll().split(
"\n",QString::SkipEmptyParts);
302 QStringList splitted = stream.readAll().split(
"\n",Qt::SkipEmptyParts);
306 int position = splitted.indexOf ( QRegExp(
"^vendor_id.*") );
307 if ( position != -1 ){
308 QString cpuVendor = splitted[position].section(
':', -1).simplified();
309 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU vendor:\t\t ") + cpuVendor );
311 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU vendor:\t\t vendor specification not found"));
314 position = splitted.indexOf ( QRegExp(
"^model name.*") );
315 if ( position != -1 ){
316 QString cpuModel = splitted[position].section(
':', -1).simplified();
317 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU model:\t\t ") + cpuModel );
319 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU model:\t\t Model specification not found"));
322 position = splitted.indexOf ( QRegExp(
"^cpu cores.*") );
323 if ( position != -1 ){
324 QString cpuCoresPhysical = splitted[position].section(
':', -1).simplified();
325 aboutWidget_->OpenFlipperAbout->append(tr(
"Physical CPU cores:\t\t ") + cpuCoresPhysical );
327 aboutWidget_->OpenFlipperAbout->append(tr(
"Physical CPU cores:\t\t CPU Core specification not found"));
330 position = splitted.indexOf ( QRegExp(
"^siblings.*") );
331 if ( position != -1 ){
332 QString cpuCoresLogical = splitted[position].section(
':', -1).simplified();
333 aboutWidget_->OpenFlipperAbout->append(tr(
"Logical CPU cores:\t\t ") + cpuCoresLogical );
335 aboutWidget_->OpenFlipperAbout->append(tr(
"Logical CPU cores:\t\t CPU Core specification not found"));
338 position = splitted.indexOf ( QRegExp(
"^flags.*") );
339 if ( position != -1 ){
340 QString cpuFlags = splitted[position].section(
':', -1).simplified();
341 aboutWidget_->OpenFlipperAbout->append( tr(
"CPU capabilities:") );
344 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU capabilities:\t\t CPU flag specification not found"));
347 #if Q_BYTE_ORDER == Q_BIG_ENDIAN 348 aboutWidget_->OpenFlipperAbout->append(tr(
"System is Big Endian"));
351 #if Q_BYTE_ORDER == Q_LITTLE_ENDIAN 352 aboutWidget_->OpenFlipperAbout->append(tr(
"System is Little Endian"));
363 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
364 aboutWidget_->OpenFlipperAbout->append(tr(
"Operating System Info:"));
365 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
368 QSettings registryOS(
"HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion", QSettings::NativeFormat);
369 aboutWidget_->OpenFlipperAbout->append(tr(
"Product Name:\t\t ") +
370 registryOS.value(
"ProductName",
"Unknown" ).toString() );
371 aboutWidget_->OpenFlipperAbout->append(tr(
"Current Version:\t\t ") +
372 registryOS.value(
"CurrentVersion",
"Unknown" ).toString() );
373 #elif defined ARCH_DARWIN 380 mib[1] = KERN_VERSION;
382 sysctl(mib, 2, NULL, &len, NULL, 0);
383 p = (
char * )malloc(len);
384 sysctl(mib, 2, p, &len, NULL, 0);
386 aboutWidget_->OpenFlipperAbout->append(tr(
"OS Version:\t\t ") + QString(p) );
391 QFile versionInfo(
"/proc/version");
392 if (! versionInfo.exists() )
393 aboutWidget_->OpenFlipperAbout->append(tr(
"Unable to retrieve Kernel information"));
395 versionInfo.open(QFile::ReadOnly);
396 QTextStream versionStream(&versionInfo);
397 aboutWidget_->OpenFlipperAbout->append(tr(
"Kernel Version:\t\t ") + versionStream.readAll().simplified());
399 QString program =
"/usr/bin/lsb_release";
402 if ( lsb.exists() ) {
403 QStringList arguments;
407 myProcess.start(program, arguments);
409 if ( myProcess.waitForFinished ( 4000 ) ) {
410 QStringList outputLSB = QString(myProcess.readAllStandardOutput()).split(
'\n');
413 int position = outputLSB.indexOf ( QRegExp(
"^Distributor ID.*") );
414 if ( position != -1 ){
415 QString distributorID = outputLSB[position].section(
':', -1).simplified();
416 aboutWidget_->OpenFlipperAbout->append(tr(
"Distributor ID:\t\t ") + distributorID );
418 aboutWidget_->OpenFlipperAbout->append(tr(
"Distributor ID:\t\t Unknown"));
421 position = outputLSB.indexOf ( QRegExp(
"^Description.*") );
422 if ( position != -1 ){
423 QString description = outputLSB[position].section(
':', -1).simplified();
424 aboutWidget_->OpenFlipperAbout->append(tr(
"Description:\t\t ") + description );
426 aboutWidget_->OpenFlipperAbout->append(tr(
"Description:\t\t Unknown"));
429 position = outputLSB.indexOf ( QRegExp(
"^Release.*") );
430 if ( position != -1 ){
431 QString release = outputLSB[position].section(
':', -1).simplified();
432 aboutWidget_->OpenFlipperAbout->append(tr(
"Release number:\t\t ") + release );
434 aboutWidget_->OpenFlipperAbout->append(tr(
"Release number:\t\t Unknown"));
437 position = outputLSB.indexOf ( QRegExp(
"^Codename.*") );
438 if ( position != -1 ){
439 QString codename = outputLSB[position].section(
':', -1).simplified();
440 aboutWidget_->OpenFlipperAbout->append(tr(
"Codename:\t\t ") + codename );
442 aboutWidget_->OpenFlipperAbout->append(tr(
"Codename:\t\t Unknown"));
446 aboutWidget_->OpenFlipperAbout->append(tr(
"Unable to get LSB info"));
450 aboutWidget_->OpenFlipperAbout->append(tr(
"No additional information. Unable to get info via LSB."));
456 QString systemPathVariable = getenv(
"PATH");
457 aboutWidget_->OpenFlipperAbout->append(tr(
"System Path:\n ") + systemPathVariable);
460 QString systemLibraryPathVariable = getenv(
"LD_LIBRARY_PATH");
461 aboutWidget_->OpenFlipperAbout->append(tr(
"LD_LIBRARY_PATH:\n ") + systemLibraryPathVariable);
470 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
471 aboutWidget_->OpenFlipperAbout->append(tr(
"OpenGL Specific Info:"));
472 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
474 QString vendor = QString((
const char*)glGetString(GL_VENDOR));
475 aboutWidget_->OpenFlipperAbout->append(tr(
"Qt reports Vendor:\t\t") + vendor);
476 QString renderer = QString((
const char*)glGetString(GL_RENDERER));
477 aboutWidget_->OpenFlipperAbout->append(tr(
"Qt reports Renderer:\t\t") + renderer);
479 QGLFormat::OpenGLVersionFlags flags = QGLFormat::openGLVersionFlags();
481 QString openGLQtVersion = tr(
"Qt reports Version:\t\t");
483 if ( flags.testFlag(QGLFormat::OpenGL_Version_4_0) )
484 openGLQtVersion += tr(
"4.0 or higher") ;
485 else if (flags.testFlag(QGLFormat::OpenGL_Version_3_3))
486 openGLQtVersion += tr(
"3.3") ;
487 else if (flags.testFlag(QGLFormat::OpenGL_Version_3_2))
488 openGLQtVersion += tr(
"3.2") ;
489 else if (flags.testFlag(QGLFormat::OpenGL_Version_3_1))
490 openGLQtVersion += tr(
"3.1") ;
491 else if (flags.testFlag(QGLFormat::OpenGL_Version_3_0))
492 openGLQtVersion += tr(
"3.0") ;
493 else if (flags.testFlag(QGLFormat::OpenGL_Version_2_1))
494 openGLQtVersion += tr(
"2.1" );
495 else if (flags.testFlag(QGLFormat::OpenGL_Version_2_0))
496 openGLQtVersion += tr(
"2.0" );
497 else if (flags.testFlag(QGLFormat::OpenGL_Version_1_5))
498 openGLQtVersion += tr(
"1.5" );
499 else if (flags.testFlag(QGLFormat::OpenGL_Version_1_4))
500 openGLQtVersion += tr(
"1.4" );
501 else if (flags.testFlag(QGLFormat::OpenGL_Version_1_3))
502 openGLQtVersion += tr(
"1.3" );
503 else if (flags.testFlag(QGLFormat::OpenGL_Version_1_2))
504 openGLQtVersion += tr(
"1.2" );
505 else if (flags.testFlag(QGLFormat::OpenGL_Version_1_1))
506 openGLQtVersion += tr(
"1.1" );
508 openGLQtVersion += tr(
"Version:\tUNKNOWN!" );
510 aboutWidget_->OpenFlipperAbout->append(openGLQtVersion);
514 const QGLContext* context = QGLContext::currentContext();
516 QString openGLprofile = tr(
"Qt reports the OpenGL profile:\t");
517 QGLFormat::OpenGLContextProfile profile = context->format().profile();
518 if (profile == QGLFormat::NoProfile)
519 openGLprofile += tr(
"no profile");
520 else if (profile == QGLFormat::CoreProfile)
521 openGLprofile += tr(
"Core profile");
522 else if (profile == QGLFormat::CompatibilityProfile)
523 openGLprofile += tr(
"Compatibility profile");
525 openGLprofile += tr(
"unknown profile");
532 QString openGLVendor = tr(
"GL reports Vendor:\t\t");
533 openGLVendor += QString((
const char*)glGetString(GL_VENDOR));
536 QString openGLRenderer = tr(
"GL reports Renderer:\t\t");
537 openGLRenderer += QString((
const char*)glGetString(GL_RENDERER));
540 QString openGLGLVersion = tr(
"GL reports Version:\t\t");
541 openGLGLVersion += QString((
const char*)glGetString(GL_VERSION));
542 aboutWidget_->OpenFlipperAbout->append(openGLGLVersion);
544 QString openGLShadingLanguageVersion = tr(
"GL reports Shading Language Version:\t");
545 openGLShadingLanguageVersion += QString((
const char*)glGetString(GL_SHADING_LANGUAGE_VERSION));
546 aboutWidget_->OpenFlipperAbout->append(openGLShadingLanguageVersion);
553 aboutWidget_->OpenFlipperAbout->append(tr(
"Supported Extensions:"));
562 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
563 aboutWidget_->OpenFlipperAbout->append(tr(
"OpenGL Values:"));
564 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
566 glGetIntegerv(GL_MAX_VIEWPORT_DIMS, &getBuffer[0] );
567 aboutWidget_->OpenFlipperAbout->append(tr(
"Maximal Viewport size(GL_MAX_VIEWPORT_DIMS):\t\t\t\t ") + QString::number(getBuffer[0]) +
"x" + QString::number(getBuffer[1]) );
569 glGetIntegerv(GL_MAX_TEXTURE_IMAGE_UNITS, &getBuffer[0] );
570 aboutWidget_->OpenFlipperAbout->append(tr(
"Maximum supported texture image units(GL_MAX_TEXTURE_IMAGE_UNITS):\t") + QString::number(getBuffer[0]) );
573 if ( glExtensions.contains(
"GL_NVX_gpu_memory_info") ) {
575 GLint total_mem_kb = 0;
576 glGetIntegerv(GPU_MEMORY_INFO_TOTAL_AVAILABLE_MEMORY_NVX, &total_mem_kb);
578 aboutWidget_->OpenFlipperAbout->append(tr(
"GPU Memory (Total available):\t\t") + QString::number(total_mem_kb /1024) +
" MB" );
581 GLint cur_avail_mem_kb = 0;
582 glGetIntegerv(GPU_MEMORY_INFO_CURRENT_AVAILABLE_VIDMEM_NVX, &cur_avail_mem_kb);
584 aboutWidget_->OpenFlipperAbout->append(tr(
"GPU Memory (Currently available):\t") + QString::number(cur_avail_mem_kb / 1024) +
" MB" );
589 aboutWidget_->OpenFlipperAbout->moveCursor(QTextCursor::Start);
596 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
597 aboutWidget_->OpenFlipperAbout->append(tr(
"GLEW Specific Info:"));
598 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
600 QString glewVersion = QString(getGlewVersion());
601 aboutWidget_->OpenFlipperAbout->append(tr(
"GLEW Version:\t") + glewVersion);
609 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
610 aboutWidget_->OpenFlipperAbout->append(tr(
"Qt Version Info:"));
611 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
612 aboutWidget_->OpenFlipperAbout->append(tr(
"Currently used Version:\t") + qVersion() );
613 aboutWidget_->OpenFlipperAbout->append(tr(
"Link time Version:\t\t") + QT_VERSION_STR );
615 QList<QByteArray> imageFormats = QImageReader::supportedImageFormats();
616 QString formatsString =
"";
617 for (
int i = 0 ; i < imageFormats.size() ; ++i) {
618 formatsString += imageFormats[i] +
" ";
620 if ( (i != 0) && (i % 15) == 0 )
621 formatsString+=
"\n";
624 aboutWidget_->OpenFlipperAbout->append(tr(
"Supported image read formats:") );
629 aboutWidget_->OpenFlipperAbout->append(tr(
"Currently used Library paths:") );
630 QStringList libPaths = QCoreApplication::libraryPaths();
631 for(
int i = 0 ; i < libPaths.size() ; ++i)
632 aboutWidget_->OpenFlipperAbout->append(
" " + libPaths[i]);
655 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
656 aboutWidget_->OpenFlipperAbout->append(tr(
"Compiler Info:"));
657 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
658 aboutWidget_->OpenFlipperAbout->append( OpenFlipper::Options::compilerInfo() );
664 definitions +=
"WIN32 ";
668 definitions +=
"WIN64 ";
672 definitions +=
"DLL ";
677 definitions +=
"APPLE ";
681 definitions +=
"ARCH_DARWIN ";
684 #ifdef INCLUDE_TEMPLATES 685 definitions +=
"INCLUDE_TEMPLATES ";
689 definitions +=
"DEBUG ";
693 definitions +=
"NDEBUG ";
697 definitions +=
"QT_NO_OPENGL ";
701 definitions +=
"OPENMP ";
705 definitions +=
"USE_OPENMP ";
708 aboutWidget_->OpenFlipperAbout->append( tr(
"Definitions (incomplete):\n") + definitions );
714 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
715 aboutWidget_->OpenFlipperAbout->append(tr(
"Registered data types:"));
716 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
724 for ( uint i = 0 ; i <
typeCount() - 2 ; ++i) {
725 types +=
typeName( currentType ) +
"\t\t typeId: " + QString::number(currentType.
value()) +
"\n";
737 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
738 aboutWidget_->OpenFlipperAbout->append(tr(
"Registered File Plugins:"));
739 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
741 for ( uint i = 0 ; i < supportedTypes().size() ; ++i ) {
742 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
743 aboutWidget_->OpenFlipperAbout->append(
"\t" + supportedTypes()[i].name );
744 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
745 aboutWidget_->OpenFlipperAbout->append(
"\t\t Load: " + supportedTypes()[i].loadFilters );
746 aboutWidget_->OpenFlipperAbout->append(
"\t\t Save: " + supportedTypes()[i].saveFilters );
754 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
755 aboutWidget_->OpenFlipperAbout->append(tr(
"Loaded Plugins:"));
756 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
758 for ( uint i = 0 ; i <
plugins().size() ; ++i ) {
759 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
761 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
763 aboutWidget_->OpenFlipperAbout->append(
"\t\t Description: \t" +
plugins()[i].description );
766 if ( !
plugins()[i].warnings.isEmpty() ) {
767 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::darkYellow);
769 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::black);
772 if ( !
plugins()[i].errors.isEmpty() ) {
773 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::darkRed);
775 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::black);
783 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
784 aboutWidget_->OpenFlipperAbout->append(tr(
"Failed Plugins:"));
785 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
787 for (
unsigned i = 0 ; i < PluginStorage::pluginsFailed().size() ; ++i ) {
788 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
789 aboutWidget_->OpenFlipperAbout->append(
"\t" + PluginStorage::pluginsFailed()[i].name );
790 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
791 aboutWidget_->OpenFlipperAbout->append(
"\t\t Version: \t\t" + PluginStorage::pluginsFailed()[i].version );
792 aboutWidget_->OpenFlipperAbout->append(
"\t\t Description: \t" + PluginStorage::pluginsFailed()[i].description );
793 aboutWidget_->OpenFlipperAbout->append(
"\t\t Path \t\t" + PluginStorage::pluginsFailed()[i].path );
795 if ( !PluginStorage::pluginsFailed()[i].warnings.isEmpty() ) {
796 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::darkYellow);
797 aboutWidget_->OpenFlipperAbout->append(
"\t\t Warnings: \t\t" + PluginStorage::pluginsFailed()[i].warnings );
798 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::black);
801 if ( !PluginStorage::pluginsFailed()[i].errors.isEmpty() ) {
802 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::darkRed);
803 aboutWidget_->OpenFlipperAbout->append(
"\t\t Errors: \t\t" + PluginStorage::pluginsFailed()[i].errors );
804 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::black);
817 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
818 aboutWidget_->OpenFlipperAbout->append(tr(
"Currently loaded Resources (e.g. by qrc files):"));
819 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
821 QDir toplevelResources(
":/");
822 for (
auto str : toplevelResources.entryList() ) {
825 QDir firstLevel(
":/" + str);
826 for (
auto firstLevelStr : firstLevel.entryList() ) {
827 aboutWidget_->OpenFlipperAbout->append(
" \t" + firstLevelStr);
829 QDir secondLevel(
":/" + str +
"/" + firstLevelStr);
831 for (
auto secondLevelStr : secondLevel.entryList() ) {
832 aboutWidget_->OpenFlipperAbout->append(
" \t\t" + secondLevelStr);
DLLEXPORT size_t typeCount()
Get the number of registered types.
unsigned int value() const
DLLEXPORT QString typeName(DataType _id)
Get the name of a type with given id.
#define TOSTRING(x)
QSettings object containing all program settings of OpenFlipper.
DLLEXPORT OpenFlipperQSettings & OpenFlipperSettings()
QSettings object containing all program settings of OpenFlipper.
std::string getExtensionString()
getExtensionString returns a string containing all supported OpenGL extensions this function uses the...