diff --git a/bin/resources/icons/AppBanner.svg b/bin/resources/icons/AppBanner.svg new file mode 100644 index 0000000000..f59072c4b2 --- /dev/null +++ b/bin/resources/icons/AppBanner.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/pcsx2-qt/AboutDialog.ui b/pcsx2-qt/AboutDialog.ui index 154a7bad4b..55a964538d 100644 --- a/pcsx2-qt/AboutDialog.ui +++ b/pcsx2-qt/AboutDialog.ui @@ -6,8 +6,8 @@ 0 0 - 576 - 294 + 580 + 300 @@ -19,45 +19,42 @@ - Qt::Horizontal + Qt::Orientation::Horizontal - - - 40 - 20 - + + QSizePolicy::Policy::Preferred - + - 260 - 260 + 1 + 1 - :/icons/logo.png + :/icons/PCSX2logo.svg + + + false - Qt::AlignCenter + Qt::AlignmentFlag::AlignCenter - Qt::Horizontal + Qt::Orientation::Horizontal - - - 40 - 20 - + + QSizePolicy::Policy::Preferred @@ -69,7 +66,7 @@ SCM Version - Qt::AlignCenter + Qt::AlignmentFlag::AlignCenter @@ -79,7 +76,7 @@ <html><head/><body><p>PCSX2 is a free and open-source PlayStation 2 (PS2) emulator. Its purpose is to emulate the PS2's hardware, using a combination of MIPS CPU Interpreters, Recompilers and a Virtual Machine which manages hardware states and PS2 system memory. This allows you to play PS2 games on your PC, with many additional features and benefits.</p></body></html> - Qt::AlignJustify|Qt::AlignVCenter + Qt::AlignmentFlag::AlignJustify|Qt::AlignmentFlag::AlignVCenter true @@ -89,23 +86,31 @@ - Qt::Vertical + Qt::Orientation::Vertical + + + QSizePolicy::Policy::Minimum - 20 - 40 + 0 + 0 + + + true + + <html><head/><body><p>PlayStation 2 and PS2 are registered trademarks of Sony Interactive Entertainment. This application is not affiliated in any way with Sony Interactive Entertainment.</p></body></html> - Qt::AlignJustify|Qt::AlignVCenter + Qt::AlignmentFlag::AlignJustify|Qt::AlignmentFlag::AlignVCenter true @@ -115,12 +120,15 @@ - Qt::Vertical + Qt::Orientation::Vertical + + + QSizePolicy::Policy::Minimum - 20 - 40 + 0 + 0 @@ -131,19 +139,22 @@ TextLabel - Qt::AlignCenter + Qt::AlignmentFlag::AlignCenter - Qt::Vertical + Qt::Orientation::Vertical + + + QSizePolicy::Policy::Minimum - 20 - 40 + 0 + 0 @@ -151,7 +162,7 @@ - QDialogButtonBox::Close + QDialogButtonBox::StandardButton::Close true @@ -162,7 +173,6 @@ - diff --git a/pcsx2-qt/resources/icons/PCSX2logo.svg b/pcsx2-qt/resources/icons/PCSX2logo.svg new file mode 100644 index 0000000000..cbc6e7b96d --- /dev/null +++ b/pcsx2-qt/resources/icons/PCSX2logo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/pcsx2-qt/resources/icons/logo.png b/pcsx2-qt/resources/icons/logo.png deleted file mode 100644 index 8c2e221c19..0000000000 Binary files a/pcsx2-qt/resources/icons/logo.png and /dev/null differ diff --git a/pcsx2-qt/resources/resources.qrc b/pcsx2-qt/resources/resources.qrc index 7c764153ea..8feec3875b 100644 --- a/pcsx2-qt/resources/resources.qrc +++ b/pcsx2-qt/resources/resources.qrc @@ -103,7 +103,7 @@ icons/black/svg/window-2-line.svg icons/black/svg/zoom-in-line.svg icons/black/svg/zoom-out-line.svg - icons/logo.png + icons/PCSX2logo.svg icons/QT.png icons/update.png icons/white/index.theme diff --git a/pcsx2/ImGui/FullscreenUI.cpp b/pcsx2/ImGui/FullscreenUI.cpp index 21401226fd..c6a1855d8d 100644 --- a/pcsx2/ImGui/FullscreenUI.cpp +++ b/pcsx2/ImGui/FullscreenUI.cpp @@ -269,6 +269,7 @@ namespace FullscreenUI static std::array, static_cast(GameDatabaseSchema::Compatibility::Perfect)> s_game_compatibility_textures; + static std::shared_ptr s_banner_texture; static std::shared_ptr s_fallback_disc_texture; static std::shared_ptr s_fallback_exe_texture; static std::vector> s_cleanup_textures; @@ -1096,6 +1097,8 @@ bool FullscreenUI::LoadResources() bool FullscreenUI::LoadSvgResources() { + s_banner_texture = LoadSvgTexture("icons/AppBanner.svg", LayoutScale(500.0f, 76.0f), SvgScaling::Fit); + for (u32 i = static_cast(GameDatabaseSchema::Compatibility::Nothing); i <= static_cast(GameDatabaseSchema::Compatibility::Perfect); i++) { @@ -1109,6 +1112,7 @@ void FullscreenUI::DestroyResources() { s_fallback_exe_texture.reset(); s_fallback_disc_texture.reset(); + s_banner_texture.reset(); for (auto& tex : s_game_compatibility_textures) tex.reset(); for (auto& tex : s_cleanup_textures) @@ -7017,7 +7021,7 @@ void FullscreenUI::OpenAboutWindow() void FullscreenUI::DrawAboutWindow() { - ImGui::SetNextWindowSize(LayoutScale(1000.0f, 580.0f)); + ImGui::SetNextWindowSize(LayoutScale(1000.0f, 600.0f)); ImGui::SetNextWindowPos(ImGui::GetIO().DisplaySize * 0.5f, ImGuiCond_Always, ImVec2(0.5f, 0.5f)); ImGui::OpenPopup(FSUI_CSTR("About PCSX2")); @@ -7027,21 +7031,24 @@ void FullscreenUI::DrawAboutWindow() if (ImGui::BeginPopupModal(FSUI_CSTR("About PCSX2"), &s_about_window_open, ImGuiWindowFlags_NoTitleBar | ImGuiWindowFlags_NoResize)) { + const ImVec2 image_size = LayoutScale(500.0f, 76.0f); + const ImRect image_bb(ImGui::GetCursorScreenPos(), ImGui::GetCursorScreenPos() + ImVec2(ImGui::GetCurrentWindow()->WorkRect.GetWidth(), image_size.y)); + const ImRect image_rect(CenterImage(image_bb, image_size)); + + DrawListSvgTexture(ImGui::GetWindowDrawList(), s_banner_texture.get(), image_rect.Min, image_rect.Max); + + const float indent = image_size.y + LayoutScale(12.0f); + ImGui::SetCursorPosY(ImGui::GetCursorPosY() + indent); ImGui::TextWrapped("%s", FSUI_CSTR( "PCSX2 is a free and open-source PlayStation 2 (PS2) emulator. Its purpose is to emulate the PS2's hardware, using a " "combination of MIPS CPU Interpreters, Recompilers and a Virtual Machine which manages hardware states and PS2 system memory. " "This allows you to play PS2 games on your PC, with many additional features and benefits.")); ImGui::NewLine(); - ImGui::TextWrapped(FSUI_CSTR("Version: %s"), BuildVersion::GitRev); - ImGui::NewLine(); - ImGui::TextWrapped("%s", FSUI_CSTR("PlayStation 2 and PS2 are registered trademarks of Sony Interactive Entertainment. This application is not " "affiliated in any way with Sony Interactive Entertainment.")); - ImGui::NewLine(); - BeginMenuButtons(); if (ActiveButton(FSUI_ICONSTR(ICON_FA_GLOBE, "Website"), false)) @@ -7068,6 +7075,10 @@ void FullscreenUI::DrawAboutWindow() EndMenuButtons(); + const float alignment = image_size.x + image_size.y; + ImGui::SetCursorPosX(ImGui::GetCursorPosX() + alignment); + ImGui::TextWrapped(FSUI_CSTR("Version: %s"), BuildVersion::GitRev); + ImGui::EndPopup(); }