56#include <common/glew_wrappers.hh>
62#include <QSurfaceFormat>
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) +
"MiB/"+
180 QString::number(ms.ullTotalPhys/1024/1024) +
"MiB free ("+
181 QString::number(ms.dwMemoryLoad) +
"%)");
182 aboutWidget_->OpenFlipperAbout->append(tr(
"Pagefile Memory:\t")+ QString::number(ms.ullAvailPageFile/1024/1024) +
"MiB/"
183 + QString::number(ms.ullTotalPageFile/1024/1024) +
"MiB free");
186#elif defined __GLIBC__
188# if __GLIBC__ >= 3 || (__GLIBC__ >= 2 && __GLIBC_MINOR__ >= 33)
190 struct mallinfo2 info = ::mallinfo2();
192 struct mallinfo info = ::mallinfo();
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 (mallinfo/mallinfo2, only main arena):\t ")
212 + QString::number(totalAllocated,
'f' ,2 ) + tr(
"MiB ")
213 + tr(
"( mmap: ") + QString::number(mmapAllocated ,
'f' ,2 ) + tr(
"MiB")
214 + tr(
", sbrk: ") + QString::number(sbrkAllocated ,
'f' ,2 ) + tr(
"MiB )") );
216 aboutWidget_->OpenFlipperAbout->append(tr(
"Free Memory:\t\t ") + QString::number(freeMem,
'f' ,2 ) + tr(
"MiB ")
217 + tr(
"(") + QString::number(availablePages,
'f' ,0 ) + tr(
" pages of ")
218 + QString::number(pageSize,
'f' ,2 ) + tr(
"KiB size)"));
220#elif defined ARCH_DARWIN
221 aboutWidget_->OpenFlipperAbout->append(tr(
"Not available for this platform (MacOS)"));
223 aboutWidget_->OpenFlipperAbout->append(tr(
"Not available for this platform"));
230 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
231 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU Information:"));
232 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
236 QSettings registryCPU(
"HKEY_LOCAL_MACHINE\\HARDWARE\\DESCRIPTION\\System\\CentralProcessor", QSettings::NativeFormat);
238 QStringList cpus = registryCPU.childGroups();
239 if ( cpus.size() != 0 ) {
241 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU vendor:\t\t ") +
242 registryCPU.value( cpus[0]+
"/VendorIdentifier",
"Unknown" ).toString() );
243 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU model:\t\t ") +
244 registryCPU.value( cpus[0]+
"/ProcessorNameString",
"Unknown" ).toString() );
245 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU identifier:\t\t ") +
246 registryCPU.value( cpus[0]+
"/Identifier",
"Unknown" ).toString() );
247 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU Speed:\t\t ") +
248 registryCPU.value( cpus[0]+
"/~MHz",
"Unknown" ).toString()+
" MHz" );
250 aboutWidget_->OpenFlipperAbout->append(
"CPU Cores:\t\t " + QString::number(cpus.size()));
253 aboutWidget_->OpenFlipperAbout->append(tr(
"Unable to retrieve CPU information"));
256 #elif defined ARCH_DARWIN
263 sysctlbyname(
"machdep.cpu.brand_string", NULL, &lenCPU, NULL, 0);
266 pCPU = (
char * )malloc(lenCPU);
269 sysctlbyname(
"machdep.cpu.brand_string", pCPU, &lenCPU, NULL, 0);
272 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU Brand:\t\t ") + QString(pCPU) );
277 int physicalCPUS = 0;
280 lenCPU =
sizeof(int);
281 sysctlbyname(
"hw.physicalcpu", &physicalCPUS, &lenCPU , NULL, 0);
284 aboutWidget_->OpenFlipperAbout->append(tr(
"Physical Cores:\t\t ") + QString::number(physicalCPUS) );
289 lenCPU =
sizeof(int);
290 sysctlbyname(
"hw.logicalcpu", &logicalCPUS, &lenCPU, NULL, 0);
293 aboutWidget_->OpenFlipperAbout->append(tr(
"LogicalCores:\t\t ") + QString::number(logicalCPUS) );
296 QFile cpuinfo(
"/proc/cpuinfo");
297 if (! cpuinfo.exists() )
298 aboutWidget_->OpenFlipperAbout->append(tr(
"Unable to retrieve CPU information"));
301 cpuinfo.open(QFile::ReadOnly);
302 QTextStream stream(&cpuinfo);
304 #if QT_VERSION < QT_VERSION_CHECK(5, 14, 0)
305 QStringList splitted = stream.readAll().split(
"\n",QString::SkipEmptyParts);
307 QStringList splitted = stream.readAll().split(
"\n",Qt::SkipEmptyParts);
311 int position = splitted.indexOf ( QRegularExpression(
"^vendor_id.*") );
312 if ( position != -1 ){
313 QString cpuVendor = splitted[position].section(
':', -1).simplified();
314 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU vendor:\t\t ") + cpuVendor );
316 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU vendor:\t\t vendor specification not found"));
319 position = splitted.indexOf ( QRegularExpression(
"^model name.*") );
320 if ( position != -1 ){
321 QString cpuModel = splitted[position].section(
':', -1).simplified();
322 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU model:\t\t ") + cpuModel );
324 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU model:\t\t Model specification not found"));
327 position = splitted.indexOf ( QRegularExpression(
"^cpu cores.*") );
328 if ( position != -1 ){
329 QString cpuCoresPhysical = splitted[position].section(
':', -1).simplified();
330 aboutWidget_->OpenFlipperAbout->append(tr(
"Physical CPU cores:\t\t ") + cpuCoresPhysical );
332 aboutWidget_->OpenFlipperAbout->append(tr(
"Physical CPU cores:\t\t CPU Core specification not found"));
335 position = splitted.indexOf ( QRegularExpression(
"^siblings.*") );
336 if ( position != -1 ){
337 QString cpuCoresLogical = splitted[position].section(
':', -1).simplified();
338 aboutWidget_->OpenFlipperAbout->append(tr(
"Logical CPU cores:\t\t ") + cpuCoresLogical );
340 aboutWidget_->OpenFlipperAbout->append(tr(
"Logical CPU cores:\t\t CPU Core specification not found"));
343 position = splitted.indexOf ( QRegularExpression(
"^flags.*") );
344 if ( position != -1 ){
345 QString cpuFlags = splitted[position].section(
':', -1).simplified();
346 aboutWidget_->OpenFlipperAbout->append( tr(
"CPU capabilities:") );
349 aboutWidget_->OpenFlipperAbout->append(tr(
"CPU capabilities:\t\t CPU flag specification not found"));
352 #if Q_BYTE_ORDER == Q_BIG_ENDIAN
353 aboutWidget_->OpenFlipperAbout->append(tr(
"System is Big Endian"));
356 #if Q_BYTE_ORDER == Q_LITTLE_ENDIAN
357 aboutWidget_->OpenFlipperAbout->append(tr(
"System is Little Endian"));
368 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
369 aboutWidget_->OpenFlipperAbout->append(tr(
"Operating System Info:"));
370 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
373 QSettings registryOS(
"HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion", QSettings::NativeFormat);
374 aboutWidget_->OpenFlipperAbout->append(tr(
"Product Name:\t\t ") +
375 registryOS.value(
"ProductName",
"Unknown" ).toString() );
376 aboutWidget_->OpenFlipperAbout->append(tr(
"Current Version:\t\t ") +
377 registryOS.value(
"CurrentVersion",
"Unknown" ).toString() );
378 #elif defined ARCH_DARWIN
385 mib[1] = KERN_VERSION;
387 sysctl(mib, 2, NULL, &len, NULL, 0);
388 p = (
char * )malloc(len);
389 sysctl(mib, 2, p, &len, NULL, 0);
391 aboutWidget_->OpenFlipperAbout->append(tr(
"OS Version:\t\t ") + QString(p) );
396 QFile versionInfo(
"/proc/version");
397 if (! versionInfo.exists() )
398 aboutWidget_->OpenFlipperAbout->append(tr(
"Unable to retrieve Kernel information"));
400 versionInfo.open(QFile::ReadOnly);
401 QTextStream versionStream(&versionInfo);
402 aboutWidget_->OpenFlipperAbout->append(tr(
"Kernel Version:\t\t ") + versionStream.readAll().simplified());
404 QString program =
"/usr/bin/lsb_release";
407 if ( lsb.exists() ) {
408 QStringList arguments;
412 myProcess.start(program, arguments);
414 if ( myProcess.waitForFinished ( 4000 ) ) {
415 QStringList outputLSB = QString(myProcess.readAllStandardOutput()).split(
'\n');
418 int position = outputLSB.indexOf ( QRegularExpression(
"^Distributor ID.*") );
419 if ( position != -1 ){
420 QString distributorID = outputLSB[position].section(
':', -1).simplified();
421 aboutWidget_->OpenFlipperAbout->append(tr(
"Distributor ID:\t\t ") + distributorID );
423 aboutWidget_->OpenFlipperAbout->append(tr(
"Distributor ID:\t\t Unknown"));
426 position = outputLSB.indexOf ( QRegularExpression(
"^Description.*") );
427 if ( position != -1 ){
428 QString description = outputLSB[position].section(
':', -1).simplified();
429 aboutWidget_->OpenFlipperAbout->append(tr(
"Description:\t\t ") + description );
431 aboutWidget_->OpenFlipperAbout->append(tr(
"Description:\t\t Unknown"));
434 position = outputLSB.indexOf ( QRegularExpression(
"^Release.*") );
435 if ( position != -1 ){
436 QString release = outputLSB[position].section(
':', -1).simplified();
437 aboutWidget_->OpenFlipperAbout->append(tr(
"Release number:\t\t ") + release );
439 aboutWidget_->OpenFlipperAbout->append(tr(
"Release number:\t\t Unknown"));
442 position = outputLSB.indexOf ( QRegularExpression(
"^Codename.*") );
443 if ( position != -1 ){
444 QString codename = outputLSB[position].section(
':', -1).simplified();
445 aboutWidget_->OpenFlipperAbout->append(tr(
"Codename:\t\t ") + codename );
447 aboutWidget_->OpenFlipperAbout->append(tr(
"Codename:\t\t Unknown"));
451 aboutWidget_->OpenFlipperAbout->append(tr(
"Unable to get LSB info"));
455 aboutWidget_->OpenFlipperAbout->append(tr(
"No additional information. Unable to get info via LSB."));
461 QString systemPathVariable = getenv(
"PATH");
462 aboutWidget_->OpenFlipperAbout->append(tr(
"System Path:\n ") + systemPathVariable);
465 QString systemLibraryPathVariable = getenv(
"LD_LIBRARY_PATH");
466 aboutWidget_->OpenFlipperAbout->append(tr(
"LD_LIBRARY_PATH:\n ") + systemLibraryPathVariable);
475 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
476 aboutWidget_->OpenFlipperAbout->append(tr(
"OpenGL Specific Info:"));
477 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
479 QString vendor = QString((
const char*)glGetString(GL_VENDOR));
480 aboutWidget_->OpenFlipperAbout->append(tr(
"Qt reports Vendor:\t\t") + vendor);
481 QString renderer = QString((
const char*)glGetString(GL_RENDERER));
482 aboutWidget_->OpenFlipperAbout->append(tr(
"Qt reports Renderer:\t\t") + renderer);
484 QPair<int, int> version = QOpenGLContext::currentContext()->format().version();
486 QString openGLQtVersion = tr(
"Qt reports Version:\t\t");
488 openGLQtVersion += QString::number(version.first) + tr(
",") + QString::number(version.second);
490 aboutWidget_->OpenFlipperAbout->append(openGLQtVersion);
494 const QOpenGLContext* context = QOpenGLContext::currentContext();
496 QString openGLprofile = tr(
"Qt reports the OpenGL profile:\t");
497 QSurfaceFormat::OpenGLContextProfile profile = context->format().profile();
498 if (profile == QSurfaceFormat::NoProfile)
499 openGLprofile += tr(
"no profile");
500 else if (profile == QSurfaceFormat::CoreProfile)
501 openGLprofile += tr(
"Core profile");
502 else if (profile == QSurfaceFormat::CompatibilityProfile)
503 openGLprofile += tr(
"Compatibility profile");
505 openGLprofile += tr(
"unknown profile");
512 QString openGLVendor = tr(
"GL reports Vendor:\t\t");
513 openGLVendor += QString((
const char*)glGetString(GL_VENDOR));
516 QString openGLRenderer = tr(
"GL reports Renderer:\t\t");
517 openGLRenderer += QString((
const char*)glGetString(GL_RENDERER));
520 QString openGLGLVersion = tr(
"GL reports Version:\t\t");
521 openGLGLVersion += QString((
const char*)glGetString(GL_VERSION));
522 aboutWidget_->OpenFlipperAbout->append(openGLGLVersion);
524 QString openGLShadingLanguageVersion = tr(
"GL reports Shading Language Version:\t");
525 openGLShadingLanguageVersion += QString((
const char*)glGetString(GL_SHADING_LANGUAGE_VERSION));
526 aboutWidget_->OpenFlipperAbout->append(openGLShadingLanguageVersion);
533 aboutWidget_->OpenFlipperAbout->append(tr(
"Supported Extensions:"));
542 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
543 aboutWidget_->OpenFlipperAbout->append(tr(
"OpenGL Values:"));
544 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
546 glGetIntegerv(GL_MAX_VIEWPORT_DIMS, &getBuffer[0] );
547 aboutWidget_->OpenFlipperAbout->append(tr(
"Maximal Viewport size(GL_MAX_VIEWPORT_DIMS):\t\t\t\t ") + QString::number(getBuffer[0]) +
"x" + QString::number(getBuffer[1]) );
549 glGetIntegerv(GL_MAX_TEXTURE_IMAGE_UNITS, &getBuffer[0] );
550 aboutWidget_->OpenFlipperAbout->append(tr(
"Maximum supported texture image units(GL_MAX_TEXTURE_IMAGE_UNITS):\t") + QString::number(getBuffer[0]) );
553 if ( glExtensions.contains(
"GL_NVX_gpu_memory_info") ) {
555 GLint total_mem_kb = 0;
556 glGetIntegerv(GPU_MEMORY_INFO_TOTAL_AVAILABLE_MEMORY_NVX, &total_mem_kb);
558 aboutWidget_->OpenFlipperAbout->append(tr(
"GPU Memory (Total available):\t\t") + QString::number(total_mem_kb /1024) +
" MB" );
561 GLint cur_avail_mem_kb = 0;
562 glGetIntegerv(GPU_MEMORY_INFO_CURRENT_AVAILABLE_VIDMEM_NVX, &cur_avail_mem_kb);
564 aboutWidget_->OpenFlipperAbout->append(tr(
"GPU Memory (Currently available):\t") + QString::number(cur_avail_mem_kb / 1024) +
" MB" );
569 aboutWidget_->OpenFlipperAbout->moveCursor(QTextCursor::Start);
576 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
577 aboutWidget_->OpenFlipperAbout->append(tr(
"GLEW Specific Info:"));
578 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
580 QString glewVersion = QString(getGlewVersion());
581 aboutWidget_->OpenFlipperAbout->append(tr(
"GLEW Version:\t") + glewVersion);
589 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
590 aboutWidget_->OpenFlipperAbout->append(tr(
"Qt Version Info:"));
591 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
592 aboutWidget_->OpenFlipperAbout->append(tr(
"Currently used Version:\t") + qVersion() );
593 aboutWidget_->OpenFlipperAbout->append(tr(
"Link time Version:\t\t") + QT_VERSION_STR );
595 QList<QByteArray> imageFormats = QImageReader::supportedImageFormats();
596 QString formatsString =
"";
597 for (
int i = 0 ; i < imageFormats.size() ; ++i) {
598 formatsString += imageFormats[i] +
" ";
600 if ( (i != 0) && (i % 15) == 0 )
601 formatsString+=
"\n";
604 aboutWidget_->OpenFlipperAbout->append(tr(
"Supported image read formats:") );
609 aboutWidget_->OpenFlipperAbout->append(tr(
"Currently used Library paths:") );
610 QStringList libPaths = QCoreApplication::libraryPaths();
611 for(
int i = 0 ; i < libPaths.size() ; ++i)
612 aboutWidget_->OpenFlipperAbout->append(
" " + libPaths[i]);
635 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
636 aboutWidget_->OpenFlipperAbout->append(tr(
"Compiler Info:"));
637 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
638 aboutWidget_->OpenFlipperAbout->append( OpenFlipper::Options::compilerInfo() );
644 definitions +=
"WIN32 ";
648 definitions +=
"WIN64 ";
652 definitions +=
"DLL ";
657 definitions +=
"APPLE ";
661 definitions +=
"ARCH_DARWIN ";
664 #ifdef INCLUDE_TEMPLATES
665 definitions +=
"INCLUDE_TEMPLATES ";
669 definitions +=
"DEBUG ";
673 definitions +=
"NDEBUG ";
677 definitions +=
"QT_NO_OPENGL ";
681 definitions +=
"OPENMP ";
685 definitions +=
"USE_OPENMP ";
688 aboutWidget_->OpenFlipperAbout->append( tr(
"Definitions (incomplete):\n") + definitions );
694 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
695 aboutWidget_->OpenFlipperAbout->append(tr(
"Registered data types:"));
696 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
704 for ( uint i = 0 ; i <
typeCount() - 2 ; ++i) {
705 types +=
typeName( currentType ) +
"\t\t typeId: " + QString::number(currentType.
value()) +
"\n";
717 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
718 aboutWidget_->OpenFlipperAbout->append(tr(
"Registered File Plugins:"));
719 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
721 for ( uint i = 0 ; i < supportedTypes().size() ; ++i ) {
722 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
723 aboutWidget_->OpenFlipperAbout->append(
"\t" + supportedTypes()[i].name );
724 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
725 aboutWidget_->OpenFlipperAbout->append(
"\t\t Load: " + supportedTypes()[i].loadFilters );
726 aboutWidget_->OpenFlipperAbout->append(
"\t\t Save: " + supportedTypes()[i].saveFilters );
734 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
735 aboutWidget_->OpenFlipperAbout->append(tr(
"Loaded Plugins:"));
736 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
738 for ( uint i = 0 ; i <
plugins().size() ; ++i ) {
739 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
741 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
743 aboutWidget_->OpenFlipperAbout->append(
"\t\t Description: \t" +
plugins()[i].description );
746 if ( !
plugins()[i].warnings.isEmpty() ) {
747 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::darkYellow);
749 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::black);
752 if ( !
plugins()[i].errors.isEmpty() ) {
753 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::darkRed);
755 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::black);
763 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
764 aboutWidget_->OpenFlipperAbout->append(tr(
"Failed Plugins:"));
765 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
767 for (
unsigned i = 0 ; i < PluginStorage::pluginsFailed().size() ; ++i ) {
768 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
769 aboutWidget_->OpenFlipperAbout->append(
"\t" + PluginStorage::pluginsFailed()[i].name );
770 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
771 aboutWidget_->OpenFlipperAbout->append(
"\t\t Version: \t\t" + PluginStorage::pluginsFailed()[i].version );
772 aboutWidget_->OpenFlipperAbout->append(
"\t\t Description: \t" + PluginStorage::pluginsFailed()[i].description );
773 aboutWidget_->OpenFlipperAbout->append(
"\t\t Path \t\t" + PluginStorage::pluginsFailed()[i].path );
775 if ( !PluginStorage::pluginsFailed()[i].warnings.isEmpty() ) {
776 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::darkYellow);
777 aboutWidget_->OpenFlipperAbout->append(
"\t\t Warnings: \t\t" + PluginStorage::pluginsFailed()[i].warnings );
778 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::black);
781 if ( !PluginStorage::pluginsFailed()[i].errors.isEmpty() ) {
782 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::darkRed);
783 aboutWidget_->OpenFlipperAbout->append(
"\t\t Errors: \t\t" + PluginStorage::pluginsFailed()[i].errors );
784 aboutWidget_->OpenFlipperAbout->setTextColor(Qt::black);
797 aboutWidget_->OpenFlipperAbout->setCurrentFont(boldFont);
798 aboutWidget_->OpenFlipperAbout->append(tr(
"Currently loaded Resources (e.g. by qrc files):"));
799 aboutWidget_->OpenFlipperAbout->setCurrentFont(standardFont);
801 QDir toplevelResources(
":/");
802 for (
auto str : toplevelResources.entryList() ) {
805 QDir firstLevel(
":/" + str);
806 for (
auto firstLevelStr : firstLevel.entryList() ) {
807 aboutWidget_->OpenFlipperAbout->append(
" \t" + firstLevelStr);
809 QDir secondLevel(
":/" + str +
"/" + firstLevelStr);
811 for (
auto secondLevelStr : secondLevel.entryList() ) {
812 aboutWidget_->OpenFlipperAbout->append(
" \t\t" + secondLevelStr);
DLLEXPORT QString typeName(DataType _id)
Get the name of a type with given id.
DLLEXPORT size_t typeCount()
Get the number of registered types.
DLLEXPORT OpenFlipperQSettings & OpenFlipperSettings()
QSettings object containing all program settings of OpenFlipper.
#define TOSTRING(x)
QSettings object containing all program settings of OpenFlipper.
unsigned int value() const
std::string getExtensionString()
getExtensionString returns a string containing all supported OpenGL extensions this function uses the...