From 22cd7dce94a9bdf00ebc419509962d3fae4752e1 Mon Sep 17 00:00:00 2001 From: Yuzu Date: Thu, 21 May 2026 19:59:00 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20show=20=E2=8C=A5=20and=20=E2=8C=83=20sym?= =?UTF-8?q?bols=20for=20Alt/Option=20and=20Ctrl=20on=20macOS?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Use macOS keyboard symbols in help bar instead of M- and ^ notation when built on Apple platforms, matching established __APPLE__ guard pattern in src/uikeyconfig.cpp. --- src/uihelpview.cpp | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/uihelpview.cpp b/src/uihelpview.cpp index e0c57438..0a04d0d2 100644 --- a/src/uihelpview.cpp +++ b/src/uihelpview.cpp @@ -270,14 +270,22 @@ std::string UiHelpView::GetKeyDisplay(const std::string& p_Func) const std::string keyName = UiKeyConfig::GetStr(p_Func); if ((keyName.size() == 9) && (keyName >= "KEY_CTRLA") && (keyName <= "KEY_CTRLZ")) { - return "^" + keyName.substr(8, 1); +#if defined(__APPLE__) + return "\xe2\x8c\x83" + keyName.substr(8, 1); // ⌃ +#else + return "^" + keyName.substr(8, 1); // ^ +#endif } else if (std::count(keyName.begin(), keyName.end(), '\\') == 2) { const std::string keyStr = StrUtil::StrFromOct(keyName); if ((keyStr.size() == 2) && (keyStr.at(0) == '\33') && StrUtil::IsValidTextKey(keyStr.at(1))) { - return "M-" + keyStr.substr(1); +#if defined(__APPLE__) + return "\xe2\x8c\xa5" + keyStr.substr(1); // ⌥ +#else + return "M-" + keyStr.substr(1); // M- +#endif } } else if (keyName == "KEY_RETURN")