diff options
author | bruvzg <7645683+bruvzg@users.noreply.github.com> | 2022-10-31 19:12:18 +0200 |
---|---|---|
committer | bruvzg <7645683+bruvzg@users.noreply.github.com> | 2022-11-01 11:04:58 +0200 |
commit | 060d62e0dc094ac7c4f15020c6921ac582f29977 (patch) | |
tree | b5cb03793c7f9d17b386a5c919600831cc5e9323 /platform | |
parent | e6751549cf7247965d1744b8c464f5e901006f21 (diff) |
Load and use system emoji font in the editor.
Diffstat (limited to 'platform')
-rw-r--r-- | platform/ios/os_ios.mm | 9 | ||||
-rw-r--r-- | platform/linuxbsd/os_linuxbsd.cpp | 11 | ||||
-rw-r--r-- | platform/macos/os_macos.mm | 9 | ||||
-rw-r--r-- | platform/windows/os_windows.cpp | 9 |
4 files changed, 34 insertions, 4 deletions
diff --git a/platform/ios/os_ios.mm b/platform/ios/os_ios.mm index a674498620..b6b94d2f5e 100644 --- a/platform/ios/os_ios.mm +++ b/platform/ios/os_ios.mm @@ -396,7 +396,14 @@ void OS_IOS::vibrate_handheld(int p_duration_ms) { } bool OS_IOS::_check_internal_feature_support(const String &p_feature) { - return p_feature == "mobile"; + if (p_feature == "system_fonts") { + return true; + } + if (p_feature == "mobile") { + return true; + } + + return false; } void OS_IOS::on_focus_out() { diff --git a/platform/linuxbsd/os_linuxbsd.cpp b/platform/linuxbsd/os_linuxbsd.cpp index 11b667fcef..db9b3ed77f 100644 --- a/platform/linuxbsd/os_linuxbsd.cpp +++ b/platform/linuxbsd/os_linuxbsd.cpp @@ -481,7 +481,16 @@ Error OS_LinuxBSD::shell_open(String p_uri) { } bool OS_LinuxBSD::_check_internal_feature_support(const String &p_feature) { - return p_feature == "pc"; +#ifdef FONTCONFIG_ENABLED + if (p_feature == "system_fonts") { + return font_config_initialized; + } +#endif + if (p_feature == "pc") { + return true; + } + + return false; } uint64_t OS_LinuxBSD::get_embedded_pck_offset() const { diff --git a/platform/macos/os_macos.mm b/platform/macos/os_macos.mm index 8ffb0abfdb..e620b058d3 100644 --- a/platform/macos/os_macos.mm +++ b/platform/macos/os_macos.mm @@ -499,7 +499,14 @@ String OS_MacOS::get_unique_id() const { } bool OS_MacOS::_check_internal_feature_support(const String &p_feature) { - return p_feature == "pc"; + if (p_feature == "system_fonts") { + return true; + } + if (p_feature == "pc") { + return true; + } + + return false; } void OS_MacOS::disable_crash_handler() { diff --git a/platform/windows/os_windows.cpp b/platform/windows/os_windows.cpp index d95a88fac1..36fd86c4f5 100644 --- a/platform/windows/os_windows.cpp +++ b/platform/windows/os_windows.cpp @@ -1181,7 +1181,14 @@ String OS_Windows::get_unique_id() const { } bool OS_Windows::_check_internal_feature_support(const String &p_feature) { - return p_feature == "pc"; + if (p_feature == "system_fonts") { + return true; + } + if (p_feature == "pc") { + return true; + } + + return false; } void OS_Windows::disable_crash_handler() { |