diff options
author | Septian <septgsk@gmail.com> | 2023-12-27 23:19:43 +0700 |
---|---|---|
committer | Septian <septgsk@gmail.com> | 2023-12-27 23:19:43 +0700 |
commit | 475c2fa1e7b85a055da9092d103d4473da0fe583 (patch) | |
tree | 1ea17f465e0b6574f9275714b77d811f40e70282 /platform/windows/os_windows.cpp | |
parent | 13a0d6e9b253654f5cc2a44f3d0b3cae10440443 (diff) | |
download | redot-engine-475c2fa1e7b85a055da9092d103d4473da0fe583.tar.gz |
Fix `OS.get_system_font_path` and `OS.get_system_font_path_for_text` to return correct value
Diffstat (limited to 'platform/windows/os_windows.cpp')
-rw-r--r-- | platform/windows/os_windows.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/platform/windows/os_windows.cpp b/platform/windows/os_windows.cpp index 1d3b80e21e..3d664a28da 100644 --- a/platform/windows/os_windows.cpp +++ b/platform/windows/os_windows.cpp @@ -1183,7 +1183,7 @@ Vector<String> OS_Windows::get_system_font_path_for_text(const String &p_font_na if (FAILED(hr)) { continue; } - String fpath = String::utf16((const char16_t *)&file_path[0]); + String fpath = String::utf16((const char16_t *)&file_path[0]).replace("\\", "/"); WIN32_FIND_DATAW d; HANDLE fnd = FindFirstFileW((LPCWSTR)&file_path[0], &d); @@ -1262,7 +1262,7 @@ String OS_Windows::get_system_font_path(const String &p_font_name, int p_weight, if (FAILED(hr)) { continue; } - String fpath = String::utf16((const char16_t *)&file_path[0]); + String fpath = String::utf16((const char16_t *)&file_path[0]).replace("\\", "/"); WIN32_FIND_DATAW d; HANDLE fnd = FindFirstFileW((LPCWSTR)&file_path[0], &d); |