Support UTF-8 in TextEdit and LineEdit navigation
This allows jumps over whole non ASCII words with Ctrl+Left/Right in a LineEdit or TextEdit. Fixes #25681
This commit is contained in:
parent
d41cd57595
commit
8851e16f75
2 changed files with 2 additions and 2 deletions
|
@ -43,7 +43,7 @@
|
|||
|
||||
static bool _is_text_char(CharType c) {
|
||||
|
||||
return (c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z') || (c >= '0' && c <= '9') || c == '_';
|
||||
return !is_symbol(c);
|
||||
}
|
||||
|
||||
void LineEdit::_gui_input(Ref<InputEvent> p_event) {
|
||||
|
|
|
@ -50,7 +50,7 @@ inline bool _is_symbol(CharType c) {
|
|||
|
||||
static bool _is_text_char(CharType c) {
|
||||
|
||||
return (c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z') || (c >= '0' && c <= '9') || c == '_';
|
||||
return !is_symbol(c);
|
||||
}
|
||||
|
||||
static bool _is_whitespace(CharType c) {
|
||||
|
|
Loading…
Reference in a new issue