25 #include <ArmarXGui/applications/ArmarXGui/ui_UseCaseSelectorItem.h>
38 configFilePath(configFilePath)
41 this->setToolTip(configFilePath);
42 ui->titleLabel->setText(title);
43 ui->descriptionLabel->setText(description);
44 std::filesystem::path p(configFilePath.toStdString());
46 ui->filenameLabel->setText(QString(p.filename().string().c_str()) +
" in " + packageName +
" ");
47 QString finalPath = iconPath;
48 if (!iconPath.isEmpty())
50 if (!QFile::exists(iconPath))
55 if (!QFile::exists(finalPath))
59 if (!QFile::exists(finalPath))
65 finalPath = QString::fromStdString((path / iconPath.toStdString()).string());
68 if (QFile::exists(finalPath))
70 QPixmap pixmap(finalPath);
73 ui->iconLabel->setPixmap(pixmap.scaled(
pixmapSize,
pixmapSize, Qt::KeepAspectRatio, Qt::SmoothTransformation));
77 ARMARX_INFO_S <<
"Cannot find image: " << iconPath.toStdString();
90 return configFilePath;
101 QPalette p(palette());
102 setAutoFillBackground(
true);
105 p.setColor(QPalette::Window, p.highlight().color());
109 p = qobject_cast<QWidget*>(parent())->palette();