diff --git a/src/App/Application.cpp b/src/App/Application.cpp index a6909448a1..937ba99f07 100644 --- a/src/App/Application.cpp +++ b/src/App/Application.cpp @@ -1132,6 +1132,14 @@ std::string Application::getNameWithVersion() return fmt::format("{} {}.{}.{}{}", appname, major, minor, point, suffix); } +bool Application::isDevelopmentVersion() +{ + static std::string suffix = []() constexpr { + return FCVersionSuffix; + }(); + return suffix == "dev"; +} + std::string Application::getTempPath() { return mConfig["AppTempPath"]; diff --git a/src/App/Application.h b/src/App/Application.h index 1c79cbb1a6..2a2d9e8f76 100644 --- a/src/App/Application.h +++ b/src/App/Application.h @@ -422,6 +422,7 @@ public: static std::string getHomePath(); static std::string getExecutableName(); static std::string getNameWithVersion(); + static bool isDevelopmentVersion(); /*! Returns the temporary directory. By default, this is set to the system's temporary directory but can be customized by the user. diff --git a/src/Gui/Dialogs/DlgAbout.cpp b/src/Gui/Dialogs/DlgAbout.cpp index 12b54089a2..3b93aa2a72 100644 --- a/src/Gui/Dialogs/DlgAbout.cpp +++ b/src/Gui/Dialogs/DlgAbout.cpp @@ -164,7 +164,11 @@ QPixmap AboutDialog::aboutImage() const about_image.load(fi.filePath(), "PNG"); } - std::string about_path = App::Application::Config()["AboutImage"]; + // Use dev or generic version of image depending on current build version. + const auto& suffix = App::Application::Config()["BuildVersionSuffix"]; + const auto about_path_key = (suffix == "dev") ? "AboutImageDev" : "AboutImage"; + const auto& about_path = App::Application::Config()[about_path_key]; + if (!about_path.empty() && about_image.isNull()) { QString path = QString::fromStdString(about_path); if (QDir(path).isRelative()) { diff --git a/src/Gui/Icons/freecadaboutdev.png b/src/Gui/Icons/freecadaboutdev.png new file mode 100644 index 0000000000..9ee1e88f25 Binary files /dev/null and b/src/Gui/Icons/freecadaboutdev.png differ diff --git a/src/Gui/Icons/resource.qrc b/src/Gui/Icons/resource.qrc index 17d760da4d..7ba58795d6 100644 --- a/src/Gui/Icons/resource.qrc +++ b/src/Gui/Icons/resource.qrc @@ -89,6 +89,7 @@ freecad-doc.svg freecad.svg freecadabout.png + freecadaboutdev.png freecadsplash_2x.png freecadsplash.png freecadsplash0_2x.png diff --git a/src/Main/MainGui.cpp b/src/Main/MainGui.cpp index 02ff633e12..ea1b24250c 100644 --- a/src/Main/MainGui.cpp +++ b/src/Main/MainGui.cpp @@ -196,7 +196,8 @@ int main(int argc, char** argv) App::Application::Config()["CopyrightInfo"] = sBanner; App::Application::Config()["AppIcon"] = "freecad"; App::Application::Config()["SplashScreen"] = "freecadsplash"; - App::Application::Config()["AboutImage"] = "freecadabout"; + App::Application::Config()["AboutImage"] = + App::Application::isDevelopmentVersion() ? "freecadaboutdev" : "freecadabout"; App::Application::Config()["StartWorkbench"] = "PartDesignWorkbench"; // App::Application::Config()["HiddenDockWindow"] = "Property editor"; App::Application::Config()["SplashAlignment"] = "Bottom|Left";