summaryrefslogtreecommitdiff
path: root/modules/text_server_adv/text_server_adv.cpp
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2020-12-28 13:23:25 +0100
committerGitHub <noreply@github.com>2020-12-28 13:23:25 +0100
commitbe509bf5e4d00b33f2867e6d06a23285b2a8fd29 (patch)
tree975e0a7384bc6fc7cf5b73b9ddc1e8eef13579d8 /modules/text_server_adv/text_server_adv.cpp
parent886571e0fc54914f161ab3f1ccf9bfe40411bc20 (diff)
parent5b937d493f0046543a77a0be7920ad39f1e5fc3c (diff)
Merge pull request #44401 from madmiraal/rename-empty-is_empty
Rename empty() to is_empty()
Diffstat (limited to 'modules/text_server_adv/text_server_adv.cpp')
-rw-r--r--modules/text_server_adv/text_server_adv.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/modules/text_server_adv/text_server_adv.cpp b/modules/text_server_adv/text_server_adv.cpp
index 3a706286e5..671c2fa029 100644
--- a/modules/text_server_adv/text_server_adv.cpp
+++ b/modules/text_server_adv/text_server_adv.cpp
@@ -171,7 +171,7 @@ bool TextServerAdvanced::load_support_data(const String &p_filename) {
}
#else
if (icu_data == nullptr) {
- String filename = (p_filename.empty()) ? String("res://") + _MKSTR(ICU_DATA_NAME) : p_filename;
+ String filename = (p_filename.is_empty()) ? String("res://") + _MKSTR(ICU_DATA_NAME) : p_filename;
FileAccess *f = FileAccess::open(filename, FileAccess::READ);
if (!f) {
@@ -1061,7 +1061,7 @@ bool TextServerAdvanced::shaped_text_add_string(RID p_shaped, const String &p_te
ERR_FAIL_COND_V(!sd, false);
ERR_FAIL_COND_V(p_size <= 0, false);
- if (p_text.empty()) {
+ if (p_text.is_empty()) {
return true;
}
@@ -1984,7 +1984,7 @@ void TextServerAdvanced::_shape_run(ShapedTextDataAdvanced *p_sd, int32_t p_star
ftrs.push_back(feature);
}
}
- hb_shape(hb_font, p_sd->hb_buffer, ftrs.empty() ? nullptr : &ftrs[0], ftrs.size());
+ hb_shape(hb_font, p_sd->hb_buffer, ftrs.is_empty() ? nullptr : &ftrs[0], ftrs.size());
unsigned int glyph_count = 0;
hb_glyph_info_t *glyph_info = hb_buffer_get_glyph_infos(p_sd->hb_buffer, &glyph_count);
@@ -2131,7 +2131,7 @@ bool TextServerAdvanced::shaped_text_shape(RID p_shaped) {
sd->script_iter = memnew(ScriptIterator(sd->text, 0, sd->text.length()));
}
- if (sd->bidi_override.empty()) {
+ if (sd->bidi_override.is_empty()) {
sd->bidi_override.push_back(Vector2i(0, sd->end));
}