From bcb6d2a429737910c81c339fefd2a9b8131004c7 Mon Sep 17 00:00:00 2001 From: Martin Helmut Fieber Date: Sun, 14 Jul 2024 12:12:34 +0200 Subject: [PATCH 1/3] Updated code of conduct to v2.1 --- CODE_OF_CONDUCT.md | 45 +++++++++++++++++++++++++-------------------- 1 file changed, 25 insertions(+), 20 deletions(-) diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md index 20595a0..7673b83 100644 --- a/CODE_OF_CONDUCT.md +++ b/CODE_OF_CONDUCT.md @@ -6,8 +6,8 @@ We as members, contributors, and leaders pledge to make participation in our community a harassment-free experience for everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, -nationality, personal appearance, race, religion, or sexual identity -and orientation. +nationality, personal appearance, race, caste, color, religion, or sexual +identity and orientation. We pledge to act and interact in ways that contribute to an open, welcoming, diverse, inclusive, and healthy community. @@ -20,16 +20,21 @@ community include: * Demonstrating empathy and kindness toward other people * Being respectful of differing opinions, viewpoints, and experiences * Giving and gracefully accepting constructive feedback -* Accepting responsibility and apologizing to those affected by our mistakes, and learning from the experience -* Focusing on what is best not just for us as individuals, but for the overall community +* Accepting responsibility and apologizing to those affected by our mistakes, + and learning from the experience +* Focusing on what is best not just for us as individuals, but for the overall + community Examples of unacceptable behavior include: -* The use of sexualized language or imagery, and sexual attention or advances of any kind +* The use of sexualized language or imagery, and sexual attention or advances of + any kind * Trolling, insulting or derogatory comments, and personal or political attacks * Public or private harassment -* Publishing others' private information, such as a physical or email address, without their explicit permission -* Other conduct which could reasonably be considered inappropriate in a professional setting +* Publishing others' private information, such as a physical or email address, + without their explicit permission +* Other conduct which could reasonably be considered inappropriate in a + professional setting ## Enforcement Responsibilities @@ -47,7 +52,7 @@ decisions when appropriate. This Code of Conduct applies within all community spaces, and also applies when an individual is officially representing the community in public spaces. -Examples of representing our community include using an official e-mail address, +Examples of representing our community include using an official email address, posting via an official social media account, or acting as an appointed representative at an online or offline event. @@ -55,7 +60,7 @@ representative at an online or offline event. Instances of abusive, harassing, or otherwise unacceptable behavior may be reported to the community leaders responsible for enforcement at -[EMAIL](mailto:EMAIL). +[INSERT CONTACT METHOD]. All complaints will be reviewed and investigated promptly and fairly. All community leaders are obligated to respect the privacy and security of the @@ -77,15 +82,15 @@ behavior was inappropriate. A public apology may be requested. ### 2. Warning -**Community Impact**: A violation through a single incident or series -of actions. +**Community Impact**: A violation through a single incident or series of +actions. **Consequence**: A warning with consequences for continued behavior. No interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, for a specified period of time. This includes avoiding interactions in community spaces as well as external channels -like social media. Violating these terms may lead to a temporary or -permanent ban. +like social media. Violating these terms may lead to a temporary or permanent +ban. ### 3. Temporary Ban @@ -104,25 +109,25 @@ Violating these terms may lead to a permanent ban. standards, including sustained inappropriate behavior, harassment of an individual, or aggression toward or disparagement of classes of individuals. -**Consequence**: A permanent ban from any sort of public interaction within -the community. +**Consequence**: A permanent ban from any sort of public interaction within the +community. ## Attribution This Code of Conduct is adapted from the [Contributor Covenant][homepage], -version 2.0, available at -[https://www.contributor-covenant.org/version/2/0/code_of_conduct.html][v2.0]. +version 2.1, available at +[https://www.contributor-covenant.org/version/2/1/code_of_conduct.html][v2.1]. Community Impact Guidelines were inspired by [Mozilla's code of conduct enforcement ladder][Mozilla CoC]. For answers to common questions about this code of conduct, see the FAQ at -[https://www.contributor-covenant.org/faq][FAQ]. Translations are available -at [https://www.contributor-covenant.org/translations][translations]. +[https://www.contributor-covenant.org/faq][FAQ]. Translations are available at +[https://www.contributor-covenant.org/translations][translations]. [homepage]: https://www.contributor-covenant.org -[v2.0]: https://www.contributor-covenant.org/version/2/0/code_of_conduct.html +[v2.1]: https://www.contributor-covenant.org/version/2/1/code_of_conduct.html [Mozilla CoC]: https://github.com/mozilla/diversity From 6d2aad5ee305fe7f141da70b3ac3711a0b1266eb Mon Sep 17 00:00:00 2001 From: Martin Helmut Fieber Date: Sun, 14 Jul 2024 12:20:58 +0200 Subject: [PATCH 2/3] Upgrade dependencies --- vendor/CMakeLists.txt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/vendor/CMakeLists.txt b/vendor/CMakeLists.txt index abfe20a..a3b0e87 100644 --- a/vendor/CMakeLists.txt +++ b/vendor/CMakeLists.txt @@ -11,25 +11,25 @@ FetchContent_Declare( FetchContent_Declare( fmt GIT_REPOSITORY "https://github.com/fmtlib/fmt.git" - GIT_TAG 10.2.1 + GIT_TAG 11.0.1 ) FetchContent_Declare( imgui GIT_REPOSITORY "https://github.com/ocornut/imgui.git" - GIT_TAG 085781f5ca5372d5fc804d7e44b5bf27a8994af7 # Branch: docking, date: 19.03.2024, 06:52 GMT+1 + GIT_TAG 527b2c45af2f8964f95826bd16ab7c7ed372ae41 # Branch: docking, date: 02.07.2024, 19:05 GMT+1 ) FetchContent_Declare( SDL2 GIT_REPOSITORY "https://github.com/libsdl-org/SDL.git" - GIT_TAG release-2.30.1 + GIT_TAG release-2.30.5 ) FetchContent_Declare( spdlog GIT_REPOSITORY "https://github.com/gabime/spdlog.git" - GIT_TAG v1.13.0 + GIT_TAG v1.14.1 ) # Settings From 82c84d80ccc2ed6593423b33f5105894ef840a75 Mon Sep 17 00:00:00 2001 From: Martin Helmut Fieber Date: Sun, 14 Jul 2024 12:21:17 +0200 Subject: [PATCH 3/3] Update high DPI handling --- src/core/Core/Application.cpp | 5 ++++- src/core/Core/Window.cpp | 1 - src/core/Platform/Linux/DPIHandler.cpp | 5 ----- src/core/Platform/Mac/DPIHandler.cpp | 7 ------- src/core/Platform/Windows/DPIHandler.cpp | 5 ----- vendor/CMakeLists.txt | 2 +- 6 files changed, 5 insertions(+), 20 deletions(-) diff --git a/src/core/Core/Application.cpp b/src/core/Core/Application.cpp index 02a870f..21b7b32 100644 --- a/src/core/Core/Application.cpp +++ b/src/core/Core/Application.cpp @@ -147,9 +147,12 @@ ExitStatus App::Application::run() { // Rendering ImGui::Render(); + SDL_RenderSetScale(m_window->get_native_renderer(), + io.DisplayFramebufferScale.x, + io.DisplayFramebufferScale.y); SDL_SetRenderDrawColor(m_window->get_native_renderer(), 100, 100, 100, 255); SDL_RenderClear(m_window->get_native_renderer()); - ImGui_ImplSDLRenderer2_RenderDrawData(ImGui::GetDrawData()); + ImGui_ImplSDLRenderer2_RenderDrawData(ImGui::GetDrawData(), m_window->get_native_renderer()); SDL_RenderPresent(m_window->get_native_renderer()); } diff --git a/src/core/Core/Window.cpp b/src/core/Core/Window.cpp index 12a8201..0728d51 100644 --- a/src/core/Core/Window.cpp +++ b/src/core/Core/Window.cpp @@ -33,7 +33,6 @@ Window::Window(const Settings& settings) { SDL_RendererInfo info; SDL_GetRendererInfo(m_renderer, &info); - DPIHandler::set_render_scale(m_renderer); APP_DEBUG("Current SDL_Renderer: {}", info.name); } diff --git a/src/core/Platform/Linux/DPIHandler.cpp b/src/core/Platform/Linux/DPIHandler.cpp index 707ba1d..c26a5dc 100644 --- a/src/core/Platform/Linux/DPIHandler.cpp +++ b/src/core/Platform/Linux/DPIHandler.cpp @@ -26,11 +26,6 @@ WindowSize DPIHandler::get_dpi_aware_window_size(const Window::Settings& setting return {settings.width, settings.height}; } -void DPIHandler::set_render_scale([[maybe_unused]] SDL_Renderer* renderer) { - APP_PROFILE_FUNCTION(); - // do nothing -} - void DPIHandler::set_global_font_scaling([[maybe_unused]] ImGuiIO* io) { APP_PROFILE_FUNCTION(); // do nothing diff --git a/src/core/Platform/Mac/DPIHandler.cpp b/src/core/Platform/Mac/DPIHandler.cpp index eb86229..389d29e 100644 --- a/src/core/Platform/Mac/DPIHandler.cpp +++ b/src/core/Platform/Mac/DPIHandler.cpp @@ -30,13 +30,6 @@ WindowSize DPIHandler::get_dpi_aware_window_size(const Window::Settings& setting return {settings.width, settings.height}; } -void DPIHandler::set_render_scale(SDL_Renderer* renderer) { - APP_PROFILE_FUNCTION(); - - auto scale{get_scale()}; - SDL_RenderSetScale(renderer, scale, scale); -} - void DPIHandler::set_global_font_scaling(ImGuiIO* io) { APP_PROFILE_FUNCTION(); diff --git a/src/core/Platform/Windows/DPIHandler.cpp b/src/core/Platform/Windows/DPIHandler.cpp index 0d7e52d..9f038a1 100644 --- a/src/core/Platform/Windows/DPIHandler.cpp +++ b/src/core/Platform/Windows/DPIHandler.cpp @@ -29,11 +29,6 @@ WindowSize DPIHandler::get_dpi_aware_window_size(const Window::Settings& setting return {width, height}; } -void DPIHandler::set_render_scale([[maybe_unused]] SDL_Renderer* renderer) { - APP_PROFILE_FUNCTION(); - // do nothing -} - void DPIHandler::set_global_font_scaling([[maybe_unused]] ImGuiIO* io) { APP_PROFILE_FUNCTION(); // do nothing diff --git a/vendor/CMakeLists.txt b/vendor/CMakeLists.txt index a3b0e87..5c368aa 100644 --- a/vendor/CMakeLists.txt +++ b/vendor/CMakeLists.txt @@ -17,7 +17,7 @@ FetchContent_Declare( FetchContent_Declare( imgui GIT_REPOSITORY "https://github.com/ocornut/imgui.git" - GIT_TAG 527b2c45af2f8964f95826bd16ab7c7ed372ae41 # Branch: docking, date: 02.07.2024, 19:05 GMT+1 + GIT_TAG 527b2c45af2f8964f95826bd16ab7c7ed372ae41 # Branch: docking, date: 02.07.2024, 19:05 GMT+2 ) FetchContent_Declare(