From 0a327f4ad3780a6e357e26c80438fb666d0ed6b6 Mon Sep 17 00:00:00 2001 From: WerWolv Date: Sat, 10 May 2025 10:43:19 +0200 Subject: [PATCH] impr: Allow debug banner to be skipped with a env var --- plugins/builtin/source/plugin_builtin.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/plugins/builtin/source/plugin_builtin.cpp b/plugins/builtin/source/plugin_builtin.cpp index 78fc4b8ac..222ababb5 100644 --- a/plugins/builtin/source/plugin_builtin.cpp +++ b/plugins/builtin/source/plugin_builtin.cpp @@ -91,7 +91,9 @@ IMHEX_PLUGIN_SETUP("Built-in", "WerWolv", "Default ImHex functionality") { // Show a warning banner on debug builds #if defined(DEBUG) - ui::BannerIcon::open(ICON_VS_ERROR, "You're running a Debug build of ImHex. Performance will be degraded!", ImColor(153, 58, 58)); + if (!hex::getEnvironmentVariable("NO_DEBUG_BANNER").has_value()) { + ui::BannerIcon::open(ICON_VS_ERROR, "You're running a Debug build of ImHex. Performance will be degraded!", ImColor(153, 58, 58)); + } dbg::setDebugModeEnabled(true); #else const auto enabled = ContentRegistry::Settings::read("hex.builtin.setting.general", "hex.builtin.setting.general.debug_mode_enabled", false);