diff --git a/main/source/init/tasks.cpp b/main/source/init/tasks.cpp index 830dce1ce..6cfa4d874 100644 --- a/main/source/init/tasks.cpp +++ b/main/source/init/tasks.cpp @@ -205,13 +205,13 @@ namespace hex::init { // Setup basic font configuration auto fonts = IM_NEW(ImFontAtlas)(); ImFontConfig cfg = {}; - cfg.OversampleH = cfg.OversampleV = 2, cfg.PixelSnapH = true; + cfg.OversampleH = cfg.OversampleV = 1, cfg.PixelSnapH = true; cfg.SizePixels = fontSize; fonts->Flags |= ImFontAtlasFlags_NoPowerOfTwoHeight; // Configure font glyph ranges that should be loaded from the default font and unifont - ImVector ranges; + static ImVector ranges; { ImFontGlyphRangesBuilder glyphRangesBuilder; @@ -241,12 +241,12 @@ namespace hex::init { } // Glyph range for font awesome icons - ImWchar fontAwesomeRange[] = { + static ImWchar fontAwesomeRange[] = { ICON_MIN_FA, ICON_MAX_FA, 0 }; // Glyph range for codicons icons - ImWchar codiconsRange[] = { + static ImWchar codiconsRange[] = { ICON_MIN_VS, ICON_MAX_VS, 0 }; @@ -284,7 +284,7 @@ namespace hex::init { IM_DELETE(fonts); // Disable unicode support in settings - ContentRegistry::Settings::write("hex.builtin.setting.general", "hex.builtin.setting.general.enable_unicode", false); + ContentRegistry::Settings::write("hex.builtin.setting.general", "hex.builtin.setting.general.load_all_unicode_chars", false); // Try to load the font atlas again return loadFontsImpl(false); @@ -305,7 +305,7 @@ namespace hex::init { // Check if unicode support is enabled in the settings and that the user doesn't use the No GPU version on Windows // The Mesa3D software renderer on Windows identifies itself as "VMware, Inc." bool shouldLoadUnicode = - ContentRegistry::Settings::read("hex.builtin.setting.general", "hex.builtin.setting.general.enable_unicode", true) && + ContentRegistry::Settings::read("hex.builtin.setting.general", "hex.builtin.setting.general.load_all_unicode_chars", false) && ImHexApi::System::getGPUVendor() != "VMware, Inc."; return loadFontsImpl(shouldLoadUnicode); diff --git a/plugins/builtin/romfs/lang/de_DE.json b/plugins/builtin/romfs/lang/de_DE.json index 039931f06..230f8fb94 100644 --- a/plugins/builtin/romfs/lang/de_DE.json +++ b/plugins/builtin/romfs/lang/de_DE.json @@ -444,7 +444,7 @@ "hex.builtin.setting.general": "Allgemein", "hex.builtin.setting.general.auto_load_patterns": "Automatisches Laden unterstützter Pattern", "hex.builtin.setting.general.server_contact": "Update checks und Statistiken zulassen", - "hex.builtin.setting.general.enable_unicode": "Alle Unicode Zeichen laden", + "hex.builtin.setting.general.load_all_unicode_chars": "Alle Unicode Zeichen laden", "hex.builtin.setting.general.network_interface": "", "hex.builtin.setting.general.save_recent_providers": "", "hex.builtin.setting.general.show_tips": "Tipps beim Start anzeigen", diff --git a/plugins/builtin/romfs/lang/en_US.json b/plugins/builtin/romfs/lang/en_US.json index 3fe011b0d..b2b57a0ec 100644 --- a/plugins/builtin/romfs/lang/en_US.json +++ b/plugins/builtin/romfs/lang/en_US.json @@ -450,7 +450,7 @@ "hex.builtin.setting.general": "General", "hex.builtin.setting.general.auto_load_patterns": "Auto-load supported pattern", "hex.builtin.setting.general.server_contact": "Enable update checks and usage statistics", - "hex.builtin.setting.general.enable_unicode": "Load all unicode characters", + "hex.builtin.setting.general.load_all_unicode_chars": "Load all unicode characters", "hex.builtin.setting.general.network_interface": "Enable network interface", "hex.builtin.setting.general.save_recent_providers": "Save recently used providers", "hex.builtin.setting.general.show_tips": "Show tips on startup", diff --git a/plugins/builtin/romfs/lang/es_ES.json b/plugins/builtin/romfs/lang/es_ES.json index c62a4c52e..c04796a0c 100644 --- a/plugins/builtin/romfs/lang/es_ES.json +++ b/plugins/builtin/romfs/lang/es_ES.json @@ -442,7 +442,7 @@ "hex.builtin.setting.general": "General", "hex.builtin.setting.general.auto_load_patterns": "Cargar automáticamente patterns soportados", "hex.builtin.setting.general.server_contact": "", - "hex.builtin.setting.general.enable_unicode": "Cargar todos los caracteres unicode", + "hex.builtin.setting.general.load_all_unicode_chars": "Cargar todos los caracteres unicode", "hex.builtin.setting.general.network_interface": "", "hex.builtin.setting.general.save_recent_providers": "Guardar proveedores recientemente utilizados", "hex.builtin.setting.general.show_tips": "Mostrar consejos al inicio", diff --git a/plugins/builtin/romfs/lang/it_IT.json b/plugins/builtin/romfs/lang/it_IT.json index 2c043efaf..b9dc5373d 100644 --- a/plugins/builtin/romfs/lang/it_IT.json +++ b/plugins/builtin/romfs/lang/it_IT.json @@ -442,7 +442,7 @@ "hex.builtin.setting.general": "Generali", "hex.builtin.setting.general.auto_load_patterns": "Auto-caricamento del pattern supportato", "hex.builtin.setting.general.server_contact": "", - "hex.builtin.setting.general.enable_unicode": "", + "hex.builtin.setting.general.load_all_unicode_chars": "", "hex.builtin.setting.general.network_interface": "", "hex.builtin.setting.general.save_recent_providers": "", "hex.builtin.setting.general.show_tips": "Mostra consigli all'avvio", diff --git a/plugins/builtin/romfs/lang/ja_JP.json b/plugins/builtin/romfs/lang/ja_JP.json index 598238fb4..84aecbfbc 100644 --- a/plugins/builtin/romfs/lang/ja_JP.json +++ b/plugins/builtin/romfs/lang/ja_JP.json @@ -442,7 +442,7 @@ "hex.builtin.setting.general": "基本", "hex.builtin.setting.general.auto_load_patterns": "対応するパターンを自動で読み込む", "hex.builtin.setting.general.server_contact": "", - "hex.builtin.setting.general.enable_unicode": "", + "hex.builtin.setting.general.load_all_unicode_chars": "", "hex.builtin.setting.general.network_interface": "", "hex.builtin.setting.general.save_recent_providers": "", "hex.builtin.setting.general.show_tips": "起動時に豆知識を表示", diff --git a/plugins/builtin/romfs/lang/ko_KR.json b/plugins/builtin/romfs/lang/ko_KR.json index de62b120d..7ea675424 100644 --- a/plugins/builtin/romfs/lang/ko_KR.json +++ b/plugins/builtin/romfs/lang/ko_KR.json @@ -442,7 +442,7 @@ "hex.builtin.setting.general": "일반", "hex.builtin.setting.general.auto_load_patterns": "지원하는 패턴 자동으로 로드", "hex.builtin.setting.general.server_contact": "", - "hex.builtin.setting.general.enable_unicode": "", + "hex.builtin.setting.general.load_all_unicode_chars": "", "hex.builtin.setting.general.network_interface": "", "hex.builtin.setting.general.save_recent_providers": "", "hex.builtin.setting.general.show_tips": "시작 시 팁 표시", diff --git a/plugins/builtin/romfs/lang/pt_BR.json b/plugins/builtin/romfs/lang/pt_BR.json index b1218d945..7bf387d24 100644 --- a/plugins/builtin/romfs/lang/pt_BR.json +++ b/plugins/builtin/romfs/lang/pt_BR.json @@ -442,7 +442,7 @@ "hex.builtin.setting.general": "General", "hex.builtin.setting.general.auto_load_patterns": "Padrão compatível com carregamento automático", "hex.builtin.setting.general.server_contact": "", - "hex.builtin.setting.general.enable_unicode": "", + "hex.builtin.setting.general.load_all_unicode_chars": "", "hex.builtin.setting.general.network_interface": "", "hex.builtin.setting.general.save_recent_providers": "", "hex.builtin.setting.general.show_tips": "Mostrar dicas na inicialização", diff --git a/plugins/builtin/romfs/lang/zh_CN.json b/plugins/builtin/romfs/lang/zh_CN.json index f89d96b3c..25ae59032 100644 --- a/plugins/builtin/romfs/lang/zh_CN.json +++ b/plugins/builtin/romfs/lang/zh_CN.json @@ -442,7 +442,7 @@ "hex.builtin.setting.general": "通用", "hex.builtin.setting.general.auto_load_patterns": "自动加载支持的模式", "hex.builtin.setting.general.server_contact": "", - "hex.builtin.setting.general.enable_unicode": "加载所有 Unicode 字符", + "hex.builtin.setting.general.load_all_unicode_chars": "加载所有 Unicode 字符", "hex.builtin.setting.general.network_interface": "", "hex.builtin.setting.general.save_recent_providers": "", "hex.builtin.setting.general.show_tips": "在启动时显示每日提示", diff --git a/plugins/builtin/romfs/lang/zh_TW.json b/plugins/builtin/romfs/lang/zh_TW.json index 858223bfd..c49fa64a3 100644 --- a/plugins/builtin/romfs/lang/zh_TW.json +++ b/plugins/builtin/romfs/lang/zh_TW.json @@ -442,7 +442,7 @@ "hex.builtin.setting.general": "一般", "hex.builtin.setting.general.auto_load_patterns": "自動載入支援的模式", "hex.builtin.setting.general.server_contact": "", - "hex.builtin.setting.general.enable_unicode": "載入所有 unicode 字元", + "hex.builtin.setting.general.load_all_unicode_chars": "載入所有 unicode 字元", "hex.builtin.setting.general.network_interface": "", "hex.builtin.setting.general.save_recent_providers": "", "hex.builtin.setting.general.show_tips": "啟動時顯示提示", diff --git a/plugins/builtin/source/content/settings_entries.cpp b/plugins/builtin/source/content/settings_entries.cpp index 188a107c3..fcc82c02c 100644 --- a/plugins/builtin/source/content/settings_entries.cpp +++ b/plugins/builtin/source/content/settings_entries.cpp @@ -73,7 +73,7 @@ namespace hex::plugin::builtin { return false; }); - ContentRegistry::Settings::add("hex.builtin.setting.general", "hex.builtin.setting.general.enable_unicode", 1, [](auto name, nlohmann::json &setting) { + ContentRegistry::Settings::add("hex.builtin.setting.general", "hex.builtin.setting.general.load_all_unicode_chars", 0, [](auto name, nlohmann::json &setting) { static bool enabled = static_cast(setting); if (ImGui::Checkbox(name.data(), &enabled)) {