38 #include <QCoreApplication>
44 const int bottom_border = 27;
45 QPixmap splash(pixmap.width(), pixmap.height() + bottom_border);
46 splash.fill(QColor(0, 0, 0));
48 QPainter painter(&splash);
50 painter.drawPixmap(QPoint(0, 0), pixmap);
52 QPixmap overlay =
loadPixmap(
"package://rviz/images/splash_overlay.png");
53 painter.drawTiledPixmap(QRect(0, pixmap.height() - overlay.height(), pixmap.width(), pixmap.height()),
57 QString version_info =
"r" + QString(
get_version().c_str());
58 version_info +=
" (" + QString(
get_distro().c_str()) +
")";
60 painter.setPen(QColor(160, 160, 160));
61 QRect r = splash.rect();
62 r.setRect(r.x() + 5, r.y() + 5, r.width() - 10, r.height() - 10);
63 painter.drawText(r, Qt::AlignRight | Qt::AlignBottom, version_info);
70 QSplashScreen::showMessage(message, Qt::AlignLeft | Qt::AlignBottom, Qt::white);